jupyterlab-contrib / jupyterlab-link-share

JupyterLab Extension to easily share a link to a running server on Binder
BSD 3-Clause "New" or "Revised" License
53 stars 14 forks source link

Shows wrong URL when using retrolab #25

Closed yuvipanda closed 2 years ago

yuvipanda commented 2 years ago

Description

When I access the dialog from retrolab, I expect the link it gives me to also point to retrolab. Instead, it points to regular lab: http://localhost:8000/user/test/lab?token=5be7a94945cf47fb92e8598d5abe7387

Reproduce

  1. Install extension
  2. Open retrolab
  3. Go to Share -> Share Jupyter Server Link

Context

This is running in latest released retrolab and current master (+ #24) of this repo.

yuvipanda commented 2 years ago

I think https://github.com/jupyterlab-contrib/jupyterlab-link-share/blob/761fec78217fbb9813aa192037053484fe9485c4/src/index.ts#L61 is not fully aware what URL it's on.

yuvipanda commented 2 years ago

I think on retrolab, it should also give you a link that opens the exact same view the user has right now.

yuvipanda commented 2 years ago

Looking at https://github.com/jupyterlab/jupyterlab/blob/ee1436736daf6f856d99ab125cc2b83592f6d196/packages/coreutils/src/pageconfig.ts#L142, it primarily hnadles single document mode vs lab, and different workspaces. I think we'll just need to implement this separately for retro, and just use the current URL + token.

jtpio commented 2 years ago

Right I think a custom plugin for retro will be needed, and can be implemented in this link share extension.