ipython-contrib / jupyter_contrib_nbextensions

A collection of various notebook extensions for Jupyter
http://jupyter-contrib-nbextensions.readthedocs.io/en/latest
Other
5.22k stars 806 forks source link

[execution_dependencies] [feature_request] Multiple dependencies, one tag #1471

Open Alexis-Prel opened 4 years ago

Alexis-Prel commented 4 years ago

Consider a notebook with the following structure:

# Cell 0 -- tags: #A

# Cell 1 -- tags: #A

# Cell 2 -- tags: =>A

Expected behavior When executing cell 0 or cell 1: they run normally When executing cell 2 : either getting an error message OR having all three cells executed

Actual behavior When executing cell 2: cell 1 and 2 are executed, but not cell 0

I believe a nice addition would be to embrace the HTML/CSS convention of using "#" prefixed attributes for unique id and "." prefixed attributes for classes. So that the above example could be rewritten as

# Cell 0 -- tags: .A

# Cell 1 -- tags: .A

# Cell 2 -- tags: =>.A

Meaning that running cell 2 is expecting to run all cells with that tag.