mcq_helper.py code
import ipywidgets as widgets
from IPython.display import display
import sys
output = widgets.Output()
if __name__ == '__main__':
question = sys.argv[1]
options = sys.argv[2:]
with output:
display(widgets.RadioButtons(options=options, description=question))
display(output)
I'm serving jupyterlab from my server. I would like to achieve the following:
- Instead of writing
%runcommand in the cell explicitly, I want it to run by default every time a cell is executed. - I want to hide the cell soon as it is executed, and only the output to be visible.
How can I do that?

%runor!pythonwouldn't be allowed (I think), you'd have to change how you triggermcq_helper.py. Practically since it is small it would be easier to build that into the notebook, or at least import it early in your notebook as a function you can call. Or something along those lines.