192 add and test tutorials in documentation#250
192 add and test tutorials in documentation#250JessieGould wants to merge 20 commits intostfc:mainfrom
Conversation
nbsphinx, ] in docs/source/conf.py for extension that gives ability to embed notebook as source file in sphinx html
…inx to conf.py and notebooks/singlepoint to source/user_guide/index.rst toctree. make clean; make (required sudo apt install pandoc and uv pip install nbsphinx.)
…uld revert this before publishing)
|
"We should consider moving the current tutorials into the documentation, ..." "...and testing them. See stfc/janus-core#399." " This may also include removing/reworking the current Usage and Tutorial sections. " |
JessieGould
left a comment
There was a problem hiding this comment.
consider removing pandoc from toml? ie is it necessary
There was a problem hiding this comment.
Pull Request Overview
This PR adds tutorial notebooks to the documentation and configures the necessary tooling to render them. The main additions are four Jupyter notebook tutorials covering single point calculations, descriptors, geometry optimisation, and high-throughput screening.
- Adds nbsphinx and pandoc dependencies for rendering Jupyter notebooks in documentation
- Includes four comprehensive tutorial notebooks demonstrating various calculation types
- Updates function name from
generate_node_graphtogenerate_provenance_graphin example code - Fixes a duplicate word typo in developer documentation
Reviewed Changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| pyproject.toml | Adds nbsphinx and pandoc dependencies to docs dependency group |
| docs/source/conf.py | Configures nbsphinx extension with error allowance |
| docs/source/user_guide/index.rst | Adds four new notebook entries to user guide |
| docs/source/user_guide/notebooks/singlepoint.ipynb | New tutorial for single point calculations |
| docs/source/user_guide/notebooks/descriptors.ipynb | New tutorial for descriptor calculations |
| docs/source/user_guide/notebooks/geometry-optimisation.ipynb | New tutorial for geometry optimisation |
| docs/source/user_guide/notebooks/high-throughput-screening.ipynb | New tutorial for high-throughput screening |
| examples/tutorials/workgraphs/simple_workgraph.ipynb | Updates function name to generate_provenance_graph |
| docs/source/developer_guide/index.rst | Fixes duplicate word "individual" |
| .github/workflows/docs.yml | Adds pandoc installation step |
| .github/workflows/ci.yml | Adds pandoc installation step |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Issues:
These will display differently online as they do in a local build so its difficult to know what will need fixing / whether these would work. |
We can probably get it programatically e.g.
We can use a path relative to the file that the notebook is in e.g. via If it works on linux (WSL), we can always describe any minor changes that are needed, or generally warn that the path may need correcting.
What does this mean?
Do you mean local as in your version of the built documentation, or local as in your version of the notebook itself? If you're running in WSL and looking at the built docs, it shouldn't be too different, barring set-up differences. If that's still a concern, you can temporarily get it to build on your fork instead, but that's a bit of a process (I'd probably do it on a new branch so it doesn't affect this PR, but you'd need to set up your fork permissions correctly, change the workflow to build on non-STFC repos, etc.) |
|
the following changes have been made and should cover the above issues
To consider:
|
closes #192