-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
141 lines (121 loc) · 3.46 KB
/
pyproject.toml
File metadata and controls
141 lines (121 loc) · 3.46 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
[build-system]
requires = ["hatchling", "hatch-vcs"]
build-backend = "hatchling.build"
[project]
name = "daggerml"
dynamic = ["version"]
authors = [
{ name="DaggerML", email="engineering@daggerml.com" }
]
description = "DaggerML"
readme = "README.md"
requires-python = ">=3.9"
license = "MIT"
keywords = []
classifiers = [
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: Implementation :: PyPy",
]
dependencies = []
[project.optional-dependencies]
cli = ["daggerml-cli>=0.0.38"]
dev = [
"pytest",
"pytest-cov",
"moto[all,server]",
]
[project.urls]
Homepage = "https://daggerml.com"
Documentation = "https://daggerml.com"
Issues = "https://github.com/daggerml/python-lib/issues"
Source = "https://github.com/daggerml/python-lib"
License = "https://github.com/daggerml/python-lib/blob/master/LICENSE"
[tool.pytest.ini_options]
pythonpath = "tests/"
minversion = "6.0"
addopts = "-ra --ignore=submodules/"
testpaths = [
"tests",
"src/daggerml",
]
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
"serial",
]
[tool.hatch.version]
source = "vcs"
[tool.hatch.version.raw-options]
version_scheme = "only-version" # use tag as version
local_scheme = "no-local-version" # pypi does not support local-schemes
tag_regex = "^v(?P<version>[0-9]+\\.[0-9]+\\.[0-9]+(?:[-\\.][a-zA-Z0-9]+)*)$"
version_file = "src/daggerml/__about__.py" # write version info to this file
relative_to = "{root:uri}"
[tool.hatch.build.targets.wheel]
packages = ["src/daggerml"]
artifacts = [
"src/daggerml/__about__.py" # add to hatch build because it's git ignored
]
[tool.hatch.envs.default]
python="3.10"
features = ["dev"]
dependencies = ["twine"]
pre-install-commands = [
"pip install -e {root:uri}/submodules/daggerml_cli",
]
[tool.hatch.envs.default.scripts]
test = 'pytest . {args}'
coverage-report = 'pytest --cov-report term-missing --cov=daggerml tests/'
dml-build = "hatch build && twine upload -r {args:testpypi} dist/*"
[tool.hatch.envs.test-all]
template = "default"
[[tool.hatch.envs.test-all.matrix]]
python = ["3.9", "3.10", "3.11", "3.12", "3.13"]
[tool.ruff]
target-version = "py39"
line-length = 120
[tool.ruff.lint]
select = ["E", "F", "B", "I", "PGH004"]
ignore = []
unfixable = ["B"]
[tool.ruff.lint.isort]
known-first-party = ["daggerml"]
[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "all"
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401", "E402"]
# Tests can use magic values, assertions, and relative imports
"tests/**/*" = ["PLR2004", "S101", "TID252"]
[tool.coverage.run]
source_pkgs = ["daggerml"]
branch = true
parallel = true
omit = [
"src/daggerml/__init__.py",
]
[tool.coverage.paths]
daggerml = ["src/daggerml", "*/python-lib/src/daggerml"]
tests = ["tests", "*/python-lib/tests"]
[tool.coverage.report]
exclude_lines = [
"no cov",
"if __name__ == .__main__.:",
"if TYPE_CHECKING:",
]
[tool.pyright]
include = ["src"]
defineConstant = { DEBUG = true }
typeCheckingMode = "basic"
reportGeneralTypeIssues = false
reportMissingImports = "error"
reportMissingTypeStubs = false
reportOptionalCall = false
reportOptionalMemberAccess = false