Skip to content

Commit 64ed3de

Browse files
committed
JupyterLab 3
Signed-off-by: martinRenou <[email protected]>
1 parent fbc9d1c commit 64ed3de

File tree

24 files changed

+1850
-252
lines changed

24 files changed

+1850
-252
lines changed

.github/workflows/job.test.yml

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ jobs:
3737
matrix:
3838
python: [3.6, 3.7, 3.8]
3939
os: [ubuntu-16.04, macos-10.14, vs2017-win2016]
40-
lab: ['>=2.2.0,<3.0.0a0']
40+
lab: ['>=3.0.0rc8,<4.0.0a0']
4141
include:
4242
# if using 3.6, use an old node
4343
- python: 3.6
@@ -77,10 +77,10 @@ jobs:
7777
uses: goanpeca/setup-miniconda@v1
7878
with:
7979
python-version: ${{ matrix.python }}
80-
channels: conda-forge, defaults
80+
channels: conda-forge/label/jupyterlab_rc, conda-forge/label/jupyterlab_server_rc, conda-forge, defaults
8181
channel-priority: true
8282
auto-activate-base: true
83-
activate-environment: jupyterlab-lsp
83+
# activate-environment: jupyterlab-lsp
8484
environment-file: requirements/github-actions.yml
8585
auto-update-conda: true
8686
use-only-tar-bz2: true # needs to be set for caching to work properly
@@ -112,9 +112,6 @@ jobs:
112112
- name: Build python distributions
113113
run: python setup.py sdist bdist_wheel
114114

115-
- name: Build npm bundles
116-
run: jlpm lerna run bundle
117-
118115
- name: Install python wheel
119116
run: cd dist && python -m pip install jupyter_lsp-${{ env.PY_JLSP_VERSION }}-py3-none-any.whl --no-deps
120117

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,3 +116,6 @@ coverage/
116116
_*.d.ts
117117
_build
118118
.virtual_documents/
119+
120+
# Built labextensions
121+
py_src/jupyter_lsp/labextensions/

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
.mypy_cache
33
.pytest_cache
44
.yarn-packages
5+
**/_*.d.ts
56
**/.ipynb_checkpoints
67
**/*.egg-info
78
**/build

MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
include LICENSE README.md
22
recursive-include py_src *.json *.R
3+
recursive-include py_src/jupyter_lsp/labextensions

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,9 @@ Use of a python `virtualenv` or a conda env is also recommended.
9797
1. install JupyterLab and the server extension
9898

9999
```bash
100-
conda install -c conda-forge 'jupyterlab>=2.2,<3.0.0a0' jupyter-lsp
100+
conda install -c conda-forge 'jupyterlab>=3.0.0-rc.7,<4.0.0a0' jupyter-lsp
101101
# or
102-
pip install 'jupyterlab>=2.2,<3.0.0a0' jupyter-lsp
102+
pip install 'jupyterlab>=3.0.0-rc.7,<4.0.0a0' jupyter-lsp
103103
```
104104

105105
> Note: With conda, you could take advantage of the bundles: `jupyter-lsp-python`

binder/environment.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
name: jupyterlab-lsp
22

33
channels:
4+
- conda-forge/label/jupyterlab_rc
5+
- conda-forge/label/jupyterlab_server_rc
46
- conda-forge
57
- defaults
68

79
dependencies:
810
# runtime dependencies
911
- python >=3.7,<3.8.0a0
10-
- jupyterlab >=2.2.0,<3.0.0a0
12+
- jupyterlab >=3.0.0rc8,<4.0.0a0
1113
- notebook >=4.3.1
1214
# build dependencies
1315
- nodejs >=10,<14

binder/postBuild

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,12 @@
11
#!/usr/bin/env bash
22
set -eux
3-
# do a dev install of the server side
4-
python -m pip install -e . --ignore-installed --no-deps -vv
5-
jupyter serverextension enable --sys-prefix --py jupyter_lsp
6-
7-
# should have no extensions
8-
jupyter labextension list
93

10-
# do a dev build of the client side
4+
# Build labextensions
115
jlpm bootstrap
126

13-
# link all pieces to lab (no build)
14-
jlpm lab:link && jupyter labextension list
15-
16-
# list extensions before build
17-
jupyter labextension list
18-
19-
# actually build
20-
jupyter lab build --debug --dev-build=False --minimize=True
7+
# Do a dev install of the server side
8+
pip install . -vv
9+
jupyter serverextension enable --sys-prefix --py jupyter_lsp
2110

22-
# list extensions again
11+
# List extensions
2312
jupyter labextension list

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,17 +38,17 @@
3838
"private": true,
3939
"scripts": {
4040
"bootstrap": "jlpm --no-optional --prefer-offline && lerna bootstrap && jlpm lint && jlpm clean && jlpm build",
41-
"build": "jlpm build:schema && jlpm build:completion-theme && jlpm build:theme-material && jlpm build:theme-vscode && jlpm build:meta && jlpm build:ws",
41+
"build": "jlpm build:schema && jlpm build:completion-theme && jlpm build:theme-material && jlpm build:theme-vscode && jlpm build:meta && jlpm build:ws && jlpm build:jupyterlab-lsp",
4242
"build:schema": "lerna run build:schema --stream",
4343
"build:meta": "lerna run build --stream --scope @krassowski/jupyterlab-lsp-metapackage",
4444
"build:completion-theme": "lerna run build --stream --scope @krassowski/completion-theme",
4545
"build:theme-vscode": "lerna run build --stream --scope @krassowski/theme-vscode",
4646
"build:theme-material": "lerna run build --stream --scope @krassowski/theme-material",
47+
"build:jupyterlab-lsp": "lerna run build --stream --scope @krassowski/jupyterlab-lsp",
4748
"build:ws": "lerna run build --stream --scope lsp-ws-connection",
4849
"watch": "lerna run --parallel watch",
4950
"bundle": "lerna run --parallel bundle",
5051
"clean": "lerna run --parallel clean",
51-
"lab:link": "lerna run lab:link",
5252
"lint:check": "jlpm prettier:check && jlpm eslint:check",
5353
"lint": "jlpm prettier && jlpm eslint",
5454
"prettier:check": "prettier --check \"**/*{.ts,.tsx,.js,.jsx,.css,.json,.md,.yml}\"",

packages/.eslintrc.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ module.exports = {
1717
],
1818
ignorePatterns: [
1919
'**/node_modules/**/*',
20+
'packages/jupyterlab-lsp/labextension/**/*',
2021
'**/lib/**/*',
2122
'**/_*.ts',
2223
'**/_*.d.ts',

packages/completion-theme/package.json

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,16 @@
3333
"lab:link": "jupyter labextension link . --no-build"
3434
},
3535
"devDependencies": {
36-
"react": "*",
37-
"@jupyterlab/ui-components": "~2.2.0"
36+
"@jupyterlab/builder": "^3.0.0-rc.2",
37+
"@jupyterlab/ui-components": "^3.0.0-rc.7",
38+
"react": "^17.0.1",
39+
"rimraf": "^3.0.2",
40+
"typescript": "~4.0.3"
3841
},
3942
"peerDependencies": {},
4043
"jupyterlab": {
4144
"extension": true,
42-
"schemaDir": "schema"
45+
"schemaDir": "schema",
46+
"outputDir": "../../py_src/jupyter_lsp/labextensions/@krassowski/completion-theme"
4347
}
44-
}
48+
}

0 commit comments

Comments
 (0)