policyengine-il 0.2.0__tar.gz → 0.2.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (71) hide show
  1. policyengine_il-0.2.2/.github/ISSUE_TEMPLATE.md +9 -0
  2. policyengine_il-0.2.2/.github/PULL_REQUEST_TEMPLATE.md +27 -0
  3. policyengine_il-0.2.2/.github/bump_version.py +77 -0
  4. policyengine_il-0.2.2/.github/changelog_template.md +8 -0
  5. policyengine_il-0.2.2/.github/get-changelog-diff.sh +4 -0
  6. policyengine_il-0.2.2/.github/has-functional-changes.sh +12 -0
  7. policyengine_il-0.2.2/.github/is-version-number-acceptable.sh +33 -0
  8. policyengine_il-0.2.2/.github/publish-git-tag.sh +4 -0
  9. policyengine_il-0.2.2/.github/update_api.py +22 -0
  10. policyengine_il-0.2.2/.github/workflows/pr.yaml +30 -0
  11. policyengine_il-0.2.2/.github/workflows/push.yaml +133 -0
  12. policyengine_il-0.2.2/.gitignore +11 -0
  13. policyengine_il-0.2.2/.python-version +1 -0
  14. policyengine_il-0.2.2/.vscode/README.md +15 -0
  15. policyengine_il-0.2.2/.vscode/launch.json +16 -0
  16. policyengine_il-0.2.2/.vscode/python.code-snippets +44 -0
  17. policyengine_il-0.2.2/.vscode/yaml.code-snippets +50 -0
  18. policyengine_il-0.2.2/CHANGELOG.md +79 -0
  19. policyengine_il-0.2.2/CONTRIBUTING.md +31 -0
  20. policyengine_il-0.2.2/Makefile +20 -0
  21. policyengine_il-0.2.2/PKG-INFO +34 -0
  22. policyengine_il-0.2.2/changelog.d/.gitkeep +0 -0
  23. policyengine_il-0.2.2/docs/_config.yml +25 -0
  24. policyengine_il-0.2.2/docs/_toc.yml +2 -0
  25. policyengine_il-0.2.2/docs/intro.md +4 -0
  26. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/gov/low_income_municipal_tax_reduction/max_low_income_municipal_tax_reduction.py +1 -3
  27. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/gov/low_income_municipal_tax_reduction/max_low_income_municipal_tax_reduction_rate.py +5 -9
  28. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/marginal_tax_rate.py +4 -12
  29. policyengine_il-0.2.2/pyproject.toml +80 -0
  30. policyengine_il-0.2.0/PKG-INFO +0 -58
  31. policyengine_il-0.2.0/policyengine_il.egg-info/PKG-INFO +0 -58
  32. policyengine_il-0.2.0/policyengine_il.egg-info/SOURCES.txt +0 -43
  33. policyengine_il-0.2.0/policyengine_il.egg-info/dependency_links.txt +0 -1
  34. policyengine_il-0.2.0/policyengine_il.egg-info/entry_points.txt +0 -2
  35. policyengine_il-0.2.0/policyengine_il.egg-info/requires.txt +0 -18
  36. policyengine_il-0.2.0/policyengine_il.egg-info/top_level.txt +0 -1
  37. policyengine_il-0.2.0/setup.cfg +0 -4
  38. policyengine_il-0.2.0/setup.py +0 -69
  39. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/LICENSE +0 -0
  40. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/MANIFEST.in +0 -0
  41. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/README.md +0 -0
  42. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/__init__.py +0 -0
  43. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/constants.py +0 -0
  44. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/entities.py +0 -0
  45. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/model_api.py +0 -0
  46. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/modelled_policies.yaml +0 -0
  47. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/parameters/gov/README.md +0 -0
  48. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/parameters/gov/low_income_municipal_tax_reduction_rate.yaml +0 -0
  49. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/parameters/simulation/README.md +0 -0
  50. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/parameters/simulation/marginal_tax_rate_adults.yaml +0 -0
  51. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/tests/household_net_income.yaml +0 -0
  52. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/tests/max_low_income_municipal_tax_reduction.yaml +0 -0
  53. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/tests/max_low_income_municipal_tax_reduction_rate.yaml +0 -0
  54. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/age.py +0 -0
  55. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/employment_income.py +0 -0
  56. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/gov/low_income_municipal_tax_reduction/low_income_municipal_tax_reduction_income.py +0 -0
  57. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/gov/municipal_tax.py +0 -0
  58. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/gross_income.py +0 -0
  59. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/household_benefits.py +0 -0
  60. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/household_market_income.py +0 -0
  61. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/household_net_income.py +0 -0
  62. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/household_size.py +0 -0
  63. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/household_tax.py +0 -0
  64. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/input/README.md +0 -0
  65. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/input/demographic/README.md +0 -0
  66. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/input/demographic/gender.py +0 -0
  67. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/is_adult.py +0 -0
  68. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/market_income.py +0 -0
  69. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/pension_income.py +0 -0
  70. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/self_employment_income.py +0 -0
  71. {policyengine_il-0.2.0 → policyengine_il-0.2.2}/policyengine_il/variables/tax.py +0 -0
@@ -0,0 +1,9 @@
1
+ Thanks for filing an issue! Please remove any top-level headers that do not apply.
2
+
3
+ # Variable to add: name
4
+
5
+ # Variable to amend: name
6
+
7
+ # Parameter to add: name
8
+
9
+ # Parameter to amend: name
@@ -0,0 +1,27 @@
1
+ Thanks for contributing! Please remove any top-level sections that do not apply to your changes.
2
+
3
+ - [ ] `make format && make documentation` has been run.
4
+
5
+ # New variable
6
+
7
+ - [ ] Label field added
8
+ - [ ] Documentation field added
9
+ - [ ] Unit field added
10
+ - [ ] Default value field added if relevant
11
+ - [ ] Variable name follows conventions
12
+ - [ ] Unit test(s) added
13
+ - [ ] Integration test(s) added if relevant
14
+ - [ ] Issues this PR fixes linked
15
+
16
+ ## What's changed
17
+
18
+ Description of the changes here.
19
+
20
+ # Bug fix
21
+
22
+ - [ ] Regression test added
23
+ - [ ] Regression test passing
24
+
25
+ ## What this fixes and how it's fixed
26
+
27
+ Description of how this fix works goes here. Link any issues this PR fixes.
@@ -0,0 +1,77 @@
1
+ """Infer semver bump from towncrier fragment types and update version."""
2
+
3
+ import re
4
+ import sys
5
+ from pathlib import Path
6
+
7
+
8
+ def get_current_version(pyproject_path: Path) -> str:
9
+ text = pyproject_path.read_text()
10
+ match = re.search(r'^version\s*=\s*"(\d+\.\d+\.\d+)"', text, re.MULTILINE)
11
+ if not match:
12
+ print(
13
+ "Could not find version in pyproject.toml",
14
+ file=sys.stderr,
15
+ )
16
+ sys.exit(1)
17
+ return match.group(1)
18
+
19
+
20
+ def infer_bump(changelog_dir: Path) -> str:
21
+ fragments = [
22
+ f for f in changelog_dir.iterdir() if f.is_file() and f.name != ".gitkeep"
23
+ ]
24
+ if not fragments:
25
+ print("No changelog fragments found", file=sys.stderr)
26
+ sys.exit(1)
27
+
28
+ categories = {f.suffix.lstrip(".") for f in fragments}
29
+ for f in fragments:
30
+ parts = f.stem.split(".")
31
+ if len(parts) >= 2:
32
+ categories.add(parts[-1])
33
+
34
+ if "breaking" in categories:
35
+ return "major"
36
+ if "added" in categories or "removed" in categories:
37
+ return "minor"
38
+ return "patch"
39
+
40
+
41
+ def bump_version(version: str, bump: str) -> str:
42
+ major, minor, patch = (int(x) for x in version.split("."))
43
+ if bump == "major":
44
+ return f"{major + 1}.0.0"
45
+ elif bump == "minor":
46
+ return f"{major}.{minor + 1}.0"
47
+ else:
48
+ return f"{major}.{minor}.{patch + 1}"
49
+
50
+
51
+ def update_file(path: Path, old_version: str, new_version: str):
52
+ text = path.read_text()
53
+ updated = text.replace(
54
+ f'version = "{old_version}"',
55
+ f'version = "{new_version}"',
56
+ )
57
+ if updated != text:
58
+ path.write_text(updated)
59
+ print(f" Updated {path}")
60
+
61
+
62
+ def main():
63
+ root = Path(__file__).resolve().parent.parent
64
+ pyproject = root / "pyproject.toml"
65
+ changelog_dir = root / "changelog.d"
66
+
67
+ current = get_current_version(pyproject)
68
+ bump = infer_bump(changelog_dir)
69
+ new = bump_version(current, bump)
70
+
71
+ print(f"Version: {current} -> {new} ({bump})")
72
+
73
+ update_file(pyproject, current, new)
74
+
75
+
76
+ if __name__ == "__main__":
77
+ main()
@@ -0,0 +1,8 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ {{changelog}}
@@ -0,0 +1,4 @@
1
+ git remote add upstream https://github.com/policyengine/policyengine-il
2
+ git fetch --tags upstream
3
+ last_tagged_commit=$(git describe --tags --abbrev=0 --first-parent)
4
+ git --no-pager diff $last_tagged_commit -- CHANGELOG.md
@@ -0,0 +1,12 @@
1
+ #! /usr/bin/env bash
2
+
3
+ IGNORE_DIFF_ON="README.md CONTRIBUTING.md Makefile .gitignore LICENSE* .github/* environment.yml"
4
+
5
+ last_tagged_commit=$(git describe --tags --abbrev=0 --first-parent) # --first-parent ensures we don't follow tags not published in master through an unlikely intermediary merge commit
6
+
7
+ if git diff-index --name-only --exit-code $last_tagged_commit -- . $(echo " $IGNORE_DIFF_ON" | sed 's/ / :(exclude)/g'); then # Check if any file that has not be listed in IGNORE_DIFF_ON has changed since the last tag was published.
8
+ echo "No functional changes detected."
9
+ exit 1
10
+ else
11
+ echo "The functional files above were changed."
12
+ fi
@@ -0,0 +1,33 @@
1
+ #! /usr/bin/env bash
2
+
3
+ if [[ ${GITHUB_REF#refs/heads/} == master ]]
4
+ then
5
+ echo "No need for a version check on master."
6
+ exit 0
7
+ fi
8
+
9
+ if ! $(dirname "$BASH_SOURCE")/has-functional-changes.sh
10
+ then
11
+ echo "No need for a version update."
12
+ exit 0
13
+ fi
14
+
15
+ current_version=`python setup.py --version`
16
+
17
+ if git rev-parse --verify --quiet $current_version
18
+ then
19
+ echo "Version $current_version already exists in commit:"
20
+ git --no-pager log -1 $current_version
21
+ echo
22
+ echo "Update the version number in setup.py before merging this branch into master."
23
+ echo "Look at the CONTRIBUTING.md file to learn how the version number should be updated."
24
+ exit 1
25
+ fi
26
+
27
+ if ! $(dirname "$BASH_SOURCE")/has-functional-changes.sh | grep --quiet CHANGELOG.md
28
+ then
29
+ echo "CHANGELOG.md has not been modified, while functional changes were made."
30
+ echo "Explain what you changed before merging this branch into master."
31
+ echo "Look at the CONTRIBUTING.md file to learn how to write the changelog."
32
+ exit 2
33
+ fi
@@ -0,0 +1,4 @@
1
+ #! /usr/bin/env bash
2
+
3
+ git tag `python setup.py --version`
4
+ git push --tags || true # update the repository version
@@ -0,0 +1,22 @@
1
+ import argparse
2
+ import os
3
+
4
+
5
+ def main():
6
+ # First, find the current package version number from the setup.py file
7
+ with open("setup.py", "r") as f:
8
+ setup = f.read()
9
+ version = setup.split("version=")[1].split(",")[0].strip('"')
10
+ # Then, clone the https://github.com/policyengine/policyengine-api repo using the GitHub CLI
11
+ pat = os.environ["GITHUB_TOKEN"]
12
+ os.system(
13
+ f"git clone https://nikhilwoodruff:{pat}@github.com/policyengine/policyengine-api"
14
+ )
15
+ # Then, cd inside and run gcp/bump_country_package.py --country policyengine-uk --version {version}
16
+ os.system(
17
+ f"cd policyengine-api && python gcp/bump_country_package.py --country policyengine-il --version {version}"
18
+ )
19
+
20
+
21
+ if __name__ == "__main__":
22
+ main()
@@ -0,0 +1,30 @@
1
+ name: Pull request
2
+ on:
3
+ pull_request:
4
+ branches: [master]
5
+ jobs:
6
+ Lint:
7
+ uses: PolicyEngine/.github/.github/workflows/lint.yml@main
8
+ check-changelog:
9
+ uses: PolicyEngine/.github/.github/workflows/changelog.yml@main
10
+ Test:
11
+ runs-on: ${{ matrix.os }}
12
+ strategy:
13
+ matrix:
14
+ os: [ubuntu-latest, windows-latest]
15
+ python-version: ["3.11"]
16
+ steps:
17
+ - name: Checkout repo
18
+ uses: actions/checkout@v6
19
+ - name: Set up Python ${{ matrix.python-version }}
20
+ uses: actions/setup-python@v6
21
+ with:
22
+ python-version: ${{ matrix.python-version }}
23
+ allow-prereleases: true
24
+ - name: Install package
25
+ run: make install
26
+ - name: Run tests
27
+ run: make test
28
+ - uses: codecov/codecov-action@v6
29
+ - name: Build package
30
+ run: make build
@@ -0,0 +1,133 @@
1
+ name: Push
2
+ on:
3
+ push:
4
+ branches: [master]
5
+ jobs:
6
+ Lint:
7
+ if: |
8
+ (github.repository == 'PolicyEngine/policyengine-il')
9
+ && (github.event.head_commit.message == 'Update PolicyEngine Israel')
10
+ uses: PolicyEngine/.github/.github/workflows/lint.yml@main
11
+ versioning:
12
+ name: Update versioning
13
+ if: |
14
+ (github.repository == 'PolicyEngine/policyengine-il')
15
+ && !(github.event.head_commit.message == 'Update PolicyEngine Israel')
16
+ runs-on: ubuntu-latest
17
+ steps:
18
+ - name: Generate GitHub App token
19
+ id: app-token
20
+ uses: actions/create-github-app-token@v3
21
+ with:
22
+ app-id: ${{ secrets.APP_ID }}
23
+ private-key: ${{ secrets.APP_PRIVATE_KEY }}
24
+ - name: Checkout repo
25
+ uses: actions/checkout@v6
26
+ with:
27
+ token: ${{ steps.app-token.outputs.token }}
28
+ - name: Setup Python
29
+ uses: actions/setup-python@v6
30
+ with:
31
+ python-version: "3.14"
32
+ - name: Build changelog
33
+ run: |
34
+ pip install towncrier
35
+ python .github/bump_version.py
36
+ towncrier build --yes --version $(python -c "import re; print(re.search(r'version = \"(.+?)\"', open('pyproject.toml').read()).group(1))")
37
+ - name: Preview changelog update
38
+ run: ".github/get-changelog-diff.sh"
39
+ - name: Update changelog
40
+ uses: EndBug/add-and-commit@v10
41
+ with:
42
+ add: "."
43
+ committer_name: Github Actions[bot]
44
+ author_name: Github Actions[bot]
45
+ message: Update PolicyEngine Israel
46
+ github_token: ${{ steps.app-token.outputs.token }}
47
+ fetch: false
48
+ Test:
49
+ runs-on: ${{ matrix.os }}
50
+ if: |
51
+ (github.repository == 'PolicyEngine/policyengine-il')
52
+ && (github.event.head_commit.message == 'Update PolicyEngine Israel')
53
+ strategy:
54
+ matrix:
55
+ os: [ubuntu-latest, windows-latest]
56
+ steps:
57
+ - name: Checkout repo
58
+ uses: actions/checkout@v6
59
+ - name: Set up Python
60
+ uses: actions/setup-python@v6
61
+ with:
62
+ python-version: "3.14"
63
+ - name: Install package
64
+ run: make install
65
+ - name: Run tests
66
+ run: make test
67
+ - uses: codecov/codecov-action@v6
68
+ - name: Generate documentation
69
+ run: make documentation
70
+ - name: Deploy documentation
71
+ if: matrix.os == 'ubuntu-latest'
72
+ uses: JamesIves/github-pages-deploy-action@v4
73
+ with:
74
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
75
+ BRANCH: gh-pages
76
+ FOLDER: docs/_build/html
77
+ Publish:
78
+ runs-on: ubuntu-latest
79
+ # PyPI trusted publishing: uploads accepted only from this workflow in the
80
+ # pypi environment (limited to master). No stored token.
81
+ environment: pypi
82
+ permissions:
83
+ contents: write # publish-git-tag.sh pushes the version tag
84
+ id-token: write
85
+ if: |
86
+ (github.repository == 'PolicyEngine/policyengine-il')
87
+ && (github.event.head_commit.message == 'Update PolicyEngine Israel')
88
+ steps:
89
+ - name: Checkout repo
90
+ uses: actions/checkout@v6
91
+ - name: Setup Python
92
+ uses: actions/setup-python@v6
93
+ with:
94
+ python-version: "3.14"
95
+ - name: Publish a git tag
96
+ run: ".github/publish-git-tag.sh || true"
97
+ - name: Install package
98
+ run: make install
99
+ - name: Build package
100
+ run: make build
101
+ - name: Publish a Python distribution to PyPI
102
+ uses: pypa/gh-action-pypi-publish@release/v1
103
+ with:
104
+ skip_existing: true
105
+ Deploy:
106
+ if: |
107
+ (github.repository == 'PolicyEngine/policyengine-il')
108
+ && (github.event.head_commit.message == 'Update PolicyEngine Israel')
109
+ runs-on: ubuntu-latest
110
+ steps:
111
+ - name: Generate GitHub App token
112
+ id: app-token
113
+ uses: actions/create-github-app-token@v3
114
+ with:
115
+ app-id: ${{ secrets.APP_ID }}
116
+ private-key: ${{ secrets.APP_PRIVATE_KEY }}
117
+ - name: Checkout repo
118
+ uses: actions/checkout@v6
119
+ with:
120
+ token: ${{ steps.app-token.outputs.token }}
121
+ - name: Setup Python
122
+ uses: actions/setup-python@v6
123
+ with:
124
+ python-version: "3.14"
125
+ - name: Install Wheel and Pytest
126
+ run: pip3 install wheel setuptools pytest==5.4.3
127
+ - name: Install package
128
+ run: make install
129
+ - name: Update API
130
+ run: python .github/update_api.py
131
+ env:
132
+ GH_TOKEN: ${{ steps.app-token.outputs.token }}
133
+ GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
@@ -0,0 +1,11 @@
1
+ **/__pycache__
2
+ **/*.egg-info
3
+ coverage.xml
4
+ .coverage
5
+ build/
6
+ dist/
7
+ docs/_build/
8
+ **/*.ipynb_checkpoints/
9
+ **/*.h5
10
+ **/iframe_figures/
11
+ .idea
@@ -0,0 +1 @@
1
+ 3.14
@@ -0,0 +1,15 @@
1
+ # VS Code Auxiliary Files
2
+
3
+ This folder contains some helper files that speed up development within Visual Studio Code:
4
+
5
+ - ```launch.json``` describes the behaviour when debugging Python files within the repo.
6
+ - ```snippets/``` contains code snippets for creating OpenFisca constructs.
7
+
8
+ ## Code Snippets
9
+
10
+ The ```snippets/``` folder contains two files:
11
+
12
+ - ```python.json``` contains snippets for creating variables, formulas and initialising new variables files.
13
+ - ```yaml.json``` contains snippets for creating tests and parameters.
14
+
15
+ There is a variety of extensions that automatically read in the code snippets, such as [Project Snippets](https://marketplace.visualstudio.com/items?itemName=rebornix.project-snippets), or the same can be achieved by pasting the contents of the files into the user snippets files (accessible via <kbd>CTRL</kbd>+<kbd>SHIFT</kbd>+<kbd>P</kbd> and selecting ```Preferences: configure user snippets```).
@@ -0,0 +1,16 @@
1
+ {
2
+ // Use IntelliSense to learn about possible attributes.
3
+ // Hover to view descriptions of existing attributes.
4
+ // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5
+ "version": "0.2.2",
6
+ "configurations": [
7
+ {
8
+ "name": "Python: Current File",
9
+ "type": "python",
10
+ "request": "launch",
11
+ "program": "${file}",
12
+ "console": "integratedTerminal",
13
+ "justMyCode": true
14
+ }
15
+ ]
16
+ }
@@ -0,0 +1,44 @@
1
+ {
2
+ // Place your snippets for python here. Each snippet is defined under a snippet name and has a prefix, body and
3
+ // description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
4
+ // $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the
5
+ // same ids are connected.
6
+ // Example:
7
+ // "Print to console": {
8
+ // "prefix": "log",
9
+ // "body": [
10
+ // "console.log('$1');",
11
+ // "$2"
12
+ // ],
13
+ // "description": "Log output to console"
14
+ // }
15
+ "OpenFisca Variable": {
16
+ "prefix": "var",
17
+ "body": [
18
+ "class ${1:name}(Variable):",
19
+ " label = \"${2:label}\"",
20
+ " documentation = \"${3:Description.}\"",
21
+ " entity = ${4:Person}",
22
+ " definition_period = ${5:YEAR}",
23
+ " value_type = ${6:float}",
24
+ " unit = \"${7:currency-ILS}\"",
25
+ "",
26
+ ""
27
+ ],
28
+ "description": "Insert a new OpenFisca Variable, without a formula."
29
+ },
30
+ "OpenFisca Formula": {
31
+ "prefix": "form",
32
+ "body": [
33
+ "def formula(${1:person}, period, parameters):",
34
+ " ${2:pass}"
35
+ ],
36
+ "description": "Insert a new OpenFisca Formula."
37
+ },
38
+ "OpenFisca Variable File": {
39
+ "prefix": "file",
40
+ "body": [
41
+ "from policyengine_ng.model_api import *",
42
+ ]
43
+ }
44
+ }
@@ -0,0 +1,50 @@
1
+ {
2
+ // Place your snippets for yaml here. Each snippet is defined under a snippet name and has a prefix, body and
3
+ // description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
4
+ // $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the
5
+ // same ids are connected.
6
+ // Example:
7
+ // "Print to console": {
8
+ // "prefix": "log",
9
+ // "body": [
10
+ // "console.log('$1');",
11
+ // "$2"
12
+ // ],
13
+ // "description": "Log output to console"
14
+ // }
15
+ "Insert OpenFisca basic parameter": {
16
+ "prefix": "param",
17
+ "body": [
18
+ "description: ${1:Description}",
19
+ "values:",
20
+ " 2010-01-01:",
21
+ " value: ${2:0.00}",
22
+ "metadata:",
23
+ " unit: currency-ILS",
24
+ " reference: ${3:none}"
25
+ ],
26
+ "description": "Insert a basic OpenFisca parameter."
27
+ },
28
+ "Insert OpenFisca parameter value with reference": {
29
+ "prefix": "refparam",
30
+ "body": [
31
+ "value: ${1:0.00}",
32
+ "reference:",
33
+ " - title: ${2:Title}",
34
+ " href: ${3:Link}",
35
+ ],
36
+ "description": "Insert a basic OpenFisca parameter."
37
+ },
38
+ "Insert OpenFisca basic test": {
39
+ "prefix": "test",
40
+ "body": [
41
+ "- name: ${1:Name}",
42
+ " period: 2023",
43
+ " input:",
44
+ " ${3:variable values here}",
45
+ " output:",
46
+ " ${4:expected output here}"
47
+ ],
48
+ "description": "Insert a basic OpenFisca parameter for one person."
49
+ },
50
+ }
@@ -0,0 +1,79 @@
1
+ ## [0.2.2] - 2026-11-16
2
+
3
+ ### Changed
4
+
5
+ - Require Python 3.11 or later.
6
+
7
+
8
+ ## [0.2.1] - 2026-10-12
9
+
10
+ ### Changed
11
+
12
+ - Publish to PyPI with trusted publishing (OIDC) from the `pypi` environment instead of a stored API token.
13
+
14
+
15
+ ## [0.1.5] - 2026-04-28
16
+
17
+ ### Changed
18
+
19
+ - Updated GitHub Actions workflows for Node 24-compatible action runtimes.
20
+
21
+
22
+ ## [0.1.4] - 2026-04-17
23
+
24
+ ### Changed
25
+
26
+ - Mint GitHub App token at runtime in push workflow instead of using the expired org PAT.
27
+
28
+
29
+ ## [0.1.3] - 2026-03-07
30
+
31
+ ### Changed
32
+
33
+ - Use org-level reusable GitHub Actions workflows for lint and changelog checks.
34
+
35
+
36
+ ## [0.1.2] - 2026-03-06
37
+
38
+ ### Changed
39
+
40
+ - Switch from black to ruff format.
41
+
42
+
43
+ ## [0.1.1] - 2026-02-24
44
+
45
+ ### Changed
46
+
47
+ - Migrated from changelog_entry.yaml to towncrier fragments to eliminate merge conflicts.
48
+
49
+
50
+ # Changelog
51
+
52
+ All notable changes to this project will be documented in this file.
53
+
54
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
56
+
57
+ ## [0.2.0] - 2026-02-24 17:31:08
58
+
59
+ ### Added
60
+
61
+ - Added Python 3.14 support, dropped Python 3.10 and below.
62
+
63
+ ## [0.1.0] - 2023-07-06 16:35:47
64
+
65
+ ### Added
66
+
67
+ - Low-income municipal tax reduction.
68
+
69
+ ## [0.0.1] - 2023-02-09 00:00:00
70
+
71
+ ### Added
72
+
73
+ - Initial Israel template.
74
+
75
+
76
+
77
+ [0.2.0]: https://github.com/PolicyEngine/policyengine-il/compare/0.1.0...0.2.0
78
+ [0.1.0]: https://github.com/PolicyEngine/policyengine-il/compare/0.0.1...0.1.0
79
+
@@ -0,0 +1,31 @@
1
+ # How to contribute
2
+
3
+ Any and all contributions are welcome to this project. You can help by:
4
+
5
+ * Filing issues. Tell us about bugs you've found, or features you'd like to see.
6
+ * Fixing issues. File a pull request to fix an issue you or someone else has filed.
7
+
8
+ If you file an issue or a pull request, one of the maintainers (primarily @nikhilwoodruff) will respond to it within at least a week. If you don't hear back, feel free to ping us on the issue or pull request.
9
+
10
+ ## Changelog Entries
11
+
12
+ Before you send out a pull request, make sure to add a description of your changes to [changelog_entry.yaml](../../changelog_entry.yaml).
13
+ For example,
14
+ ```yaml
15
+ - bump: patch
16
+ changes:
17
+ fixed:
18
+ - Fixed a bug causing Windows tests to fail.
19
+ ```
20
+ You can find more examples in [changelog.yaml](../../changelog.yaml). Note that you do not need to add the date field.
21
+ That field is automatically populated by `make changelog`. Also, note that **you should not run `make changelog`
22
+ yourself**, as [our GitHub workflows](../../.github/workflows) will do this for you as part of the build process.
23
+
24
+ ## Pull requests
25
+
26
+ Each pull request should:
27
+ * Close an issue. If there isn't an issue that the pull request completely addresses, please file one.
28
+ * Have a description that makes sense to a layperson. If you're fixing a bug, describe what the bug is and how you fixed it. If you're adding a feature, describe what the feature is and why you added it.
29
+ * Have tests. If you're fixing a bug, write a test that fails without your fix and passes with it. If you're adding a feature, write tests that cover the feature. Sometimes this isn't necessary (for example, documentation changes), but if in doubt, err on the side of including tests.
30
+ * Pass all GitHub actions. If you're not sure why a GitHub action is failing, feel free to ask for help in the issue or pull request.
31
+
@@ -0,0 +1,20 @@
1
+ all: install format test build changelog
2
+
3
+ documentation:
4
+ myst build docs
5
+
6
+ format:
7
+ ruff format .
8
+
9
+ install:
10
+ pip install -e .[dev]
11
+
12
+ test:
13
+ policyengine-core test policyengine_il/tests -c policyengine_il
14
+
15
+ build:
16
+ python -m build
17
+
18
+ changelog:
19
+ python .github/bump_version.py
20
+ towncrier build --yes --version $$(python -c "import re; print(re.search(r'version = \"(.+?)\"', open('pyproject.toml').read()).group(1))")