quarto-dev / quarto-dev/quarto-cli
Embedded notebook cells do not show source references in book format
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 6k
- Forks
- 458
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 41
Description
Bug description
The embedded notebook cell feature does not produce source links to the notebook when used in book format. I would have expected this feature to work in book format, too - at a minimum, when the book output format is HTML (though it may apply to other formats, too, as long as the notebook is included in the book somewhere).
I can see situations where the book includes code snippets along the way with the entire notebook available in the appendix, and having the ability to click through to the entire notebook would be awesome.
This does not seem to be controlled by notebook-links or notebook-view settings - changing them has no impact.
Steps to reproduce
Embed a cell from a notebook foo.ipynb into a document using shortcode:
{{< embed foo.ipynb#foo >}}
Expected behavior
The rendered page should include both the content of the notebook cell as well as a source reference to it.
Actual behavior
The rendered page only includes the content of the notebook cell.
Your environment
- IDE: VSCode
- Quarto version: 1.4.537
- WSL 2 with Ubuntu
Quarto check output
Quarto 1.4.537
[✓] Checking versions of quarto binary dependencies...
Pandoc version 3.1.11: OK
Dart Sass version 1.69.5: OK
Deno version 1.37.2: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
Version: 1.4.537
Path: /opt/quarto/bin
[✓] Checking tools....................OK
TinyTeX: (external install)
Chromium: (not installed)
[✓] Checking LaTeX....................OK
Using: TinyTex
Path: /home/aurimas/.TinyTeX/bin/x86_64-linux
Version: 2021
[✓] Checking basic markdown render....OK
[✓] Checking Python 3 installation....OK
Version: 3.11.5 (Conda)
Path: /home/aurimas/micromamba/envs/confluence/bin/python
Jupyter: 5.3.2
Kernels: bsfinal, gp-processes, idendro, pymc3, bayes, python3, ncr, homecourt, pymc4, julia-1.9, cse6242hw4, ir, css, julia-1.6, bayesian, anaconda-real, strongarm, cse6242project, pdfparser
Traceback (most recent call last):
File "/opt/quarto/share/jupyter/jupyter.py", line 21, in
from notebook import notebook_execute, RestartKernel
File "/opt/quarto/share/jupyter/notebook.py", line 14, in
from yaml import safe_load
ModuleNotFoundError: No module named 'yaml'
[✓] Checking Jupyter engine render....OK
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Use the embed foo.ipynb#foo shortcode as the reproduction entry point and compare its behavior in an HTML book while checking whether notebook-links or notebook-view affects the result. Done means the rendered cell includes a source reference to the notebook when that notebook is included in the book.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, jupyter
- Domain
- documentation
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100