GPJax welcomes contributions from interested individuals or groups. There are many ways to contribute, including:
- Answering questions on our discussions page.
- Raising issues related to bugs or desired enhancements.
- Contributing or improving the docs or examples.
- Fixing outstanding issues (bugs).
- Extending or improving our codebase.
As a contributor to GPJax, you can help us keep the community open and inclusive. Please read and follow our Code of Conduct.
Please open issues on Github Issue Tracker. Here you can mention
You can ask a question or start a discussion in the Discussion section on Github.
Submitting code contributions to GPJax is done via a GitHub pull
Our preferred workflow is to first fork the GitHub
repository, clone it to your local
machine, and develop on a feature branch. Once you're happy with your changes,
push your code.
New to this? Don't panic, our guide below will walk you through every detail!
Before opening a pull request we recommend you check our pull request checklist.
Clone your GPJax fork from your GitHub account to your local disk, and add the base repository as a remote:
featurebranch to hold your development changes:
featurebranch. It's good practice to avoid work on the
mainbranch of any repository.
- We use Poetry for packaging and dependency management, and project requirements are in
pyproject.toml. We suggest using a virtual environment for development. For those using Apple Silicon chips, we advise using Conda miniforge. Once the virtual environment is activated, run:
At this point we recommend you check your installation passes the supplied unit tests:
- Install the pre-commit hooks.
Please ensure you have done this before committing any files. If
successful, this will print the following output
pre-commit installed at
- At this point you can manually run the pre-commit hooks with the following command:
- Add changed files using
git addand then
git commitfiles to record your changes locally:
Then push the changes to your GitHub account with:
- Go to the GitHub web page of your fork of the GPJax repo. Click the 'Pull request' button to send your changes to the project's maintainers for review.
We welcome both complete or "work in progress" pull requests. Before opening one, we recommended you check the following guidelines to ensure a smooth review process.
My contribution is a "work in progress":
Please prefix the title of incomplete contributions with
[WIP] (to indicate a
work in progress). WIPs are useful to:
- Indicate you are working on something to avoid duplicated work.
- Request broad review of functionality or API.
- Seek collaborators.
In the description of the pull request, we recommend you outline where work needs doing. For example, do some tests need writing?
My contribution is complete:
If addressing an issue, please use the pull request title to describe the issue and mention the issue number in the pull request description. This will make sure a link back to the original issue is created. Then before making your pull request, we recommend you check the following:
- Do all public methods have informative docstrings that describe their function, input(s) and output(s)?
- Do the pre-commit hooks pass?
- Do the tests pass when everything is rebuilt from scratch?
Documentation and high-coverage tests are necessary for enhancements to be accepted. Test coverage can be checked with:
Navigate to the newly created folder
htmlcov and open
index.html to view
the coverage report.
This guide was derived from PyMC's guide to contributing.