Thank you for considering contributing to this project!
All contributions are appreciated, from reporting bugs to implementing new features. This guide will try to help you take the first steps.
- First, fork the repository.
- Copy forked repository to local machine:
>>> git clone https://github.com/<username>/obscure_stats.git
>>> cd obscure_stats- This project uses
poetryas a pakcage manager. See how to install it here. - Set up local environment that
poetrywill use. You can do it with pyenv or venv or any other environment manager that you like. - to initialize your local environment run:
>>> poetry install- You are good to go!
- Every change should be tested; you need to add new tests for the new functionality (
pytestandpytest-covwill help you with this). - Every change should be documented; you need to add a docstring (
numpystyle) with reference to a scientific paper (preprints accepted). - Every change should be clean; you need to run linters, formatters, type checkers (
ruffandpyreflywill take care of this).
After you have made some changes to the codebase, you should run the following commands:
>>> poetry run ruff check . --fixThis command will run linters and other useful stuff and try to fix all the problems. If something is unfixable automatically, you should try to fix it manually.
>>> poetry run ruff format .This command will run formatter.
>>> poetry run pyrefly check .This command will run type checker. All typing problems should be fixed.
>>> poetry run pytest --cov-report term-missing --cov=obscure_statsThis command will run the test suite. All tests should pass, as well as code coverage should be high enough.
Happy coding!