sphinx-pyrunblock
Fast, in-process embedding of live Python code output into your Sphinx docs.
sphinx-pyrunblock runs each .. runblock:: example directly in a shared
interpreter rather than spawning a subprocess per block — and it's backward
compatible with sphinx-autorun: same runblock directive, same
autorun_languages config shape, drop-in upgrade.
.. runblock:: pycon
>>> for i in range(5):
... print(i)
Produces:
>>> for i in range(5):
... print(i)
0
1
2
3
4
Installation
$ pip install sphinx-pyrunblock
Enable the extension by adding it to the extensions list in conf.py:
extensions.append("sphinx_pyrunblock")
See the full documentation
for configuration (conf.py options, runfirst setup), per-block directive
options (:numpy:, :scipy:, :smtb:, :precision:, :include:,
:exclude:), and how errors are reported during a build.
Heritage
sphinx-pyrunblock began as a fork of
sphinx-autorun by Hugo
Osvaldo Barrera, itself descended from Vadim Gubergrits' original
sphinxcontrib-autorun. See the
full history
for the complete lineage.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sphinx_pyrunblock-1.0.1.tar.gz.
File metadata
- Download URL: sphinx_pyrunblock-1.0.1.tar.gz
- Upload date:
- Size: 14.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7e303f82b7f0b0e0972bf9fcb0473532970a40e14c570d3c1a101a44be4854f8
|
|
| MD5 |
97688039d1a6c322fe181c0c025cb75d
|
|
| BLAKE2b-256 |
1f4c889c4a4f3d1d257c1b3f0b17e8bc3b5817d3bacc4c5e294c5e259abd1a7b
|
Provenance
The following attestation bundles were made for sphinx_pyrunblock-1.0.1.tar.gz:
Publisher:
release.yml on petercorke/sphinx-pyrunblock
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sphinx_pyrunblock-1.0.1.tar.gz -
Subject digest:
7e303f82b7f0b0e0972bf9fcb0473532970a40e14c570d3c1a101a44be4854f8 - Sigstore transparency entry: 2278902787
- Sigstore integration time:
-
Permalink:
petercorke/sphinx-pyrunblock@19165c7f2000d3a835b4eaf49e0225933eebd1cf -
Branch / Tag:
refs/heads/main - Owner: https://github.com/petercorke
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@19165c7f2000d3a835b4eaf49e0225933eebd1cf -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file sphinx_pyrunblock-1.0.1-py3-none-any.whl.
File metadata
- Download URL: sphinx_pyrunblock-1.0.1-py3-none-any.whl
- Upload date:
- Size: 9.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e4dbfc7d37043c87277253cb6d388dfe391accd1eb0554ce254ef3b432795412
|
|
| MD5 |
8c49ac9af2be420b0a1d1b9dcf357aae
|
|
| BLAKE2b-256 |
fb13505078b6979d7891309f460cde46d23cd55eca97163c372d94a11ee1e45d
|
Provenance
The following attestation bundles were made for sphinx_pyrunblock-1.0.1-py3-none-any.whl:
Publisher:
release.yml on petercorke/sphinx-pyrunblock
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sphinx_pyrunblock-1.0.1-py3-none-any.whl -
Subject digest:
e4dbfc7d37043c87277253cb6d388dfe391accd1eb0554ce254ef3b432795412 - Sigstore transparency entry: 2278902823
- Sigstore integration time:
-
Permalink:
petercorke/sphinx-pyrunblock@19165c7f2000d3a835b4eaf49e0225933eebd1cf -
Branch / Tag:
refs/heads/main - Owner: https://github.com/petercorke
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@19165c7f2000d3a835b4eaf49e0225933eebd1cf -
Trigger Event:
workflow_dispatch
-
Statement type: