Read metadata from kernelspec files to map to VS Code kernels.
See original GitHub issueAs mentioned in this comment, the experience with .NET Interactive notebooks would benefit greatly if certain Jupyter kernels could be hidden from the user on kernel select AND if this same mechanism could be used to assign the appropriate kernel on notebook open.
E.g.,
If the C# kernelspec added this:
...
"metadata": {
"vscode-extension": "ms-dotnettools.dotnet-interactive-vscode"
}
...
Then we’d like the kernel selector list to only show the in-memory VS Code kernel (as exposed by registerNotebookKernelProvider
) because the extension that provides that kernel happens to match the vscode-extension
metadata value.
Without this the user is shown 4 different kernels: “.NET (C#)”, “.NET (F#)”, “.NET (PowerShell)”, and “.NET Interactive”, but this can be confusing and not give a great experience. The first 3 kernels are Jupyter-specific kernelspec files and offer the basic Jupyter functionality, but if the last option of “.NET Interactive” is selected, then the user will also get rich IntelliSense, etc.
I’m not too concerned about the final name of vscode-extension
; we’ll leave that decision up to you to decide.
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (8 by maintainers)
Top GitHub Comments
Thanks, here’s the revised condition (hide only if .NET interactive extension is available in VS Code)
I chatted with my team and we think the best approach will be my most recent suggestion of:
I should note, however, that when you’re testing locally, you’ll need to set
kernel_id
toundefined
because the current version of our extension doesn’t set the kernel ID, but in the future we’ll set it to"dotnet-interactive"
and we’ll be sure to update our kernelspec files with the same change.E.g.,