PlasmaControl / DESC

Stellarator Equilibrium and Optimization Suite
MIT License
98 stars 26 forks source link

Strip kernel info from jupyter notebooks #1215

Open dpanici opened 3 months ago

dpanici commented 3 months ago

If you use jupyter locally, you often change the kernel to match your conda env (desc-env or whatever), but the CI does not make a conda env, they just install in the base python environment. This causes issues where the jupyter wants to find desc-env but cannot, and you have to instead manually change the kernel of the jupyter back to the base Python kernel before saving and uploading to git.

Would be nice to automatically strip the kernel info to avoid this annoyance

dpanici commented 3 weeks ago

pre-commit hook to check if a notebook was changed and if so, to strip the kernel info from it