Skip to content

Latest commit

 

History

History
69 lines (47 loc) · 1.99 KB

CONTRIBUTING.md

File metadata and controls

69 lines (47 loc) · 1.99 KB

Contributing

Everyone that wants to contribute to the project should read this document.

Getting Started

You may follow these steps if you wish to create a pull request. Fork the repo and clone it on your local machine. Then in the project's directory run this if you're on macOS (requires Homebrew):

brew install python
brew install poetry  # More info: https://python-poetry.org
make clean

On Ubuntu (including Windows WSL2):

sudo apt-get update && sudo apt-get install make python3-virtualenv python3
curl -sSL https://install.python-poetry.org | python3 -
make clean

Then see if you can run lints and tests:

make deps all

Writing Tests

For medium to large changes you'll need to include tests in your pull request. This project uses pytest.

Code Style

Code style must remain consistent in this project. When you're done writing your code you can use Black to automatically format Python files:

poetry run black .

Additional code style rules:

  1. Write docstrings for all classes, functions, methods, and modules.
  2. Document all function/method arguments and return values.
  3. Document all class variables instance variables.
  4. Documentation guidelines also apply to tests.
  5. Avoid isinstance() (it breaks duck typing).

Updating Docs

If you're adding a new feature you'll need to update the Sphinx documentation for this project. Docs are located in the docs directory and can be written using reStructuredText or Markdown.

To locally build docs and view them in a browser you can run:

make docs

Then browse to: docs/_build/html/index.html

Thank You!

Thanks for fixing bugs or adding features to the project!