Contributor Guide¶
Code of Conduct¶
🐛 Bug Reports / 🙋 Feature Requests¶
Please leave bug reports and feature requests as Github issues .
Be sure to check through existing issues (open and closed) to confirm that the bug hasn’t been reported before.
Duplicate bug reports are a huge drain on the time of other contributors, and should be avoided as much as possible.
↪️ Pull Requests¶
For larger, new features:
Open an RFC issue . Discuss the feature with project maintainers to be sure that your change fits with the project vision and that you won’t be wasting effort going in the wrong direction.
Once you get the green light 🚦 from maintainers, you can proceed with the PR.
Contributions / PRs should follow the Forking Workflow :
Fork it: https://github.com/[your-github-username]/unify-client-python/fork
Create your feature branch:
git checkout -b my-new-featureCommit your changes:
git commit -am 'Add some feature'Push to the branch:
git push origin my-new-featureCreate a new Pull Request
We optimize for PR readability, so please squash commits before and during the PR review process if you think it will help reviewers and onlookers navigate your changes.
Don’t be afraid to push -f
on your PRs when it helps our eyes read your code.
Install¶
This project uses poetry
as its package manager. For details on poetry
,
see the official documentation .
Install pyenv:
curl https://pyenv.run | bashClone your fork and
cd
into the project:git clone https://github.com/<your-github-username>/unify-client-python cd unify-client-pythonUse
pyenv
to install a compatible Python version (3.6
or newer; e.g.3.7.3
):pyenv install 3.7.3Set that Python version to be your version for this project(e.g.
3.7.3
):pyenv local 3.7.3Check that your Python version matches the version specified in
.python-version
:cat .python-version python --versionInstall
poetry
as described here:curl -sSL https://raw.githubusercontent.com/sdispater/poetry/master/get-poetry.py | pythonInstall dependencies via
poetry
:poetry install
Run style checks¶
To run linter:
poetry run flake8 .
To run formatter:
poetry run black --check .
Run the formatter without the –check flag to fix formatting in-place.
Build docs¶
To build the docs:
cd docs/
poetry run make html
After docs are build, view them by:
cd docs/ # unless you are there already
open -a 'Google Chrome' _build/html/index.html # open in your favorite browser