Development
We welcome contributions to the development of ensemble-integration. To contribute follow the below instructions to submit a pull request:
Install Python. First of all make sure you have a supported version of Python on your local machine (see GitHub for supported versions).
Install Poetry.
eipyuses Poetry to manage dependencies. To install Poetry follow the instructions on their website.Fork the repo.
git fork https://github.com/GauravPandeyLab/eipy.git
Set up a virtual environment. Navigate to the
eipydirectory and create and activate a virtual environment.
python -m venv .venv
source .venv/bin/activate
Install dependencies. If editing the documentation make sure to include the
--with docsargument.
poetry install --with docs
Make contributions.
Linting and formating. We use Flake8 for linting and Black for formatting. For linting type, for example,
flake8 eipy/ei.py
For formatting type, for example,
black eipy/ei.py
Run tests. All tests can be found in the tests folder and can be run by typing
pytest
Note that new test file names must have the prefix test_.
9. Submit pull request. Updates must be made via a pull request. Internal users should note that pushing to the main branch has been disabled.
10. Publishing new versions to PyPI (internal only). We now use poetry-dynamic-versioning to iterate version numbers in pyproject.toml automatically. You can publish to PyPI by creating a new release, which will run the “Publish to PyPI” workflow. This workflow determines the PyPI version number from the GitHub release tag, which you should manually iterate. Note: to test things out first, you can try manually running the “Publish to test PyPI” workflow.