Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename trait to allowed_kernelspecs #672

Merged
merged 9 commits into from
Aug 5, 2021

Conversation

blink1073
Copy link
Member

@blink1073 blink1073 commented Aug 4, 2021

Partially addresses #642 by deprecating KernelSpecManager.whitelist in favor of the more descriptive and inclusive KernelSpecManager.allowed_kernelspecs.

@blink1073 blink1073 added this to the 7.0 milestone Aug 4, 2021
Copy link
Member

@kevin-bates kevin-bates left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes look good Steve, thank you for providing this. I just had a couple of comments. I've run with this branch and see the appropriate deprecation warning:

[W 14:52:14.292 NotebookApp] KernelSpecManager.whitelist is deprecated in JupyterLab 7.0, use KernelSpecManager.allowed_kernel_names instead

My first thought on the trait name was allowed_kernels but I think allowed_kernel_names is more correct. I suppose another option would be allowed_kernelspecs so that kernel names aren't accidentally interpreted as "ipykernel" or "xeus-python", etc. i.e., the literal kernel name.

jupyter_client/kernelspec.py Outdated Show resolved Hide resolved
jupyter_client/kernelspec.py Outdated Show resolved Hide resolved
blink1073 and others added 2 commits August 4, 2021 17:21
Co-authored-by: Kevin Bates <kbates4@gmail.com>
Co-authored-by: Kevin Bates <kbates4@gmail.com>
Copy link
Member

@kevin-bates kevin-bates left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Per a sidebar, I've suggested the trait name be allowed_kernelspecs to potentially avoid ambiguity.

The title could probably use an update as well, but didn't want to assume the suggestions would be accepted. 😄

jupyter_client/kernelspec.py Outdated Show resolved Hide resolved
jupyter_client/kernelspec.py Outdated Show resolved Hide resolved
jupyter_client/kernelspec.py Outdated Show resolved Hide resolved
jupyter_client/kernelspec.py Outdated Show resolved Hide resolved
jupyter_client/kernelspec.py Outdated Show resolved Hide resolved
jupyter_client/tests/test_kernelspec.py Outdated Show resolved Hide resolved
blink1073 and others added 4 commits August 4, 2021 20:17
Co-authored-by: Kevin Bates <kbates4@gmail.com>
Co-authored-by: Kevin Bates <kbates4@gmail.com>
Co-authored-by: Kevin Bates <kbates4@gmail.com>
Co-authored-by: Kevin Bates <kbates4@gmail.com>
@blink1073 blink1073 changed the title Rename trait to allowed_kernel_names Rename trait to allowed_kernelspecs Aug 5, 2021
blink1073 and others added 2 commits August 4, 2021 20:18
Co-authored-by: Kevin Bates <kbates4@gmail.com>
Co-authored-by: Kevin Bates <kbates4@gmail.com>
@blink1073
Copy link
Member Author

Thanks! I updated the title and description accordingly.

@blink1073 blink1073 merged commit 279de89 into jupyter:master Aug 5, 2021
@blink1073 blink1073 deleted the use-allowlist-trait branch August 5, 2021 01:38
@vidartf
Copy link
Contributor

vidartf commented Aug 6, 2021

[W 14:52:14.292 NotebookApp] KernelSpecManager.whitelist is deprecated in JupyterLab 7.0, use KernelSpecManager.allowed_kernel_names instead

Did we release Jupyterlab 7 already??? 😮 🎉

@vidartf vidartf mentioned this pull request Aug 6, 2021
@blink1073
Copy link
Member Author

Did we release Jupyterlab 7 already??? 😮 🎉

Haha fixes are welcome. 😉

@vidartf
Copy link
Contributor

vidartf commented Aug 6, 2021

#674

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

Successfully merging this pull request may close these issues.

None yet

3 participants