-
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathpyproject.toml
More file actions
196 lines (173 loc) · 5.32 KB
/
pyproject.toml
File metadata and controls
196 lines (173 loc) · 5.32 KB
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
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
# Copyright (c) 2023-2025 Datalayer, Inc.
# Distributed under the terms of the Modified BSD License.
[build-system]
requires = ["hatchling==1.21.1"]
build-backend = "hatchling.build"
[project]
name = "datalayer_core"
description="Datalayer Core"
keywords = []
readme = "README.md"
license = { text = "BSD-3-Clause" }
requires-python = ">=3.10"
classifiers = [
"Framework :: Jupyter",
"Intended Audience :: Developers",
"Intended Audience :: System Administrators",
"Intended Audience :: Science/Research",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
]
# TODO Unpin keyring https://github.com/datalayer/core/issues/36
dependencies = [
"httpx",
"jupyter-console",
"jupyter-kernel-client",
"jupyter-nbmodel-client",
"jupyter-server>=2.10,<3",
"keyring==23.0.1",
"mcp",
"pydantic-settings",
"pydantic[email]",
"pyyaml>=6.0", # Require newer PyYAML that builds on Python 3.12+
"questionary",
"requests>=2.33.0",
"pygments>=2.20.0",
"rich",
"traitlets",
"typer",
]
dynamic = ["version"]
[project.urls]
Homepage = "https://github.com/datalayer/core"
Documentation = "https://core.datalayer.tech"
Repository = "https://github.com/datalayer/core"
Issues = "https://github.com/datalayer/core/issues"
Changelog = "https://github.com/datalayer/core/blob/main/CHANGELOG.md"
[project.optional-dependencies]
test = [
"coverage",
"mypy",
"pytest",
"pytest-asyncio",
"pytest-cov",
"pytest_jupyter",
"pytest-tornasync",
"python-dotenv",
"types-requests",
"typing-extensions",
]
docs = [
"click>=8.3.1", # Use latest version, 8.2.2 issue has been fixed
"npdoc_to_md",
"pydoc-markdown>=4.0", # Use modern version with proper module structure
]
examples = [
"fastapi",
"pydantic",
"scikit-learn",
"streamlit",
"torch",
"uvicorn",
]
otel = [
"logfire>=3.0.0",
"opentelemetry-api>=1.20.0",
"opentelemetry-sdk>=1.20.0",
"opentelemetry-exporter-otlp-proto-http>=1.20.0",
]
[project.scripts]
d = "datalayer_core.cli.__main__:main"
dla = "datalayer_core.cli.__main__:main"
datalayer = "datalayer_core.cli.__main__:main"
datalayer-config = "datalayer_core.config:main"
datalayer-migrate = "datalayer_core.migrate:main"
datalayer-server = "datalayer_core.serverapplication:main"
datalayer-troubleshoot = "datalayer_core.troubleshoot:main"
[tool.hatch.version]
path = "datalayer_core/__version__.py"
[tool.hatch.build.targets.sdist]
artifacts = [
"datalayer_core/assets/about.md",
]
exclude = [".github", "binder"]
[tool.hatch.build.targets.wheel]
artifacts = [
"datalayer_core/assets/about.md",
]
[tool.hatch.build.targets.wheel.shared-data]
"jupyter-config/server-config" = "etc/jupyter/jupyter_server_config.d"
"jupyter-config/nb-config" = "etc/jupyter/jupyter_notebook_config.d"
[tool.hatch.build.hooks.version]
path = "datalayer_core/_version.py"
[tool.jupyter-releaser.options]
version_cmd = "hatch version"
[tool.mypy]
follow_imports = "skip"
ignore_missing_imports = true
disallow_untyped_defs = true
disallow_any_generics = true
warn_unused_ignores = true
[[tool.mypy.overrides]]
module = "tornado.*"
ignore_errors = true
[[tool.mypy.overrides]]
module = "datalayer_core.handlers.chat.*"
disable_error_code = ["attr-defined"]
[tool.ruff.lint]
extend-select = ["I"]
[tool.poetry]
version = "0.1.0"
[tool.numpydoc_validation]
checks = [
"all", # report on all checks, except the below
"EX01", # No examples section found
"SA01", # See Also section found
"ES01", # No extended summary found
"GL08", # The object does not have a docstring
"PR01", # Parameters not documented
"PR02", # Unknown parameters
"RT01", # No Returns section found
]
exclude = [ # don't report on objects that match any of these regex
'\.undocumented_method$',
'\.__repr__$',
'\.test_.*$',
'\.__init__$', # Skip __init__ methods
'\.Config$', # Skip Pydantic Config classes
]
exclude_files = [ # don't process filepaths that match these regex
'^test_.*.py$',
]
[tool.pydoc-markdown]
loaders = [
{ type = "python", search_path = ["datalayer_core"] }
]
processors = [
{ type = "filter", skip_empty_modules = false },
{ type = "smart" },
{ type = "crossref" },
{ type = "datalayer_core._pydoc.ReplaceProcessor" }
]
[tool.pydoc-markdown.renderer]
type = "datalayer_core._pydoc.MyDocusaurusRenderer"
docs_base_path = "docs/docs"
relative_output_path = "python_api"
relative_sidebar_path = "sidebar.json"
sidebar_top_level_label = ""
[tool.bandit]
exclude_dirs = ["tests"]
skips = [
"B101", # Assert statements are acceptable in this codebase
"B105", # Hardcoded password strings - these are configuration keys, not actual passwords
"B106", # Hardcoded password funcarg - false positive for empty default values
"B110", # Try/except pass is acceptable for error handling
"B404", # Subprocess import is needed for legitimate process management
"B603", # Subprocess calls are controlled and necessary for CLI operations
"B606", # Process execution without shell is safer and intentional
"B607", # Partial path execution is acceptable for known binaries
]