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
Currently, the widget manager for JupyterLab displays an error message when there is version mismatch (added in #3185), which is useful as it is also displayed in the output cell:
But it does not check if the provided version is valid.
One possible source of confusion would be if the frontend version is not set properly. For example a value of 1.8.0a0 is not valid according to the valid function from the semver package:
This is reproducible with the (now deprecated) Jupyter Widget cookiecutter, by creating a new widget and changing the version to 0.1.0a0:
Error: Module jupyter-widget-example, version ^0.1.0a0 is not registered, however, 0.1.0a0 is
Proposed Solution
Additional context
Maybe we could first check if the provided version is valid, and update the error message so it's less confusing to users when the issue is about a malformed version?
Problem
Currently, the widget manager for JupyterLab displays an error message when there is version mismatch (added in #3185), which is useful as it is also displayed in the output cell:
ipywidgets/python/jupyterlab_widgets/src/manager.ts
Lines 208 to 216 in b78de43
The semver cache checks the
maxSatisfying
version here:ipywidgets/python/jupyterlab_widgets/src/semvercache.ts
Line 24 in b78de43
But it does not check if the provided version is valid.
One possible source of confusion would be if the frontend version is not set properly. For example a value of
1.8.0a0
is not valid according to thevalid
function from thesemver
package:This is reproducible with the (now deprecated) Jupyter Widget cookiecutter, by creating a new widget and changing the version to
0.1.0a0
:Proposed Solution
Additional context
Maybe we could first check if the provided version is valid, and update the error message so it's less confusing to users when the issue is about a malformed version?
cc @ohrely
The text was updated successfully, but these errors were encountered: