Skip to main content

An OpenFisca extension that adds some variables to an already-existing tax and benefit system.

Project description

OpenFisca Extension-Template

This repository is here to help you bootstrap your own OpenFisca extension package.

You should NOT fork it but download a copy of its source code and

  • change the name openfisca_extension_template to reflect your extension's name, e.g. openfisca_shangrila
  • empty out CHANGELOG.md
  • replace the placeholders variables and parameters to suit your own purposes

Installing

We recommend you to use an isolated environment manager to manage build and extension dependencies separately:

pipx install poetry
pipx install tox

Virtualenv

Poetry will automatically manage a virtual environment for you. Nonetheless, if you need to have more control over your dependencies, we recommend you to use a virtualenv:

manager to install OpenFisca:

poetry config settings.virtualenvs.create false
pyenv install 3.9.16
pyenv virtualenv 3.9.16 my-super-duper-extension-3.9.16
cd ~/path/where/is/my-super-duper-extension-3.9.16
pyenv local my-super-duper-extension-3.9.16

To install your extension for development, run:

poetry install --all-extras --sync

Testing

You can make sure that everything is working by running the provided tests:

poetry run openfisca test --country-package=openfisca_country_template --extensions=openfisca_extension_template openfisca_extension_template/tests

Learn more about tests.

Your extension package is now installed and ready!

Cleanup

To completely clean up your environment, run:

poetry env remove --all
pip freeze | grep -v "^-e" | sed "s/@.*//" | xargs pip uninstall -y

This will remove all pip package from current environment and remove all Poetry environment in OpenFisca Extension-Template.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

openfisca_extension_template-2.0.0.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

File details

Details for the file openfisca_extension_template-2.0.0.tar.gz.

File metadata

File hashes

Hashes for openfisca_extension_template-2.0.0.tar.gz
Algorithm Hash digest
SHA256 38361d8395e886a5290c812ba732211184ae3764b3196c0bdb995b2112092995
MD5 7699c9e45f981be41777df87febfc0cd
BLAKE2b-256 fad2558cfb8e7471cfd1bad0065e12251aee74e94532aae5bfece6f7598c4da4

See more details on using hashes here.

File details

Details for the file openfisca_extension_template-2.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for openfisca_extension_template-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 17215375710f99ddd512d8df488542043697e58f79b2081b314775373a3ee023
MD5 07f284c25abc2fe23a1e81608ee0a482
BLAKE2b-256 744e27a3df4624fe195671c391a962cca13b86802838de2a71ef4b6fbcf52ce7

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page