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

Pick up kernelspecs from Jupyter directories #7

Closed
rgbkrk opened this issue May 19, 2015 · 9 comments
Closed

Pick up kernelspecs from Jupyter directories #7

rgbkrk opened this issue May 19, 2015 · 9 comments

Comments

@rgbkrk
Copy link
Member

rgbkrk commented May 19, 2015

We'll need/want to search the new Jupyter paths as well for kernelspecs, just as in https://github.com/jupyter/jupyter_core/blob/master/jupyter_core/paths.py

This is for the future release of the Jupyter packages (but my and the rest of the IPython/Jupyter team's likeliness to use this package).

@willwhitney
Copy link
Collaborator

Which of these directories contains the kernelspecs? ~/.jupyter?

@rgbkrk
Copy link
Member Author

rgbkrk commented May 19, 2015

Multiples. It's the aggregation of all of them...

In [1]: import jupyter_core.paths

In [2]: jupyter_core.paths.jupyter_path("kernels")
Out[2]:
['/Users/rgbkrk/Library/Jupyter/kernels',
 '/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/share/jupyter/kernels',
 '/usr/local/share/jupyter/kernels',
 '/usr/share/jupyter/kernels']

This is where I was bantering around with creating a simple wrapper script that would dump JSON to stdout with options we'd need from an alternate front end (like Hydrogen). The other alternative is to use what we've got and launch a python kernel just for Hydrogen that queries for this same information.

It's either that or always searching particular paths.

@willwhitney
Copy link
Collaborator

Gosh, that's ugly. I'd sure love a script that dumps JSON of all the kernels' info.

@willwhitney
Copy link
Collaborator

Especially if that script worked across IPython and Jupyter.

@rgbkrk
Copy link
Member Author

rgbkrk commented May 19, 2015

As the migration happens, IPython will just be one of the kernels for Jupyter. It's all the same team.

When I get some free time after work, I'll start poking at what scripts could be useful for Hydrogen and Jupyter sidecar to call out to Jupyter for accurate information.

@willwhitney
Copy link
Collaborator

What I mean is that I'd like this to still work for people who haven't
updated to a post-Split version. I find most people don't update until
something completely stops working.

Thanks!

On Tue, May 19, 2015 at 4:51 PM Kyle Kelley notifications@github.com
wrote:

As the migration happens, IPython will just be one of the kernels for
Jupyter. It's all the same team.

When I get some free time after work, I'll start poking at what scripts
could be useful for Hydrogen and Jupyter sidecar to call out to Jupyter for
accurate information.


Reply to this email directly or view it on GitHub
#7 (comment).

@rgbkrk
Copy link
Member Author

rgbkrk commented May 19, 2015

Totally, I'll end up making a script that straddles both.

Also, people are strange and install from master whether or not they're contributing to IPython/Jupyter. For this release it's a bit silly since it's mostly repackaging, but in previous versions it was a big delta.

@willwhitney
Copy link
Collaborator

Awesome!

For the moment I'm loading all kernels found in that list plus ~/.ipython/kernels and ~/.jupyter/kernels. Not a good answer, but it ought to tide us over for now. That's in the latest release.

@rgbkrk
Copy link
Member Author

rgbkrk commented May 23, 2015

Done in #19.

@rgbkrk rgbkrk closed this as completed May 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants