-
Notifications
You must be signed in to change notification settings - Fork 42
ST6RI-766 Update to JupyterLab version 4.x in the Jupyter deployment #696
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
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I noticed that the new extension does not support folding of code between braces. That is, the old mode definition included:
modeProps: {
fold: ['brace'],
}
but I don't see anything similar in the new sysmlparser
definition. If there is no way to do this in the new approach, that is a serious degradation of functionality that I know is commonly used by users.
Also, the file |
No, this shouldn't work. I always go for jupyter lab. I'm not sure if there is a high demand for classic Notebook. |
I've tried adding code folding as an extension in the frontend plugin but I couldn't get it working unfortunately. I couldn't really find any option either that would indicate some easy turn-on.
|
I think we need to use |
If it is not going to work anyway, we should take it out of the build. |
The problem is that the v6 In any case, if we can't find a way to get code folding incorporated fairly quickly, I am going to defer this PR to the next sprint. I don't want to deploy it without code folding. |
We can use |
I am going to remove this PR from the release. We figure out code folding on the next sprint. |
This PR includes dependency and code updates for the
org.omg.sysml.jupyter.jupyterlab
labextension to support Jupyter 4.x. Older versions are no longer supported.This PR doesn't change how the extension is packaged. Installing it into Jupyter is still possible with
jupyter labextension install
(which is deprecated but still works in 4.x).Dependency updates
package.json
"@jupyterlab/application": "3.x"
->"4.x"
"typescript": "<4.4.0"
->"~5.8.3"
"@jupyterlab/codemirror": "^0.0.98"
->">=4.0"
"@codemirror/legacy-modes": "^6.3.2"
es2018
->es2023
Code changes
Previously, the syntax highlight was registered by adding a new "mode" to Codemirror. This is no longer an option. Instead, the language has to be registered via
IEditorLanguageRegistry
by the front-end plugin. Luckily, the underlying parser is still present and can be registered in "legacy" mode, so most of the configuration can be easily ported.sysml
languageclike
parser is created