With nbconvert 5.3 you cannot use the ExecutePreprocessor and filter outputs at the same time #663
Labels
good first issue
great for new contributors
Preprocessor:Execute
Preprocessor:TagRemove
Preprocessor
TagRemovePreprocessor
currently handles removing cells, inputs, all outputs and individual outputs. It runs before theExecutePreprocessor
runs.As a result, once
ExecutePreprocessor
runs, it recreates the outputs that should have been filtered out byTagRemovePreprocessor
.The simplest solution is to rerun
TagRemovePreprocessor
but that seems wasteful.The other solution would be to create a subclass of
TagRemovePreprocessor
called something likeOutputTagRemovePreprocessor
that inherits the traitlet values, but overwrites thepreprocess_cell
method to only filter outputs (adhering to bothremove_all_outputs_tags
andremove_single_output_tags
). Then invoke this new preprocessor after all other preprocessors have run. This would make sense to appear in the baseExporter
class.The text was updated successfully, but these errors were encountered: