Skip to content

Add jupyter kernelspec list/remove --missing to list/remove all missing kernels.

Open

Description

I often install kernels from project virtualenvs (my-project/.venv/) that eventually get removed. I can manually remove a kernelspec with jupyter kernelspec remove my-project but forget to do this, then forget the missing kernel name, etc. Instead, I use a script that checks if the python executable the kernel points to exists, and if it doesn't, removes the kernel. A command jupyter kernelspec remove --missing would save users (myself) some pain.

Alternatively, it might be simpler to add jupyter kernelspec list --missing which would list out kernels with missing python interpreters, and a user can pipe this to jupyter kernelspec remove.

I'd be happy to attempt a PR with one or both of these features if you agree. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions