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

Support JupyterLab Workspaces in Lab #805

Open
wants to merge 33 commits into
base: main
Choose a base branch
from

Conversation

bollwyvl
Copy link
Collaborator

@bollwyvl bollwyvl commented Sep 16, 2022

References

Code changes

  • normalize more metapackage package.json and tsconfig.json actions in doit repo
  • add prettier-package.json
  • add doit repo to linting
  • refactor settings, contents to use common configurable IForager wrapper
  • add /api/workspaces/* handlers
    • localForage
      • drivers and storageName in jupyter-lite.json
    • server-backed in /api/workspaces/all.json?
  • allow mode=single-document to be set by URL parameter
    • could be set in metadata, but this should probably become an upstream thing

    • presentationMode would be nice, too

  • overloaded some plugins
    • IRouter to add transforming
    • IWindowResolver to handle the lack of real server without overloading all of StateDB
  • ???
  • support workspaces definitions in
    • jupyter_build_config.json against given files/folders
    • jupyter-lite.json?
      • these are kinda nasty files, i don't see a big win to inlining them
    • in-contents .jupyterlab-workspace files?
  • ui tests
    • use goto('lab/index.html?reset') instead of page.reload in some existing tests
    • ~~add tests for various patterns above ~~
      • galata does some hacks on statedb, etc. avoiding for now
  • docs
    • document use cases
    • document with other storage options
    • add some workspaces to examples site

User-facing changes

  • when reloading /lab/, existing windows should be re-opened
  • kernel state/ids are lost, so some things won't work
  • when a second browser is opened on the same site, it will try to reuse the workspace (which doesn't work today)
    • a second browser will open with a timestamp-based suffix, e.g ?clone=default-6123123

Backwards-incompatible changes

  • ???

@github-actions
Copy link
Contributor

lite-badge 👈 Try it on ReadTheDocs

@bollwyvl bollwyvl added the enhancement New feature or request label Sep 16, 2022
@bollwyvl bollwyvl changed the title [wip] Support workspaces Support workspaces Sep 18, 2022
@bollwyvl bollwyvl changed the title Support workspaces Support JupyterLab Workspaces in Lab Sep 18, 2022
@bollwyvl bollwyvl marked this pull request as ready for review September 18, 2022 22:03
@bollwyvl bollwyvl requested a review from jtpio September 18, 2022 22:03
@psychemedia
Copy link
Contributor

Will a user be able to havr two different workspaces open in different browser tabs for the same jupyterlite environment?

@jtpio jtpio added this to the 0.1.0 milestone Sep 27, 2022
)
)

if C.CI and not C.CHECKING_RELEASE:
Copy link
Member

Choose a reason for hiding this comment

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

Maybe we still need to run this in the check release workflow to make sure resolutions have been updated and not leave a git dirty state.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Hm... i guess i though that check-release should be allowed to changes things, while "plain old lint" should just fail hard if a new package gets added, for example (which is what bit me)

@jtpio
Copy link
Member

jtpio commented Oct 7, 2022

Thanks @bollwyvl for working on this.

I did a quick check on RTD and there seems to be an issue with RetroLab. Here is what it looks like:

workspaces-retro.mp4

@bollwyvl
Copy link
Collaborator Author

bollwyvl commented Oct 8, 2022

Thanks for the thorough review. Need to sit back and take another look at it... maybe a path forward is for me to split up the repo plumbing stuff and then do the workspaces stuff on top of that...

@jtpio jtpio modified the milestones: 0.1.0, 0.2.0 Mar 14, 2023
@jtpio
Copy link
Member

jtpio commented Mar 14, 2023

Bumping to 0.2.0 so we have time to update to Notebook 7 in the meantime (#826) and address issues in https://github.com/jupyter/notebook if needed, since RetroLab is not maintained anymore.

@bollwyvl
Copy link
Collaborator Author

bollwyvl commented Mar 14, 2023 via email

@jtpio
Copy link
Member

jtpio commented Mar 15, 2023

Notebook 7 does not use workspaces at the moment. I think this was discussed recently. Probably it won't make it for 7.0, but could be considered for 7.x (as long as we don't create another JupyterLab).

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.

Support Workspaces
3 participants