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

[Do not merge] Support both lite and remote kernel #118

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

trungleduc
Copy link
Member

@trungleduc trungleduc commented May 8, 2024

References

This is an experiment on adding support for the remote kernels to voici dashboards.

How to test

  • Start a jupyter server session with:
jupyter server --ServerApp.token='' --ServerApp.password='' --ServerApp.disable_check_xsrf=True --no-browser --port=8000 --ServerApp.allow_origin="*"
  • Build voici dashboard with the following config in jupyter_lite_config.json:
{
  "VoilaConfiguration": {
    "extension_config": {
      "VoiciRemoteKernel": {
        "name-of-notebook-using-remote-kernel.ipynb": {
          "baseUrl": "http://127.0.0.1:8000/",
          "wsUrl": "ws://127.0.0.1:8000/"
        }
      }
    }
  }
}

The notebooks with names in the VoiciRemoteKernel section will use the remote kernel, other notebooks still use lite kernel.

Code changes

Backwards-incompatible changes

Copy link
Contributor

github-actions bot commented May 8, 2024

lite-badge 👈 Try it on ReadTheDocs

@trungleduc trungleduc added the enhancement New feature or request label May 10, 2024
@jtpio
Copy link
Member

jtpio commented May 10, 2024

Is it something that should be specific to Voici, or could this also be useful in JupyterLite?

@jtpio
Copy link
Member

jtpio commented May 10, 2024

Thinking that with something like jupyterlab/jupyterlab#15329 that would allow configuring the service manager with extensions, we could have such functionality live in a regular JupyterLab extension, so it could be installed on Voici and JupyterLite deployments if desired.

@trungleduc
Copy link
Member Author

Thinking that with something like jupyterlab/jupyterlab#15329 that would allow configuring the service manager with extensions, we could have such functionality live in a regular JupyterLab extension, so it could be installed on Voici and JupyterLite deployments if desired.

indeed, I want to test it first in voici to see if swapping the server setting is enough to make the kernel work. But ideally, a custom service manager supporting both types of kernel should be the way to go.

@jtpio
Copy link
Member

jtpio commented May 10, 2024

Nice, that makes sense, it would be faster to get a proof-of-concept up and running this way.

This would actually benefit not just Voici or JupyterLite, but could allow for hybrid (in-browser / remote) kernels in JupyterLab (or other lab-based apps) too (and progressively make lab and lite converge).

Thanks for looking into this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants