- Ensure the bug was not already reported by searching on GitHub under Issues.
- If you're unable to find an open issue addressing the problem, open a new one. Be sure to include a title and clear description, as much relevant information as possible, and a code sample or an executable test case demonstrating the expected behavior that is not occurring.
- Be sure to add the complete error messages.
- Ensure that it hasn't been yet implemented in the
main
branch of the repository and that there's not an Issue requesting it yet. - Open a new issue and make sure to describe it clearly, mention how it improves the project and why its useful.
Bug fixes and features are added through pull requests (PRs).
- Keep each PR focused. While it's more convenient, do not combine several unrelated fixes together. Create as many branches as needing to keep each PR focused.
- Ensure that your PR includes a test that fails without your patch, and passes with it.
- Ensure the PR description clearly describes the problem and solution. Include the relevant issue number if applicable.
- Do not mix style changes/fixes with "functional" changes. It's very difficult to review such PRs and it most likely get rejected.
- Do not add/remove vertical whitespace. Preserve the original style of the file you edit as much as you can.
- Do not turn an already submitted PR into your development playground. If after you submitted PR, you discovered that more work is needed - close the PR, do the required work and then submit a new PR. Otherwise each of your commits requires attention from maintainers of the project.
- If, however, you submitted a PR and received a request for changes, you should proceed with commits inside that PR, so that the maintainer can see the incremental fixes and won't need to review the whole PR again. In the exception case where you realize it'll take many many commits to complete the requests, then it's probably best to close the PR, do the work and then submit it again. Use common sense where you'd choose one way over another.
- HTTPS:
git clone https://github.com/Nixtla/mlforecast.git
- SSH:
git clone [email protected]:Nixtla/mlforecast.git
- GitHub CLI:
gh repo clone Nixtla/mlforecast
The repo comes with an environment.yml
file which contains the libraries needed to run all the tests (please note that the distributed interface is only available on Linux). In order to set up the environment you must have conda/mamba
installed, we recommend mambaforge.
Once you have conda/mamba
go to the top level directory of the repository and run:
{conda|mamba} env create -f environment.yml
Once you have your environment setup, activate it using conda activate mlforecast
.
From the top level directory of the repository run: pip install ".[dev]"
From the top level directory of the repository run: pip install -e .[dev]
Run pre-commit install
The library is built using the notebooks contained in the nbs
folder. If you want to make any changes to the library you have to find the relevant notebook, make your changes and then call nbdev_export
.
- If you're working on the local interface, use
nbdev_test --skip_file_glob "distributed*" --n_workers 1
. - If you're modifying the distributed interface run the tests using
nbdev_test --n_workers 1
.
Run ./action_files/lint
Run ./action_files/clean_nbs
- Docs are automatically created from the notebooks in the
nbs
folder. - In order to modify the documentation:
- Find the relevant notebook.
- Make your changes.
- Run all cells.
- Run
nbdev_preview
- If you modified the
index.ipynb
notebook, runnbdev_readme
.