-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathpyproject.toml
117 lines (103 loc) · 2.96 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
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "apricot-server"
dynamic = ["version"]
description = "A proxy for delegating LDAP requests to an OpenID Connect backend."
readme = "README.md"
requires-python = ">=3.7"
license = "BSD-3-Clause"
keywords = []
authors = [
{ name = "James Robinson", email = "[email protected]" },
]
classifiers = [
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
]
dependencies = [
"ldaptor~=21.2",
"oauthlib~=3.2",
"pydantic~=2.4",
"redis~=5.0",
"requests-oauthlib~=1.3",
"Twisted~=23.10",
"zope.interface~=6.2",
]
[project.urls]
Documentation = "https://github.com/alan-turing-institute/apricot#readme"
Issues = "https://github.com/alan-turing-institute/apricot/issues"
Source = "https://github.com/alan-turing-institute/apricot"
[tool.hatch.version]
path = "apricot/__about__.py"
[tool.hatch.build.targets.wheel]
packages = ["."]
[tool.hatch.envs.lint]
detached = true
dependencies = [
"black~=24.2",
"mypy~=1.8",
"ruff~=0.7",
"types-oauthlib~=3.2",
"types-redis~=4.6",
"types-requests~=2.31",
"typing-extensions~=4.12",
]
[tool.hatch.envs.lint.scripts]
typing = "mypy {args:apricot} run.py"
style = [
"black --check --diff {args:apricot run.py .github}",
"ruff check --preview {args:apricot run.py .github}",
]
fmt = [
"black {args:apricot run.py .github}",
"ruff check --preview --fix {args:apricot run.py .github}",
"style",
]
all = [
"style",
"typing",
]
[tool.ruff.lint]
# See https://beta.ruff.rs/docs/rules/
select = ["ALL"]
ignore = [
"D100", # missing-docstring-in-module
"D104", # missing-docstring-in-package
"D203", # one-blank-line-before-class (due to conflict with D211)
"D213", # multi-line-summary-second-line (due to conflict with D212)
"CPY001", # missing-copyright-notice
"G010", # logging-warn (due to incorrect heuristic)
]
[tool.ruff.lint.flake8-annotations]
allow-star-arg-any = true
[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "parents"
[tool.ruff.lint.isort]
combine-as-imports = true
known-first-party = ["apricot"]
[tool.ruff.lint.pydocstyle]
convention = "google"
ignore-decorators = ["typing.override"]
[tool.mypy]
disallow_subclassing_any = false # allow subclassing of types from third-party libraries
files = "apricot" # run mypy over this directory
strict = true # enable all optional error checking flags
[[tool.mypy.overrides]]
module = [
"ldaptor.*",
"pydantic.*",
"requests_oauthlib.*",
"twisted.*",
"zope.interface.*",
]
ignore_missing_imports = true