Contributing¶
We welcome contributions to Django Comb.
Bug reports¶
Report a bug by opening a Github issue.
Feature requests and feedback¶
Send feedback or request a new feature by opening a Github issue.
Submitting pull requests¶
Before spending time working on a pull request, we highly recommend filing a Github issue and engaging with the project maintainer to align on the direction you're planning to take. This can save a lot of your precious time!
This doesn't apply to trivial pull requests such as spelling corrections.
Development¶
System prerequisites¶
Make sure these are installed first.
Setup¶
You don't need to activate or manage a virtual environment - this is taken care in the background of by uv.
- Fork django-comb (look for the "Fork" button).
-
Clone your fork locally:
-
Change into the directory you just cloned:
-
Set up pre-commit. (Optional, but recommended.):
You will now be able to run commands prefixed with just, providing you're in the django-comb directory.
To see available commands, run just.
Formatting code¶
Running linters¶
Running tests¶
When you're developing a feature, you'll probably want to run tests quickly, using just the latest supported Python version:
You can also pass a specific Python version, e.g. just test --python=3.13.
If you want to invoke pytest directly, e.g. to run a specific test, just use uv run pytest, e.g.:
Finally, you can run all the tests under all supported Python versions with just test-all. This gives a more complete
picture of whether the changes are compatible with all supported versions. Additionally, it will run tests under the
lowest versions of dependencies specified in pyproject.toml, with the lowest supported Python version.
Building documentation¶
To view docs locally:
Releasing to Pypi¶
(Only maintainers can do this.)
- Choose a new version number (based on semver).
git pull origin main- Update
docs/release_notes.mdwith the new version number. - Update the
__version__variable insrc/django_comb/__init__.pywith the new version number. - Update
project.versioninpyproject.tomlwith the new version number. git commit -am "Release v{new version number"git push- Wait for tests to pass on CI.
git tag v{new version number}git push --tags- This should kick start the Github
releaseworkflow which releases the project to PyPI.