You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Shell scripts run in CI but that can also be run locally (.circleci/*.sh, soon .github/*.sh).
Makefile.
OpenFisca CLI.
Depending on each case, these complement (installing locally, testing both locally and in CI, packaging in CI), reference (publish-git-tag.sh from CI config, openfisca test in test-api.sh) or overlap (make check-style vs .circleci/lint-changed-python-tests.sh) each other.
Problem
This setup raises the following issues:
Inconsistent workflows (make install differs from the install result in CI, which calls make build instead), leading to inconsistent test results (e.g. build: test against packaged version #1037).
There is interest in converging the workflow on one single tool.
Maintainers present in the call preferred make over openfisca as it is shorter, especially when multiple country packages are installed in one virtualenv (make test vs openfisca test --country-package openfisca_france tests).
The cost of installing Docker was felt as too high, even for maintainers.
The representativity of the sample of participants to the discussion was too low to lead to any conclusion as to which tool to prefer.
Annex
Known workflow steps
The following table aims at summarizing all known declared workflow steps. It was established by @MattiSG on 03/09/2021, based on reading through Core, France and Country Template Makefile, .circleci/config.yml and .circleci/*.sh.
Some tasks exist only on Core and are marked with ⊛, some exist only on a country package (France or Country Template) and are marked with ✣.
make api(in Core)make serve-local(in Country Template)
openfisca serve
Check version number validity
git fetch && check_version_and_changelog.sh
check_version_and_changelog.sh
Build package
make build
Clean installed packages
make uninstall, make clean
Test web API ✣
test-api.sh
Deploy ✣
Deploy web API
publish-python-package.sh && publish-git-tag.sh
Deploy ⊛
Trigger documentation build update
publish-python-package.sh && publish-git-tag.sh
Check NumPy compatibility ⊛
Check NumPy typing against latest 3 minor versions
Check types ⊛
make check-types
Run Country-Template tests ⊛
Run Country Template tests
Log test coverage ⊛
Submit coverage to Coveralls
Usage survey
In parallel to this RFC, in order to identify which tasks might be removed altogether from the list of existing ones, and which destination is least likely to disrupt existing uses, a survey has been created by @MattiSG to better understand the current usages. You are strongly encouraged to participate to it: share your current workflow.
This RFC aims at finding the best solution to the problems identified above. Contributors are invited to vote on the propositions below, which will be exposed each in their own post, through emoji reactions (:+1: to support an option, :-1: to reject it, :eyes: to indicate having read it and not supporting nor rejecting it). Contributors are also invited to ask for clarifications, suggest improvements to the propositions if that could change their stance on them, and contribute their own if they believe they can offer significant improvements.
In order to contribute a proposition, please make clear whether it is a new one, in which case you should give it a new number (e.g. “proposition 5”), or if it builds upon an existing one to add some detail, in which case you should suffix the original number with a letter (e.g. “proposition 3A”).
This RFC will close after one week (7 ⨉ 24 hours) without changes to the proposition set. At that time, votes will be counted and the most consensual proposition will be implemented.
RFC: Consolidate build workflow
Context
There are currently four sources of truth for how to build, test and deploy an OpenFisca package:
.circleci/config.yml, soon.github/workflows/config.yml, cf. Switch from CircleCI to GitHub Actions #1030)..circleci/*.sh, soon.github/*.sh).Makefile.Depending on each case, these complement (installing locally, testing both locally and in CI, packaging in CI), reference (
publish-git-tag.shfrom CI config,openfisca testintest-api.sh) or overlap (make check-stylevs.circleci/lint-changed-python-tests.sh) each other.Problem
This setup raises the following issues:
make installdiffers from the install result in CI, which callsmake buildinstead), leading to inconsistent test results (e.g. build: test against packaged version #1037).make testand contributorsopenfisca test), leading to blocked PRs (e.g. Allow variable neutralization in YAML test files #1021 (comment)).Discussion
A synchronous discussion with @benjello @benoit-cty @sandcha @maukoquiroga @HAEKADI @MattiSG took place on 02/09/2021 on this topic.
Conclusions on that topic were that:
makeoveropenfiscaas it is shorter, especially when multiple country packages are installed in one virtualenv (make testvsopenfisca test --country-package openfisca_france tests).Annex
Known workflow steps
The following table aims at summarizing all known declared workflow steps. It was established by @MattiSG on 03/09/2021, based on reading through Core, France and Country Template
Makefile,.circleci/config.ymland.circleci/*.sh.pip install --editable(optional)make deps,make installpip install openfisca_country_packagelint-changed-python-files.sh,lint-changed-yaml-tests.shmake check-syntax-errors check-stylemake format-stylepytest && openfisca testmake testopenfisca testmake api(in Core)make serve-local(in Country Template)openfisca servegit fetch && check_version_and_changelog.shcheck_version_and_changelog.shmake buildmake uninstall,make cleantest-api.shpublish-python-package.sh && publish-git-tag.shpublish-python-package.sh && publish-git-tag.shmake check-typesUsage survey
In parallel to this RFC, in order to identify which tasks might be removed altogether from the list of existing ones, and which destination is least likely to disrupt existing uses, a survey has been created by @MattiSG to better understand the current usages. You are strongly encouraged to participate to it: share your current workflow.
The results of the survey are publicly available.
Process
This RFC aims at finding the best solution to the problems identified above. Contributors are invited to vote on the propositions below, which will be exposed each in their own post, through emoji reactions (:+1: to support an option, :-1: to reject it, :eyes: to indicate having read it and not supporting nor rejecting it). Contributors are also invited to ask for clarifications, suggest improvements to the propositions if that could change their stance on them, and contribute their own if they believe they can offer significant improvements.
In order to contribute a proposition, please make clear whether it is a new one, in which case you should give it a new number (e.g. “proposition 5”), or if it builds upon an existing one to add some detail, in which case you should suffix the original number with a letter (e.g. “proposition 3A”).
This RFC will close after one week (7 ⨉ 24 hours) without changes to the proposition set. At that time, votes will be counted and the most consensual proposition will be implemented.