jupyterlab / jupyterlab-monaco Goto Github PK
View Code? Open in Web Editor NEWA JupyterLab extension providing the Monaco editor
License: BSD 3-Clause "New" or "Revised" License
A JupyterLab extension providing the Monaco editor
License: BSD 3-Clause "New" or "Revised" License
And release pip and conda packages?
Here we can discuss the future plans for LSP integration ๐
WIP PR: #12
I made some modification on original jupyterlab application, so I need to run the dev mode.
I got such error after running jlpm run add:sibling ./extensions/jupyterlab-monaco
(I placed the jupyterlab-monaco
repo under extensions
folder under jupyterlab code root directory):
$ jlpm run add:sibling ./extensions/jupyterlab-monaco
yarn run v1.3.2
$ node buildutils/lib/add-sibling.js ./extensions/jupyterlab-monaco
> jlpm run integrity
$ node buildutils/lib/ensure-repo.js
npm ERR! code E404
npm ERR! 404 Not found : file-loader!..
npm ERR! 404
npm ERR! 404 'file-loader!..' is not in the npm registry.
npm ERR! 404 Your package name is not valid, because
npm ERR! 404 1. name can no longer contain special characters ("~'!()*")
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/zhaofengli/.npm/_logs/2018-06-20T06_52_57_173Z-debug.log
child_process.js:644
throw err;
^
Error: Command failed: npm view file-loader!.. version
npm ERR! code E404
npm ERR! 404 Not found : file-loader!..
npm ERR! 404
npm ERR! 404 'file-loader!..' is not in the npm registry.
npm ERR! 404 Your package name is not valid, because
npm ERR! 404 1. name can no longer contain special characters ("~'!()*")
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/zhaofengli/.npm/_logs/2018-06-20T06_52_57_173Z-debug.log
at checkExecSyncError (child_process.js:601:13)
at Object.execSync (child_process.js:641:13)
at Object.getDependency (/Users/zhaofengli/projects/goldersgreen/frontend/src/packages/jupyterlab_package/buildutils/lib/get-dependency.js:69:45)
at /Users/zhaofengli/projects/goldersgreen/frontend/src/packages/jupyterlab_package/buildutils/lib/ensure-package.js:83:51
at Array.forEach (<anonymous>)
at Object.ensurePackage (/Users/zhaofengli/projects/goldersgreen/frontend/src/packages/jupyterlab_package/buildutils/lib/ensure-package.js:74:11)
at ensureIntegrity (/Users/zhaofengli/projects/goldersgreen/frontend/src/packages/jupyterlab_package/buildutils/lib/ensure-repo.js:194:46)
at Object.<anonymous> (/Users/zhaofengli/projects/goldersgreen/frontend/src/packages/jupyterlab_package/buildutils/lib/ensure-repo.js:240:5)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Really excited about this extension!
It seems the text editor settings for key mapping and editor theme don't apply to Monaco, is that correct? Is it possible to add vim or other key mappings to monaco or will that only be possible through the use of extensions?
And is their hope that extensions from VS code could be migrated to monaco on jupyter lab, or will they have to be written from scratch?
Thanks!
Looks like commits are a year or more old.
I find this repor to be a super great idea, so its sad if it has stopped.
Maybe somebody else carried on the great work?
Hi,
Like the default editor, we should be able to connect a console and run code with Shift+Enter
When I try to install on jupyterlab=1.0.0, it reports error below. Maybe you can update the extension for jupyterlab>=1.0.0?
ValueError:
"[email protected]" is not compatible with the current JupyterLab
Conflicting Dependencies:
JupyterLab Extension Package
>=1.2.1 <1.3.0 >=0.18.0 <0.19.0@jupyterlab/application
>=1.2.1 <1.3.0 >=0.18.0 <0.19.0@jupyterlab/apputils
>=3.2.0 <3.3.0 >=2.0.2 <3.0.0 @jupyterlab/coreutils
>=1.2.1 <1.3.0 >=0.18.0 <0.19.0@jupyterlab/fileeditor
It's hard to know how mature a project is without installing it, if no screenshots are included.
https://github.com/Microsoft/monaco-editor-webpack-plugin. It even has options to only include certain features or languages. I've used it for https://github.com/superRaytin/react-monaco-editor and it works well.
I met the following error when run
yarn run build
node_modules/@jupyterlab/rendermime/lib/widgets.d.ts(7,31): error TS2420: Class 'RenderedCommon' incorrectly implements interface 'IRenderer'.
Types of property 'title' are incompatible.
Type 'Title' is not assignable to type 'Title'. Two different types with this name exist, but they are unrelated.
Types of property 'owner' are incompatible.
Type 'Widget' is not assignable to type 'Widget'. Two different types with this name exist, but they are unrelated.
Types of property 'layout' are incompatible.
Type 'Layout' is not assignable to type 'Layout'. Two different types with this name exist, but they are unrelated.
Property 'init' is protected but type 'Layout' is not a class derived from 'Layout'.
error Command failed with exit code 1.
As I'm experiencing troubles setting up the right dev environment on WSL, I thought it useful to solve it in an issue here. I'm on WSL x64 (Ubuntu 16.04) using Miniconda3.
I went through the jupyterlab contributing guide and the instructions on this repo and did the following in a folder /mnt/d/jlab/:
conda create -n monaco
source activate monaco
conda install -c conda-forge nodejs notebook nb_conda_kernels
git clone https://github.com/<your-github-username>/jupyterlab.git
cd jupyterlab
pip install -e .
jlpm install
jlpm run build # Build the dev mode assets (optional)
jlpm run build:core # Build the core mode assets (optional)
jupyter lab build # Build the app dir assets (optional)
cd ..
git clone https://github.com/jupyterlab/jupyterlab-monaco.git
cd jupyterlab-monaco
yarn install
yarn run build
jupyter labextension link .
That final command sometimes ends up in an infinite loop, supplying dev mode argument helps it to pass.
I tried experimenting with rebuilding after I made the changes in that config.json you mentioned somewhere, but I can't get it to work.
I can start JupyterLab with the default command, but the text editor is still codemirror.
Would you mind helping out with a comprehensive bash file that should work in principle? Did I forget anything or got something wrong?
I guess it's just "first-timer" issues.
R-Brain/jupyterlab has a implementation of monaco
on jupyterlab, but on a very old version.
Depending on my experience on their website, their implementation is quite good, they even integrated monaco
into the notebook cells. So I think this might be a help even it's old.
This repository is part of the repositories listed as inactive during the JupyterLab team call.
This issue is to ping anyone listening for changes in this repository that starting from today if no volunteer propose him/herself to maintain this repository it will be archived in 2 weeks (aka July 27th, 2023).
There is a weird behavior observed in my setup: After a file is open and then closed with Monaco, when it is open the second time, the following error message pops up in the Firefox JS console:
TypeError: this.editor is undefined [Learn More] index.js:72
which is corresponded to the following line:
jupyterlab-monaco/src/index.ts
Line 95 in f710e41
This error prevents the editor to show up in the Jupyterlab window. It seems that the old MonacoWidget
object is not destroyed when the editor tab is closed. Refreshing the webpage solved this problem.
My environment:
Thank you for the great work. ๐
However, during the building process, a conflict occurred:
jupyterlab-monaco-0.1.0.tgz
Errored, use --debug for full output:
ValueError:
"[email protected]" is not compatible with the current JupyterLab
Conflicting Dependencies:
JupyterLab Extension Package
>=0.15.4-0 <0.16.0-0 >=0.16.2-0 <0.17.0-0 @jupyterlab/application
>=0.15.4-0 <0.16.0-0 >=0.16.2-0 <0.17.0-0 @jupyterlab/fileeditor
>=0.15.5-0 <0.16.0-0 >=0.16.3-0 <0.17.0-0 @jupyterlab/apputils
Seems the dependencies are too new. So I modified the corresponding versions in the package.json
,
this problem was gone.
Hope this extension could be published on npm soon, thus saving the building process. ๐
"[email protected]" is not compatible with the current JupyterLab
Conflicting Dependencies:
JupyterLab Extension Package
>=0.17.2 <0.18.0 >=0.16.2 <0.17.0 @jupyterlab/application
>=0.17.2 <0.18.0 >=0.16.3 <0.17.0 @jupyterlab/apputils
>=2.0.2 <3.0.0 >=1.1.2 <2.0.0 @jupyterlab/coreutils
>=0.17.2 <0.18.0 >=0.16.2 <0.17.0 @jupyterlab/fileeditor
Is there a way to install custom language highlighting-support? As I understand it, highlighting ist not handled by LSP yet, so it has to installed independently.
Is it time to publish this extension to npm?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.