-
Notifications
You must be signed in to change notification settings - Fork 3
/
pyproject.toml
136 lines (124 loc) · 3.67 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
[build-system]
requires = [
"setuptools>=68",
"setuptools_scm[toml]>=8.0",
]
build-backend = "setuptools.build_meta"
[project]
name = "scitacean"
description = "High-level interface for SciCat"
license = { "file" = "LICENSE" }
authors = [{ name = "Scitacean contributors" }]
readme = "README.md"
keywords = ["scicat"]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Natural Language :: English",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Scientific/Engineering",
"Typing :: Typed",
]
requires-python = ">=3.10"
dependencies = [
"email-validator >= 2",
"httpx >= 0.24",
"pydantic >= 2",
"python-dateutil >= 2.8",
]
dynamic = ["version"]
[project.urls]
"Documentation" = "https://scicatproject.github.io/scitacean"
"Bug Tracker" = "https://github.com/SciCatProject/scitacean/issues"
"Source" = "https://github.com/SciCatProject/scitacean"
[project.optional-dependencies]
sftp = ["paramiko >= 3"]
test = [
"filelock >= 3",
"hypothesis >= 6.48",
"pyyaml >= 5"
]
[tool.setuptools_scm]
[tool.pytest.ini_options]
minversion = "7.0"
testpaths = "tests"
addopts = """
--strict-config
--strict-markers
--disable-socket
--allow-hosts=127.0.0.1,::1
-ra
-v
--hypothesis-profile=scitacean
"""
filterwarnings = [
"error",
# Many tests don't set a checksum, so File raises this warning.
"ignore:Cannot check if local file:UserWarning",
# From paramiko
"ignore:TripleDES has been moved:cryptography.utils.CryptographyDeprecationWarning",
]
[tool.mypy]
plugins = "pydantic.mypy"
mypy_path = "src"
exclude = ["docs/conf.py", "tools/model-generation", "venv"]
ignore_missing_imports = true
enable_error_code = [
"ignore-without-code",
"redundant-expr",
"truthy-bool",
]
strict = true
show_error_codes = true
warn_unreachable = true
[[tool.mypy.overrides]]
module = "tests.*"
disallow_untyped_defs = false
disallow_untyped_calls = false
[tool.pydantic-mypy]
init_forbid_extra = true
init_typed = true
warn_required_dynamic_aliases = true
[tool.ruff]
line-length = 88
extend-include = ["*.ipynb"]
extend-exclude = [".*", "__pycache__", "build", "dist", "venv"]
[tool.ruff.lint]
select = ["B", "C4", "D", "DTZ", "E", "F", "G", "I", "FBT003", "PERF", "PGH", "PT", "PYI", "RUF", "S", "T20", "UP", "W"]
ignore = [
"D105", # most magic methods don't need docstrings as their purpose is always the same
"E741", "E742", "E743", # do not use names ‘l’, ‘O’, or ‘I’; they are not a problem with a proper font
"UP038", # leads to slower code
# Conflict with ruff format, see
# https://docs.astral.sh/ruff/formatter/#conflicting-lint-rules
"COM812", "COM819", "D206", "D300", "E111", "E114", "E117", "ISC001", "ISC002", "Q000", "Q001", "Q002", "Q003", "W191",
]
fixable = ["I001"]
isort.known-first-party = ["scitacean"]
pydocstyle.convention = "numpy"
[tool.ruff.lint.per-file-ignores]
"tests/*" = [
"S101", # asserts are fine in tests
"D10", # no docstrings required in tests
"S324", # insecure hsh function; we don't use hashing for security
]
"docs/*" = [
"D", "E402", "F811", "F841", "RUF015", "S101", "T201",
]
"*.ipynb" = ["I"]
"docs/conf.py" = ["D10"]
"tools/*" = ["D10"]
"src/scitacean/model.py" = ["D10"]
"src/scitacean/testing/strategies.py" = ["D401"]
[tool.codespell]
ignore-words-list = [
"specfield",
"socio-economic",
]