Skip to content

Latest commit

 

History

History
31 lines (21 loc) · 2.56 KB

CONTRIBUTING.md

File metadata and controls

31 lines (21 loc) · 2.56 KB

How to contribute

This project is developed using nbdev, a way to create delightful software with Jupyter notebooks. The Python library and docs are automatically created from the notebooks in the /nbs directory.

How to get started

Note: nbdev works on macOS, Linux, and most Unix-style operating systems. It works on Windows under WSL, but some features will not work under cmd or Powershell.

Follow the install nbdev instructions, specifically:

  1. Install jupyter notebook
  2. Install nbdev
  3. Install quarto
  4. After cloning the repository, run this command inside it: nbdev_install_hooks
  5. Run nbdev_export inside the project directory
  6. Run pip install -e '.[dev]' inside the project directory

Visit https://hugetim.github.io/nbstata/dev_docs_index.html to get oriented.

How to submit notebook PRs

After making changes to the /nbs notebooks, you should run nbdev_prepare and make any necessary changes in order to pass all the tests.

(You may also make limited changes directly to the .py files in the /nbstata folder, in which case you should sync those changes back to the notebooks with nbdev_update.)

ReviewNB gives us visual diffs for notebooks and enables PR comments specific to a cell: https://app.reviewnb.com/hugetim/nbstata/ (free account needed to login)

Do you want to contribute to the documentation?

  • Docs are automatically created from the notebooks in the /nbs folder.
  • You can preview the docs locally by running nbdev_preview. While in preview mode, you can make updates to notebooks and they will be reflected (after a small delay) in your browser.

Specifics to be aware of

  • The @patch_to decorator is occasionally used to break up class definitions into separate cells.