-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
174 lines (154 loc) · 4.91 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
# Copyright (c) Jupyter Development Team.
# Distributed under the terms of the Modified BSD License.
[build-system]
build-backend = "hatchling.build"
requires = ["hatchling>=1.4.0", "hatch-nodejs-version", "jupyterlab>=4.0.0"]
[project]
name = "jupyter_collaboration"
readme = "README.md"
license = { file = "LICENSE" }
requires-python = ">=3.8"
classifiers = [
"Intended Audience :: Developers",
"Intended Audience :: System Administrators",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Framework :: Jupyter",
"Framework :: Jupyter :: JupyterLab",
"Framework :: Jupyter :: JupyterLab :: 4",
"Framework :: Jupyter :: JupyterLab :: Extensions",
"Framework :: Jupyter :: JupyterLab :: Extensions :: Prebuilt",
]
dependencies = [
"jupyter_server>=2.0.0,<3.0.0",
"jupyter_ydoc>=2.0.0,<3.0.0",
"pycrdt-websocket>=0.12.5,<0.13.0",
"jupyter_events>=0.7.0",
"jupyter_server_fileid>=0.7.0,<1",
"jsonschema>=4.18.0"
]
dynamic = ["version", "description", "authors", "urls", "keywords"]
[project.optional-dependencies]
dev = [
"click",
"pre-commit",
"jupyter_releaser"
]
test = [
"coverage",
"jupyter_server[test]>=2.0.0",
"jupyter_server_fileid[test]",
"pytest>=7.0",
"pytest-cov",
"websockets"
]
docs = [
"jupyterlab>=4.0.0",
"sphinx",
"myst-parser",
"pydata-sphinx-theme"
]
[tool.black]
line-length = 100
[tool.isort]
profile = "black"
[tool.hatch.version]
source = "nodejs"
[tool.hatch.build.hooks.version]
path = "jupyter_collaboration/_version.py"
[tool.hatch.metadata.hooks.nodejs]
fields = ["description", "authors", "urls"]
[tool.hatch.build.targets.sdist]
artifacts = ["/jupyter_collaboration/labextension"]
exclude = ["/.github", "/binder", "node_modules"]
[tool.hatch.build.targets.sdist.force-include]
"./packages" = "packages"
[tool.hatch.build.targets.wheel.shared-data]
"jupyter_collaboration/labextension" = "share/jupyter/labextensions/@jupyter/collaboration-extension"
"install.json" = "share/jupyter/labextensions/@jupyter/collaboration-extension/install.json"
"jupyter-config/jupyter_collaboration.json" = "etc/jupyter/jupyter_server_config.d/jupyter_collaboration.json"
[tool.hatch.build.hooks.jupyter-builder]
dependencies = ["hatch-jupyter-builder>=0.5"]
build-function = "hatch_jupyter_builder.npm_builder"
ensured-targets = [
"jupyter_collaboration/labextension/static/style.js",
"jupyter_collaboration/labextension/package.json",
]
skip-if-exists = ["jupyter_collaboration/labextension/static/style.js"]
[tool.hatch.build.hooks.jupyter-builder.build-kwargs]
npm = ["jlpm"]
build_cmd = "build:prod"
editable_build_cmd = "install:extension"
[tool.jupyter-releaser]
skip = ["check-links"]
[tool.jupyter-releaser.options]
version-cmd = "python scripts/bump_version.py --force"
[tool.jupyter-releaser.hooks]
before-build-npm = [
"YARN_ENABLE_IMMUTABLE_INSTALLS=0 jlpm build:prod"
]
before-build-python = [
"jlpm clean:all",
# Build the assets
"jlpm build:prod",
# Clean the build artifacts to not include them in sdist
"jlpm clean:lib"
]
before-bump-version = [
"python -m pip install -U jupyterlab",
"jlpm"
]
[tool.check-wheel-contents]
ignore = ["W002"]
[tool.pytest.ini_options]
addopts = "-raXs --durations 10 --color=yes --doctest-modules"
testpaths = ["tests/"]
timeout = 300
# Restore this setting to debug failures
# timeout_method = "thread"
filterwarnings = [
"error",
# From tornado
"ignore:unclosed <socket.socket:ResourceWarning",
"module:make_current is deprecated:DeprecationWarning",
"module:clear_current is deprecated:DeprecationWarning",
"module:There is no current event loop:DeprecationWarning",
#
"module:Jupyter is migrating its paths to use standard platformdirs:DeprecationWarning",
# In PyPy/Cython: see https://github.com/yaml/pyyaml/issues/688
"ignore:can't resolve package from __spec__ or __package__, falling back on __name__ and __path__:ImportWarning",
# see https://github.com/dateutil/dateutil/issues/1314
"ignore:.*datetime.utcfromtimestamp\\(\\) is deprecated.*:DeprecationWarning:",
]
[tool.mypy]
exclude=[
"^binder/jupyter_config\\.py$",
]
check_untyped_defs = true
disallow_any_generics = false
disallow_incomplete_defs = true
disallow_untyped_decorators = true
no_implicit_optional = true
no_implicit_reexport = true
pretty = true
show_error_context = true
show_error_codes = true
strict_equality = true
strict_optional = true
warn_unused_configs = true
warn_redundant_casts = true
warn_return_any = false
warn_unused_ignores = true
ignore_missing_imports = true
[[tool.mypy.overrides]]
module = [
"traitlets.*",
"jupyter_server.*",
"terminado"
]
ignore_missing_imports = true