Skip to content

Commit 8c08faf

Browse files
martinRenouecharles
andcommitted
Lab 4 Lumino 2
Co-authored-by: Eric Charles <[email protected]>
1 parent e226177 commit 8c08faf

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+20431
-14438
lines changed

Diff for: .github/workflows/build.yml

+1-7
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,6 @@ jobs:
1313
- name: Checkout
1414
uses: actions/checkout@v3
1515

16-
- name: Install node
17-
uses: actions/setup-node@v3
18-
with:
19-
node-version: '18'
20-
cache: yarn
21-
2216
- name: Install Python
2317
uses: actions/setup-python@v4
2418
with:
@@ -36,7 +30,7 @@ jobs:
3630
3731
- name: Install build dependencies
3832
run: |
39-
python -m pip install jupyterlab~=3.0 jupyter_packaging~=0.10
33+
python -m pip install jupyterlab jupyter_packaging~=0.10
4034
4135
- name: Install node dependencies
4236
run: |

Diff for: .github/workflows/devinstall.yml

+1-6
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,6 @@ jobs:
1212
steps:
1313
- name: Checkout
1414
uses: actions/checkout@v3
15-
- name: Install node
16-
uses: actions/setup-node@v3
17-
with:
18-
node-version: '18'
19-
cache: yarn
2015
- name: Install Python
2116
uses: actions/setup-python@v4
2217
with:
@@ -33,7 +28,7 @@ jobs:
3328
3429
- name: Install dependencies
3530
run: |
36-
python -m pip install notebook jupyterlab~=3.0 jupyter_packaging~=0.10
31+
python -m pip install notebook jupyterlab jupyter_packaging~=0.10
3732
- name: Run the dev-install script
3833
run: |
3934
./dev-install.sh

Diff for: .github/workflows/lint.yml

+13-7
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,19 @@ jobs:
99

1010
steps:
1111
- uses: actions/checkout@v3
12-
- name: Install node
13-
uses: actions/setup-node@v3
12+
13+
- name: Install Python
14+
uses: actions/setup-python@v4
1415
with:
15-
node-version: '18'
16-
cache: yarn
16+
python-version: '3.8'
17+
architecture: 'x64'
18+
19+
- name: Install dependencies
20+
run: |
21+
python -m pip install jupyterlab
22+
1723
- name: yarn install, integrity, lint
1824
run: |
19-
yarn --frozen-lockfile
20-
yarn integrity
21-
yarn lint:check
25+
jlpm --immutable
26+
jlpm integrity
27+
jlpm lint:check

Diff for: .github/workflows/packaging.yml

+3-9
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,6 @@ jobs:
2121
- name: Checkout
2222
uses: actions/checkout@v3
2323

24-
- name: Install node
25-
uses: actions/setup-node@v3
26-
with:
27-
node-version: '18'
28-
cache: yarn
29-
3024
- name: Install Python
3125
uses: actions/setup-python@v4
3226
with:
@@ -42,7 +36,7 @@ jobs:
4236
4337
- name: Install dependencies
4438
run: |
45-
python -m pip install --upgrade pip wheel build jupyterlab~=3.0
39+
python -m pip install --upgrade pip wheel build jupyterlab
4640
4741
- name: Build PyPI distributions for ipywidgets
4842
run: |
@@ -53,11 +47,11 @@ jobs:
5347
5448
- name: Install node dependencies
5549
run: |
56-
yarn
50+
jlpm
5751
5852
- name: Build JS
5953
run: |
60-
yarn build
54+
jlpm build
6155
6256
- name: Build PyPI distributions for jupyterlab_widgets
6357
run: |

Diff for: .github/workflows/tests.yml

+28-59
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,11 @@ jobs:
1111
- name: Set up Python
1212
uses: actions/setup-python@v4
1313
with:
14-
python-version: 3.7
14+
python-version: 3.8
1515
cache: 'pip'
1616
cache-dependency-path: |
1717
**/setup.cfg
1818
**/requirements*.txt
19-
- name: Install node
20-
uses: actions/setup-node@v3
21-
with:
22-
node-version: '18'
23-
cache: yarn
2419
- name: Install dependencies
2520
run: |
2621
sudo apt-get install -y pandoc
@@ -39,44 +34,39 @@ jobs:
3934
- name: Set up Python
4035
uses: actions/setup-python@v4
4136
with:
42-
python-version: 3.7
37+
python-version: 3.8
4338
cache: 'pip'
4439
cache-dependency-path: |
4540
**/setup.cfg
4641
**/requirements*.txt
4742
- name: Install dependencies
4843
run: |
4944
python -m pip install --upgrade pip
50-
python -m pip install jupyterlab~=3.0
51-
- name: Install node
52-
uses: actions/setup-node@v3
53-
with:
54-
node-version: '18'
55-
cache: yarn
45+
python -m pip install jupyterlab==4.0.0
5646
- name: yarn install, build, test
5747
run: |
58-
yarn --frozen-lockfile
59-
yarn build
60-
yarn build:examples
48+
jlpm --immutable
49+
jlpm build
50+
jlpm build:examples
6151
6252
pushd packages/base
63-
yarn test:unit:firefox:headless
53+
jlpm test:unit:firefox:headless
6454
popd
6555
6656
pushd packages/base-manager
67-
yarn test:unit:firefox:headless
57+
jlpm test:unit:firefox:headless
6858
popd
6959
7060
pushd packages/controls
71-
yarn test:unit:firefox:headless
61+
jlpm test:unit:firefox:headless
7262
popd
7363
7464
pushd packages/html-manager
75-
yarn test:unit:firefox:headless
65+
jlpm test:unit:firefox:headless
7666
popd
7767
7868
pushd examples/web1
79-
yarn test:firefox:headless
69+
jlpm test:firefox:headless
8070
popd
8171
8272
env:
@@ -87,7 +77,7 @@ jobs:
8777
strategy:
8878
max-parallel: 4
8979
matrix:
90-
python-version: ['3.7', '3.8', '3.9', '3.10', '3.11']
80+
python-version: ['3.8', '3.9', '3.10', '3.11']
9181

9282
steps:
9383
- uses: actions/checkout@v3
@@ -118,27 +108,22 @@ jobs:
118108
- name: Set up Python
119109
uses: actions/setup-python@v4
120110
with:
121-
python-version: 3.7
111+
python-version: 3.8
122112
cache: 'pip'
123113
cache-dependency-path: |
124114
**/setup.cfg
125115
**/requirements*.txt
126-
- name: Install node
127-
uses: actions/setup-node@v3
128-
with:
129-
node-version: '18'
130-
cache: yarn
131116
- name: Install Python dependencies
132117
run: |
133118
python -m pip install --upgrade pip
134-
pip install file://$PWD/python/ipywidgets#egg=ipywidgets[test]
119+
pip install jupyterlab file://$PWD/python/ipywidgets#egg=ipywidgets[test]
135120
- name: Install JS dependencies
136121
run: |
137-
yarn
122+
jlpm
138123
- name: Compare spec with latest version
139124
run: |
140125
python ./packages/schema/generate-spec.py -f markdown spec.md
141-
yarn prettier
126+
jlpm prettier
142127
diff -u ./packages/schema/jupyterwidgetmodels.latest.md ./spec.md
143128
144129
ui-test:
@@ -159,18 +144,12 @@ jobs:
159144
- name: Install dependencies
160145
run: |
161146
python -m pip install --upgrade pip
162-
python -m pip install -U jupyterlab~=3.2 jupyter-packaging~=0.10
163-
164-
- name: Install node
165-
uses: actions/setup-node@v3
166-
with:
167-
node-version: '18'
168-
cache: yarn
147+
python -m pip install -U jupyterlab==4.0.0 jupyter-packaging~=0.10
169148
170149
- name: Build and Install ipywidgets
171150
run: |
172-
yarn --frozen-lockfile
173-
yarn build
151+
jlpm --immutable
152+
jlpm build
174153
175154
- name: Build the extension
176155
run: |
@@ -187,25 +166,15 @@ jobs:
187166
188167
- name: Install Test Dependencies
189168
run: |
190-
cd ui-tests
191-
yarn --frozen-lockfile
192-
yarn playwright install chromium
193-
194-
- name: Launch JupyterLab
195-
run: |
196-
cd ui-tests
197-
yarn start:detached
198-
199-
- name: Wait for JupyterLab
200-
uses: ifaxity/wait-on-action@v1
201-
with:
202-
resource: http-get://localhost:8888/api
203-
timeout: 20000
169+
jlpm --immutable
170+
npx playwright install chromium
171+
working-directory: ui-tests
204172

205-
- name: Run UI Tests
173+
- name: Execute integration tests
174+
shell: bash -l {0}
175+
working-directory: ui-tests
206176
run: |
207-
cd ui-tests
208-
yarn test
177+
npx playwright test
209178
210179
- name: Upload Playwright Test assets
211180
if: always()
@@ -225,9 +194,9 @@ jobs:
225194
226195
- name: Update snapshots
227196
if: failure()
197+
working-directory: ui-tests
228198
run: |
229-
cd ui-tests
230-
yarn test:update
199+
jlpm test:update
231200
232201
- name: Upload updated snapshots
233202
if: failure()

Diff for: .yarnrc

-4
This file was deleted.

Diff for: .yarnrc.yml

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
nodeLinker: node-modules

Diff for: README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ Installing from source is more complicated and requires a developer install,
8888
see the detailed [developer install](docs/source/dev_install.md) instructions.
8989

9090
If you want to install ipywidgets from source, **you will need the
91-
[yarn](https://yarnpkg.com/) package manager version 1.2.1 or later**.
91+
[yarn](https://yarnpkg.com/) package manager version 3 or later**.
9292
To install the latest `main` version from the root directory of the source
9393
code, run `dev-install.sh`. To only build the Python package enter
9494
`pip install -e .`.

Diff for: dev-install.sh

+4-13
Original file line numberDiff line numberDiff line change
@@ -2,25 +2,16 @@
22

33
# For a clean conda environment please read docs/source/dev_install.md
44

5-
echo -n "Checking yarn... "
6-
yarn -v
7-
if [ $? -ne 0 ]; then
8-
echo "'yarn -v' failed, therefore yarn is not installed. In order to perform a
9-
developer install of ipywidgets you must have both yarn and pip installed on your
10-
machine! See https://yarnpkg.com/lang/en/docs/install/ for installation instructions."
11-
exit 1
12-
fi
13-
145
echo -n "Checking pip... "
156
pip --version
167
if [ $? -ne 0 ]; then
178
echo "'pip --version' failed, therefore pip is not installed. In order to perform
18-
a developer install of ipywidgets you must have both pip and yarn installed on
9+
a developer install of ipywidgets you must have pip installed on
1910
your machine! See https://packaging.python.org/installing/ for installation instructions."
2011
exit 1
2112
fi
2213

23-
echo -n "Checking JupyterLab (assuming JupyterLab >=3)... "
14+
echo -n "Checking JupyterLab (assuming JupyterLab >=4)... "
2415
jupyter lab --version 2>/dev/null
2516
if [ $? -ne 0 ]; then
2617
echo "no, skipping installation of widgets for jupyterlab"
@@ -34,8 +25,8 @@ set -e
3425
nbExtFlags="--sys-prefix $1"
3526

3627
echo -n "Installing and building all yarn packages"
37-
yarn
38-
yarn build
28+
jlpm
29+
jlpm build
3930

4031
echo -n "widgetsnbextension"
4132
pip install -v -e ./python/widgetsnbextension

Diff for: docs/environment.yml

+3-2
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,13 @@ dependencies:
99
- pip
1010
- packaging
1111
- jupyter-packaging
12-
- jupyterlab >=3,<4
12+
- jupyterlab >=4,<5
1313
- nodejs >=18,<19
1414
# dependencies
1515
- jupyter_client
1616
# docs
1717
- docutils >=0.19
18-
- jupyterlab-myst
18+
# - jupyterlab-myst
1919
- myst-nb >=0.17,<0.18
2020
- pandoc
2121
- pydata-sphinx-theme
@@ -39,3 +39,4 @@ dependencies:
3939
- python-libarchive-c
4040
- pip:
4141
- jupyterlite ==0.1.0b18
42+
- git+https://github.com/executablebooks/jupyterlab-myst.git@agoose77/feat-jupyterlab-v4-next

Diff for: docs/requirements.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ipykernel
55
ipyleaflet
66
jupyter-client
77
jupyter-packaging
8-
jupyterlab >=3,<4
8+
jupyterlab >=4
99
jupyterlite ==0.1.0b18
1010
matplotlib
1111
myst-nb >=0.17,<0.18

Diff for: examples/web3/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"@jupyter-widgets/base": "^6.0.4",
1818
"@jupyter-widgets/controls": "^5.0.5",
1919
"@jupyter-widgets/html-manager": "^1.0.7",
20-
"@jupyterlab/services": "^6.0.0",
20+
"@jupyterlab/services": "^6.0.0 || ^7.0.0",
2121
"codemirror": "^5.48.0",
2222
"font-awesome": "^4.7.0",
2323
"http-server": "^14.0.0"

0 commit comments

Comments
 (0)