Names of outputs collected from tagged jupyter notebook cells is vulnerable to collisions #7302
Labels
bug
Something isn't working
embed
triaged-to
Issues that were not self-assigned, signals that an issue was assigned to someone.
Milestone
Bug description
First: I'd like to celebrate since this is my first ever bug report I'm submitting to a project on github! 🥳 I cannot think of a more deserving project which I really want to see succeed.
That out of the way--I seem to have found a very frustrating bug. If I try to embed plots from two different notebooks in the same qmd file, a collision occurs if the plots come from the same cell number in the respective notebooks.
i.e. if I have two notebooks, and I embed their respective first cells in a .qmd document, their outputs will both be
cell-2-output-1.png
, so one will overwrite the other in the main document.Steps to reproduce
This is what my document looks like:
nb1 and nb2 are single cell notebooks with a simple plot output from matplotlib.
I have link to a reproducer repo here: https://github.com/e-miz/quarto-jup-emebed-collision
Simply run
quarto render maindoc.qmd
to generate the output.Expected behavior
I would have expected that I can embed content from multiple distinct notebooks which happen to share cell numbers in the same document.
Actual behavior
Essentially what happens is because both notebooks output
cell-2-output-1.png
, the one embedded last overrides the other in the main document. Unfortunately, I can't figure out how to control quarto to append or prepend some kind of string to the output filenames from each notebook to prevent this from happening.Your environment
IDE:
VSCode Version: 1.83.1 (system setup)
Commit: f1 b07bd25dfad€4b0167beb15359ae573aecd2cc
Date: (1 wk ago)
Electron: 25.8.4
ElectronBuildld: 24154031
Chromium: 114.0.5735.289
Nodejs: 18.15.0
V8: 11.4.183.29-electron.0
OS: Windows NTx64 10.0.19045
OS:
WSL2
NAME="Ubuntu"
VERSION="20.04.6 LTS (Focal Fossa)"
Quarto check output
Quarto 1.4.429 [✓] Checking versions of quarto binary dependencies... Pandoc version 3.1.8: OK Dart Sass version 1.55.0: OK Deno version 1.33.4: OK [✓] Checking versions of quarto dependencies......OK [✓] Checking Quarto installation......OK Version: 1.4.429 Path: /opt/quarto/bin [✓] Checking tools....................OK TinyTeX: v2023.10 Chromium: 869685 [✓] Checking LaTeX....................OK Using: TinyTex Path: /home/emiz/.TinyTeX/bin/x86_64-linux Version: 2023 [✓] Checking basic markdown render....OK [✓] Checking Python 3 installation....OK Version: 3.11.5 (Conda) Path: /home/emiz/miniconda3/envs/sv_SEDecayTime/bin/python Jupyter: 5.4.0 Kernels: python3 (-) Checking Jupyter engine render....0.00s - Debugger warning: It seems that frozen modules are being used, which may 0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off 0.00s - to python to disable frozen modules. 0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. (|) Checking Jupyter engine render....0.00s - Debugger warning: It seems that frozen modules are being used, which may 0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off 0.00s - to python to disable frozen modules. 0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. [✓] Checking Jupyter engine render....OK [✓] Checking R installation...........(None) Unable to locate an installed version of R. Install R from https://cloud.r-project.org/
The text was updated successfully, but these errors were encountered: