You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
jupyter-server-documents (JSD) v0.3.0b0 does not work on JupyterLab v4.6 (tested with jupyterlab==4.6.1). This is a downstream consequence of #262: JupyterLab 4.6 bundles @jupyter/ydoc v4, but JSD's prebuilt frontend — and its @jupyter/collaboration / @jupyter/docprovider dependencies — are built against @jupyter/ydoc v3 (>=2.1.3 <3.0.0 || >=3.0.0 <4.0.0).
Until #262 lands (upgrading JSD to @jupyter/ydoc v4), JSD should be considered incompatible with JupyterLab >= 4.6, and I'd suggest documenting/pinning jupyterlab <4.6 for the v0.3.0 line.
Note: Jupyter Collaboration v4 almost certainly has the same problem on JupyterLab 4.6 — its v5 release (which moves to @jupyter/ydoc v4) is still pre-release (5.0.0 is not out yet), so the currently-released jupyter-collaboration line is also pinned to ydoc v3.
jupyter labextension list reports the extensions as incompatible:
"@jupyter-ai-contrib/server-documents@0.3.0-b0" is not compatible with the current JupyterLab
Conflicting Dependencies:
JupyterLab Extension Package
>=4.0.0-b1 <5.0.0 >=2.1.3 <3.0.0 || >=3.0.0 <4.0.0 @jupyter/ydoc
"@jupyter/collaboration-extension@4.4.1" is not compatible ... (same @jupyter/ydoc conflict)
"@jupyter/docprovider-extension@4.4.1" is not compatible ... (same @jupyter/ydoc conflict)
In the browser, the console is full of module-federation shared-singleton rejections, the decisive one being:
Unsatisfied version 4.0.0 from CORE_FEDERATION of shared singleton module @jupyter/ydoc (required ^3.0.0-a3)
(accompanied by a cascade of @jupyterlab/* singleton mismatches, since the JSD-built assets expect the 4.5-era @jupyterlab/* alpha ranges).
Why exactly it fails
@jupyter/ydoc is declared a shared singleton in the module-federation graph. When both JupyterLab (v4) and JSD (v3) request it, webpack federation can only hand out one instance for the whole app. JupyterLab wins as the host, so JSD's v3-built code receives the v4@jupyter/ydoc — whose YNotebook / YFile / awareness classes are not API-compatible with what JSD compiled against.
The visible result is not a hard white-screen crash — the shell renders and plugins report as "activated" — but documents never populate: opening a notebook shows an empty editor with the status bar stuck at Cell 0/0 and the kernel indicator stuck at Initializing (see screenshot). The shared model handed to JSD is the wrong ydoc version, so the notebook's cells/outputs are never wired up and the document is effectively unusable.
Land Upgrade Jupyter YDoc v4 #262 (upgrade JSD frontend to @jupyter/ydoc v4 + the JupyterLab 4.6 @jupyterlab/* ranges), and adopt jupyter-collaboration v5 once it's released.
In the meantime, add a jupyterlab <4.6 ceiling (or a documented note) so users don't silently land on a broken combination.
Summary
jupyter-server-documents(JSD) v0.3.0b0 does not work on JupyterLab v4.6 (tested withjupyterlab==4.6.1). This is a downstream consequence of #262: JupyterLab 4.6 bundles@jupyter/ydocv4, but JSD's prebuilt frontend — and its@jupyter/collaboration/@jupyter/docproviderdependencies — are built against@jupyter/ydocv3 (>=2.1.3 <3.0.0 || >=3.0.0 <4.0.0).Until #262 lands (upgrading JSD to
@jupyter/ydocv4), JSD should be considered incompatible with JupyterLab >= 4.6, and I'd suggest documenting/pinningjupyterlab <4.6for the v0.3.0 line.Related
@jupyter/ydocv4) is still pre-release (5.0.0is not out yet), so the currently-releasedjupyter-collaborationline is also pinned to ydoc v3.Reproduction
pip install "jupyterlab==4.6.1" jupyter-server-documents jupyter labWhat the user sees
jupyter labextension listreports the extensions as incompatible:In the browser, the console is full of module-federation shared-singleton rejections, the decisive one being:
(accompanied by a cascade of
@jupyterlab/*singleton mismatches, since the JSD-built assets expect the 4.5-era@jupyterlab/*alpha ranges).Why exactly it fails
@jupyter/ydocis declared a shared singleton in the module-federation graph. When both JupyterLab (v4) and JSD (v3) request it, webpack federation can only hand out one instance for the whole app. JupyterLab wins as the host, so JSD's v3-built code receives the v4@jupyter/ydoc— whoseYNotebook/YFile/ awareness classes are not API-compatible with what JSD compiled against.The visible result is not a hard white-screen crash — the shell renders and plugins report as "activated" — but documents never populate: opening a notebook shows an empty editor with the status bar stuck at
Cell 0/0and the kernel indicator stuck atInitializing(see screenshot). The shared model handed to JSD is the wrong ydoc version, so the notebook's cells/outputs are never wired up and the document is effectively unusable.Environment
jupyterlab==4.6.1(bundles@jupyter/ydoc4.0.0)jupyter-server-documents==0.3.0b0jupyter-collaboration-ui==2.4.1,jupyter-docprovider==2.4.1(both ydoc v3)Suggested resolution
@jupyter/ydocv4 + the JupyterLab 4.6@jupyterlab/*ranges), and adoptjupyter-collaborationv5 once it's released.jupyterlab <4.6ceiling (or a documented note) so users don't silently land on a broken combination.