Contributing

Thank you for your interest in contributing to Django-AWS-API-Gateway-WebSockets.

Ways to contribute

You can help by:

  • reporting bugs;

  • improving documentation;

  • adding tests;

  • fixing issues;

  • proposing new features;

  • reviewing pull requests.

Development setup

Fork the repository and clone your fork locally.

Install the development requirements that match the Python and Django versions you want to test against.

Install pre-commit hooks:

pre-commit install

Running tests

Run the test suite with coverage:

coverage erase
python -W error::DeprecationWarning -W error::PendingDeprecationWarning -m coverage run --parallel -m pytest --ds tests.settings
coverage combine
coverage report

Pull requests

Before opening a pull request:

  1. Check for an existing issue or open a new one.

  2. Add or update tests for your change.

  3. Update documentation where appropriate.

  4. Run the test suite.

  5. Run pre-commit checks.

  6. Add yourself to AUTHORS if appropriate.

  7. Open a pull request against the main repository.

Documentation changes

Documentation is built with Sphinx.

To build the docs locally:

cd docs
make html

The generated HTML will be available under docs/_build/html.

Style guidelines

When contributing code:

  • keep changes focused;

  • prefer readable code over clever code;

  • include tests for bug fixes and new functionality;

  • avoid unrelated formatting changes;

  • document public behaviour.