Python packaging made simple. Recommendations & guidance curated by the pyOpenSci community
See the code
pyOpenSci Python Packaging Guide and TutorialspyOpenSci is devoted to building diverse, supportive community around the Python open source tools that drive open science. We do this through:
pyOpenSci is an independent organization, fiscally sponsored by Community Initiatives.
This repository contains the source files for the pyOpenSci Python packaging guide.
Our guidebook is built with Sphinx which is a documentation tool and uses the pydata-sphinx-theme.
The easiest way to build our documentation is to use the nox automation tool,
a tool for quickly building environments and running
commands within them.
Using nox ensures that your environment has all the dependencies needed to build the documentation.
To build, follow these steps:
Install nox
python -m pip install nox
Build the documentation:
nox -s docs
This should create a local environment in a .nox folder, build the documentation (as specified in the noxfile.py configuration), and the output will be in _build/html.
To build live documentation that updates when you update local files, run the following command:
nox -s docs-live
If you are a uv user, you can also skip installing nox and use uvx instead:
uvx nox -s docs-live
When building for release, the docs are built multiple times for each translation, but translations are only included in the production version of the guide after some completion threshold.
The sphinx build environment is controlled by an environment variable SPHINX_ENV
SPHINX_ENV=development (default), sphinx assumes all languages are built,
and includes them in the language selectorSPHINX_ENV=production, only those languages in release_languages (set in conf.py)
are built and included in the language selector.Most of the time you should not need to set SPHINX_ENV,
as it is forced by the primary nox sessions intended to be used for release or development:
SPHINX_ENV=development
docs-live - autobuild englishdocs-live-lang - autobuild a single languagedocs-live-langs - autobuild all languagesSPHINX_ENV=production
build-test - build all languages for productionWe welcome and issues and pull requests to improve the content of this guide. If you'd like to see an improvement, please open an issue.
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specification. Contributions of any kind welcome!
(top 30 of 74)
Python
77.2%
CSS
17.6%
TeX
2.2%
HTML
1.5%
JavaScript
1.5%
Python packaging made simple. Recommendations & guidance curated by the pyOpenSci community
See the code
pyOpenSci Python Packaging Guide and TutorialspyOpenSci is devoted to building diverse, supportive community around the Python open source tools that drive open science. We do this through:
pyOpenSci is an independent organization, fiscally sponsored by Community Initiatives.
This repository contains the source files for the pyOpenSci Python packaging guide.
Our guidebook is built with Sphinx which is a documentation tool and uses the pydata-sphinx-theme.
The easiest way to build our documentation is to use the nox automation tool,
a tool for quickly building environments and running
commands within them.
Using nox ensures that your environment has all the dependencies needed to build the documentation.
To build, follow these steps:
Install nox
python -m pip install nox
Build the documentation:
nox -s docs
This should create a local environment in a .nox folder, build the documentation (as specified in the noxfile.py configuration), and the output will be in _build/html.
To build live documentation that updates when you update local files, run the following command:
nox -s docs-live
If you are a uv user, you can also skip installing nox and use uvx instead:
uvx nox -s docs-live
When building for release, the docs are built multiple times for each translation, but translations are only included in the production version of the guide after some completion threshold.
The sphinx build environment is controlled by an environment variable SPHINX_ENV
SPHINX_ENV=development (default), sphinx assumes all languages are built,
and includes them in the language selectorSPHINX_ENV=production, only those languages in release_languages (set in conf.py)
are built and included in the language selector.Most of the time you should not need to set SPHINX_ENV,
as it is forced by the primary nox sessions intended to be used for release or development:
SPHINX_ENV=development
docs-live - autobuild englishdocs-live-lang - autobuild a single languagedocs-live-langs - autobuild all languagesSPHINX_ENV=production
build-test - build all languages for productionWe welcome and issues and pull requests to improve the content of this guide. If you'd like to see an improvement, please open an issue.
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specification. Contributions of any kind welcome!
(top 30 of 74)
Python
77.2%
CSS
17.6%
TeX
2.2%
HTML
1.5%
JavaScript
1.5%