Closed rgbkrk closed 8 years ago
Jp would need to be a class that's dynamically allocated and inheirted from EventEmitter. Example here: https://nodejs.org/api/events.html
var jp = require('jupyter-paths')() // returns a class. can pass args here
What you're really doing though is watching the filesystem, which might get weird.. I haven't done that yet.
We'll leave this standalone as just "where do I find these Jupyter things", keeping it small as an npm
package.
The Jupyter ecosystem has defined protocols for:
The kinds of things a front end for Jupyter needs to ask for are:
If it's for a notebook app or Hydrogen within Atom, it needs to know about all the kernel runtimes it has started. Typically this is through a kernel manager (in the Python Jupyter code).
Per a conversation with @karissa, we should think about an interface like this:
Which would provide the list of kernelspecs across systems, using the directories currently pulled from
require('jupyter-paths').jupyterPath('kernels')
. Alternatively (or in addition) we could providejp.kernelSpecs()
to get the full listing of specs.Beyond this, we'll want to be able to list the currently running runtimes (globally) as well as those launched by a running kernelManager.
Example kernel spec:
Example runtime: