vatlab/sos-notebook

Notebook saves unused kernels.

BoPeng opened this issue · 1 comments

Opening a notebook in a machine will modify the meta information of the notebook with kernels of the current machine, leading to unexpected changes of the notebook. We should only save kernels that are actually used in the notebook.

The problem here is that we use IPython.notebook.metadata to keep kernel information. Because this information has to reflect supported kernels of the current machine, it cannot be changed when the notebook is open, so we cannot modify metadata when files are changed.

The only possibility is to use a hook to change meta information when the notebook is written to disk.