Skip to content

Commit a060a48

Browse files
jeremymanningclaude
andcommitted
Fix Read the Docs nbsphinx kernel error
- Add environment detection to disable notebook execution on Read the Docs - Set nbsphinx_execute = 'never' for READTHEDOCS environment - Keep nbsphinx_execute = 'auto' for local builds - Resolves NoSuchKernel error during Read the Docs build process 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent 16c40e4 commit a060a48

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

docs/conf.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,14 @@
4141
# allow nbsphinx errors for missing optional dependencies
4242
nbsphinx_allow_errors = True
4343

44+
# Don't execute notebooks during documentation build (for Read the Docs)
45+
# Check if we're on Read the Docs environment
46+
import os
47+
if os.environ.get('READTHEDOCS', None) == 'True':
48+
nbsphinx_execute = 'never'
49+
else:
50+
nbsphinx_execute = 'auto'
51+
4452
# Generate the API documentation when building
4553
autosummary_generate = True
4654

0 commit comments

Comments
 (0)