installation error: doesn't support current version of Jupyterlab
Opened this issue · 8 comments
me too :(
@up2young I found an updated version under the Pull Requests
, and was able to clone that repo and build it. Hope it works for you.
The extension works fine for me after changing the dependencies in package.json. There is a pull request waiting with similar changes.
"dependencies": {
"@jupyterlab/application": "^0.19",
"@jupyterlab/coreutils": "^2.0.0-1",
"@jupyterlab/filebrowser": "^0.19",
"@jupyterlab/notebook": "^0.19",
"@jupyterlab/services": "^3.0.0-1",
"@phosphor/widgets": "^1.6.0"
},
Using the ^ in npm dependencies works differently for 0.x releases, so this package would then be limited to version 0.19.x.
Allows changes that do not modify the left-most non-zero digit in the [major, minor, patch] tuple. In other words, this allows patch and minor updates for versions 1.0.0 and above, patch updates for versions 0.X >=0.1.0, and no updates for versions 0.0.X
Personally I think "^0.19" is too conservative, and would suggest matching "0.x" as they are in theory intended to be backwards compatible.
In the latest jupyter-lab version this does not work either,
however changing the depenencies in package.json as suggested by @a1650078 works out of the box when we change them to the following:
"dependencies": {
"@jupyterlab/application": "^1.0.1",
"@jupyterlab/coreutils": "^3.0.0",
"@jupyterlab/filebrowser": "^1.0.1",
"@jupyterlab/notebook": "^1.0.1",
"@jupyterlab/services": "^4.0.1",
"@phosphor/widgets": "^1.6.0"
}
and generally following the workflow suggested by @cocoaaa :)
@Magnusgaertner I'd be happy to accept a PR
<Update on installing this extension with jupyter-lab 1.1.0>
I recently updated jupyterlab to version 1.1.0 and had another dependency conflicts. I'm not very familiar with packaging and npm installation process, so there must be a more proper way to resolve this conflict by updating the package.json file. In the meantime, if anyone wants a quick fix, here is what I did to install this extension on jupterlab 1.1.0:
- Clone this repo
cd
to the directory of your local cloned repo- run
npm install
(without changing anything in thepackage.json
file) - run
npm run build
- Try
jupyter labextension link .
If you get an error about conflicting dependencies like this:
Change the package.json
's "dependencies" field to what matches in the error message (eg. change to the leftmost column's version numbers). For example, I had to update the field to:
"dependencies": {
"@jupyterlab/application": "^1.1",
"@jupyterlab/coreutils": "^3.1",
"@jupyterlab/filebrowser": "^1.1",
"@jupyterlab/notebook": "^1.1",
"@jupyterlab/services": "^4.1",
"@phosphor/widgets": "^1.6.0"
},
- Run
jupyter labextension link .
- Rebuild jupyter-lab:
jupyter lab build
For some reason, if I use update the dependency versions before running npm install
, I get this error:
node_modules/@jupyterlab/ui-components/lib/icon/iconregistry.d.ts:1:8 - error TS1192: Module '"/Users/hayley/miniconda3/share/jupyter/lab/manual_extensions/jupyterlab-clipboard/node_modules/@types/react/index"' has no default export.
1 import React from 'react';
~~~~~
node_modules/@jupyterlab/ui-components/lib/icon/interfaces.d.ts:3:8 - error TS1192: Module '"/Users/hayley/miniconda3/share/jupyter/lab/manual_extensions/jupyterlab-clipboard/node_modules/@types/react/index"' has no default export.
3 import React from 'react';
~~~~~
src/index.ts:3:3 - error TS2305: Module '"/Users/hayley/miniconda3/share/jupyter/lab/manual_extensions/jupyterlab-clipboard/node_modules/@jupyterlab/application/lib/index"' has no exported member 'JupyterLabPlugin'.
3 JupyterLabPlugin,
~~~~~~~~~~~~~~~~
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! jupyterlab-clipboard@0.3.0-alpha prepublish: `yarn clean && yarn build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the jupyterlab-clipboard@0.3.0-alpha prepublish script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
So, I had to use the original package.json
until I got the dependencies conflicts. Hope this helps.