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

Make Jupytext's server extension compatible with Jupyter Server based apps like Voila #270

Closed
mwouts opened this issue Jun 30, 2019 · 1 comment
Milestone

Comments

@mwouts
Copy link
Owner

mwouts commented Jun 30, 2019

The use case for this was reported at voila-dashboards/voila#107 by @SylvainCorlay. Voila is an application that can render notebooks as interactive web pages. Since voila reexecutes the notebook in full before serving it, there's no point in preserving the outputs. So it would be nice to store these notebooks in the form of Jupytext files.

Voila is internally based on jupyter_server rather than on notebook. In particular the default contents manager is LargeFileManager from jupyter_server.services.contents.largefilemanager rather than from notebook.services.contents.largefilemanager. Jupytext's extension should be aware of then at the time of substituing the default CM with Jupytext's one.

Also, we should add a jupyter_server_config.d/jupytext.json file that activates Jupytext's server extension on the ServerApp. That way, using Jupytext with Voila would simply be a matter of having both programs installed.

@mwouts mwouts added this to the 1.2.0 milestone Jun 30, 2019
mwouts added a commit that referenced this issue Jun 30, 2019
Unless it already has Jupytext's attributes
#270
mwouts added a commit that referenced this issue Jul 3, 2019
Unless it already has Jupytext's attributes
#270
mwouts added a commit that referenced this issue Jul 6, 2019
Unless it already has Jupytext's attributes
#270
@mwouts
Copy link
Owner Author

mwouts commented Jul 6, 2019

With the latest commit we do see Jupytext's contents manager class being created when jupyter server is started (with no other config than having Jupytext installed):

(python3) C:\Users\Marc\Documents\GitHub\jupytext>jupyter server
[I 21:12:47.182 ServerApp] [Jupytext Server Extension] Deriving a JupytextContentsManager from LargeFileManager
[I 21:12:47.183 ServerApp] Serving notebooks from local directory: C:\Users\Marc\Documents\GitHub\jupytext
[I 21:12:47.183 ServerApp] The Jupyter Server is running at:
[I 21:12:47.183 ServerApp] http://localhost:8888/?token=...

@mwouts mwouts closed this as completed Jul 6, 2019
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

1 participant