Skip to content

Commit df7121f

Browse files
committed
Update README to have Jlab 3.0 as a requirement
1 parent 81cdde5 commit df7121f

File tree

7 files changed

+2697
-991
lines changed

7 files changed

+2697
-991
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ for the frontend extension.
1717

1818
## Requirements
1919

20-
- JupyterLab >= 2.2
20+
- JupyterLab >= 3.0
2121

2222
## Install
2323

_version.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
version_info = {
2+
'major': 1,
3+
'minor': 0,
4+
'micro': 4
5+
}
6+
7+
__version__ = '{}.{}.{}'.format(
8+
version_info['major'], version_info['minor'], version_info['micro']
9+
)

binder/environment.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# a mybinder.org-ready environment for demoing code_snippet
2+
# this environment may also be used locally on Linux/MacOS/Windows, e.g.
3+
#
4+
# conda env update --file binder/environment.yml
5+
# conda activate code_snippet-demo
6+
#
7+
name: code_snippet-demo
8+
9+
channels:
10+
- conda-forge
11+
12+
dependencies:
13+
# runtime dependencies
14+
- python >=3.8,<3.9.0a0
15+
- jupyterlab >=3,<4.0.0a0
16+
# labextension build dependencies
17+
- nodejs >=14,<15
18+
- pip
19+
- wheel
20+
# additional packages for demos
21+
# - ipywidgets

package.json

Lines changed: 38 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616
"files": [
1717
"lib/**/*.{d.ts,eot,gif,html,jpg,js,js.map,json,png,svg,woff2,ttf}",
1818
"style/**/*.{css,eot,gif,html,jpg,json,png,svg,woff2,ttf}",
19-
"schema/*.json"
19+
"schema/*.json",
20+
"style/index.js"
2021
],
2122
"main": "lib/index.js",
2223
"types": "lib/index.d.ts",
@@ -27,58 +28,62 @@
2728
},
2829
"scripts": {
2930
"build": "jlpm run build:lib",
31+
"build:all": "jlpm run build:labextension",
3032
"build:labextension": "cd code_snippets && rimraf labextension && mkdirp labextension && cd labextension && npm pack ../..",
3133
"build:lib": "tsc",
32-
"build:all": "jlpm run build:labextension",
3334
"clean": "jlpm run clean:lib",
34-
"clean:lib": "rimraf lib tsconfig.tsbuildinfo",
35-
"clean:labextension": "rimraf code_snippets/labextension",
3635
"clean:all": "jlpm run clean:lib && jlpm run clean:labextension",
36+
"clean:labextension": "rimraf code_snippets/labextension",
37+
"clean:lib": "rimraf lib tsconfig.tsbuildinfo",
3738
"eslint": "eslint . --ext .ts,.tsx --fix",
3839
"eslint:check": "eslint . --ext .ts,.tsx",
40+
"format": "prettier \"src/**/*.{ts, tsx}\" --check",
3941
"prepare": "jlpm run clean && jlpm run build",
40-
"watch": "tsc -w",
41-
"format": "prettier \"src/**/*.{ts, tsx}\" --check"
42+
"watch": "tsc -w"
4243
},
4344
"dependencies": {
44-
"@jupyterlab/application": "^2.1.2",
45-
"@jupyterlab/apputils": "^2.2.4",
46-
"@jupyterlab/cells": "^2.2.4",
47-
"@jupyterlab/docmanager": "^2.1.2",
48-
"@jupyterlab/docregistry": "^2.1.2",
49-
"@jupyterlab/fileeditor": "^2.1.2",
50-
"@jupyterlab/nbformat": "^2.1.0",
51-
"@jupyterlab/notebook": "^2.1.2",
52-
"@jupyterlab/rendermime": "^2.1.1",
53-
"@jupyterlab/services": "^5.0.0",
54-
"@lumino/algorithm": "^1.3.2",
45+
"@jupyterlab/application": "^3.0.2",
46+
"@jupyterlab/apputils": "^3.0.2",
47+
"@jupyterlab/cells": "^3.0.2",
48+
"@jupyterlab/docmanager": "^3.0.2",
49+
"@jupyterlab/docregistry": "^3.0.2",
50+
"@jupyterlab/fileeditor": "^3.0.2",
51+
"@jupyterlab/nbformat": "^3.0.1",
52+
"@jupyterlab/notebook": "^3.0.2",
53+
"@jupyterlab/rendermime": "^3.0.2",
54+
"@jupyterlab/services": "^6.0.2",
55+
"@lumino/algorithm": "^1.3.3",
5556
"@lumino/coreutils": "^1.5.3",
56-
"@lumino/dragdrop": "^1.6.2",
57-
"@lumino/messaging": "^1.4.2",
58-
"@lumino/properties": "^1.2.2",
59-
"@lumino/signaling": "^1.4.2",
60-
"@lumino/widgets": "^1.13.2"
57+
"@lumino/dragdrop": "^1.7.1",
58+
"@lumino/messaging": "^1.4.3",
59+
"@lumino/properties": "^1.2.3",
60+
"@lumino/signaling": "^1.4.3",
61+
"@lumino/widgets": "^1.16.1"
6162
},
6263
"devDependencies": {
63-
"@typescript-eslint/eslint-plugin": "^2.25.0",
64-
"@typescript-eslint/parser": "^2.25.0",
65-
"eslint": "^7.7.0",
64+
"@jupyterlab/builder": "^3.0.0-rc.13",
65+
"@typescript-eslint/eslint-plugin": "^2.27.0",
66+
"@typescript-eslint/parser": "^2.27.0",
67+
"eslint": "^7.5.0",
6668
"eslint-config-prettier": "^6.10.1",
6769
"eslint-plugin-prettier": "^3.1.2",
6870
"eslint-plugin-react": "^7.20.4",
6971
"husky": "^4.2.5",
7072
"lint-staged": "^10.2.13",
7173
"mkdirp": "^1.0.3",
72-
"prettier": "^1.19.1",
73-
"rimraf": "^2.6.1",
74-
"typescript": "~3.7.3"
74+
"npm-run-all": "^4.1.5",
75+
"prettier": "^1.19.0",
76+
"rimraf": "^3.0.2",
77+
"typescript": "~4.1.3"
7578
},
7679
"sideEffects": [
77-
"style/*.css"
80+
"style/*.css",
81+
"style/index.js"
7882
],
7983
"jupyterlab": {
8084
"extension": true,
81-
"schemaDir": "schema"
85+
"schemaDir": "schema",
86+
"outputDir": "code_snippet/labextension"
8287
},
8388
"husky": {
8489
"hooks": {
@@ -90,5 +95,6 @@
9095
"eslint --cache --fix"
9196
],
9297
"*.js": "eslint --cache --fix"
93-
}
94-
}
98+
},
99+
"styleModule": "style/index.js"
100+
}

pyproject.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[build-system]
2+
requires = ["jupyter_packaging~=0.7.9", "jupyterlab>=3.0.0rc13,==3.*", "setuptools>=40.8.0", "wheel"]
3+
build-backend = "setuptools.build_meta"

setup.py

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -13,26 +13,26 @@
1313
HERE = os.path.abspath(os.path.dirname(__file__))
1414

1515
# The name of the project
16-
name="metadata_code_snippets"
16+
# name="metadata_code_snippets"
1717

1818
# Ensure a valid python version
1919
ensure_python(">=3.5")
2020

2121
# Get our version
22-
version = get_version(os.path.join(name, "_version.py"))
22+
version = get_version("_version.py")
2323

24-
lab_path = os.path.join(HERE, name, "labextension")
24+
# lab_path = os.path.join(HERE, name, "labextension")
2525

2626
# Representative files that should exist after a successful build
27-
jstargets = [
28-
os.path.join(HERE, "lib", "CodeSnippetService.js"),
29-
]
27+
# jstargets = [
28+
# os.path.join(HERE, "lib", "CodeSnippetService.js"),
29+
# ]
3030

31-
package_data_spec = {
32-
name: [
33-
"*"
34-
]
35-
}
31+
# package_data_spec = {
32+
# name: [
33+
# "*"
34+
# ]
35+
# }
3636

3737
data_files_spec = [
3838
("share/jupyter/metadata/code-snippets", "share/jupyter/metadata/code-snippets", "*.json")
@@ -47,7 +47,7 @@
4747
long_description = fh.read()
4848

4949
setup_args = dict(
50-
name=name,
50+
name='code_snippet',
5151
version=version,
5252
url="https://github.com/jupytercalpoly/project2.git",
5353
author="Jay Ahn, Kiran Pinnipati",
@@ -56,8 +56,7 @@
5656
long_description_content_type="text/markdown",
5757
cmdclass=cmdclass,
5858
install_requires=[
59-
"jupyterlab~=2.0",
60-
"elyra==1.0.0b1"
59+
"jupyterlab~=3.0"
6160
],
6261
zip_safe=False,
6362
include_package_data=True,

0 commit comments

Comments
 (0)