jupyter-sphinx icon indicating copy to clipboard operation
jupyter-sphinx copied to clipboard

Feature request: allow temporarily suppressing execution of cells

Open slavoutich opened this issue 4 years ago • 1 comments

Problem that I would like to solve is to avoid cells compilation, that can be quite slow, when it is not needed. For example, one wants to build Sphinx documentation to check if cross-referencing between classes/functions is done right. Checking this does not require Jupyter cell execution, but this task can easily take on the order of several minutes, depending on how heavily jupyter-sphinx is used.

I propose to make jupyter-sphinx compilation to be suppressable by some environment variable, for example:

make JUPYTER_SPHINX_SUPPRESS=true html

In this case, outputs of jupyter-sphinx can be replaced by some dummy output instead of actually executed results, which should speed up compilation a lot.

slavoutich avatar Apr 08 '21 15:04 slavoutich

That's exactly what I was looking for as well. E.g. when running link checking with sphinx it would be great to disable execution of Jupyter cells.

One solution would be to add a config option, which can be used to disable execution of cells globally and which can then be easily set when running sphinx on the command line.

hagenw avatar Oct 15 '21 07:10 hagenw