papermill icon indicating copy to clipboard operation
papermill copied to clipboard

Implement --remove-tagged-cells

Open astrofrog opened this issue 2 years ago β€’ 9 comments

This implements a new --remote-tagged-cells option as described by @MSeal in https://github.com/nteract/papermill/issues/429#issuecomment-642806948. The idea of the current implementation is to keep it as simple as possible – only being able to specify a single tag and requiring an exact match (no regular expressions etc). My personal use case for this is being able to run notebooks with/without diagnostic plotting but there are other use cases described in https://github.com/nteract/papermill/issues/429.

If the maintainers are on board with this PR so far, I can add documentation and anything else required.

One thought I had was that perhaps this option would read more clearly as --remove-cells-with-tag otherwise it sounds like a boolean option, and also doesn't make it clear that a single tag is what should be passed in. What do people think about this?

astrofrog avatar Nov 09 '23 12:11 astrofrog

Check out this pull request onΒ  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

Thanks @astrofrog (nice to see you here). It looks like some of the CLI tests still need updating. It also looks like botocore is being grumpy with python 3.12.

willingc avatar Nov 14 '23 04:11 willingc

Thanks @astrofrog -- on the botocore build part I am working on getting a new release out anyway and need to fix dep updates since the last one regardless.

MSeal avatar Nov 15 '23 23:11 MSeal

Looks like tests are failing now due to some test scaffolding including the input_path in the arguments.

MSeal avatar Nov 16 '23 16:11 MSeal

Is there something I could do to move this PR forward, having been the instigator of #429 back in 2019? 😁 (We've used a custom fork of Papermill in the meantime, but it's fallen quite out of repair, so it'd be nice to use the upstream version.)

akx avatar Dec 18 '23 14:12 akx

Any updates on this? I am also interested in this feature and will appreciate push on it Thank you

andreytaboola avatar Jul 03 '24 12:07 andreytaboola