File: pyproject.toml

package info (click to toggle)
python-cotyledon 2.2.0-3
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 300 kB
  • sloc: python: 1,336; makefile: 16
file content (179 lines) | stat: -rw-r--r-- 3,833 bytes parent folder | download
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
[build-system]
requires = ["setuptools", "setuptools_scm"]
build-backend = "setuptools.build_meta"

[project]
name = "cotyledon"
description = "Cotyledon provides a framework for defining long-running services."
readme = "README.rst"
authors = [
    {name = "Mehdi Abaakouk", email = "sileht@sileht.net"}
]
classifiers = [
   "Intended Audience :: Information Technology",
   "Intended Audience :: System Administrators",
   "Operating System :: POSIX :: Linux",
   "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",
]
license = "Apache-2.0"
dynamic = ["version"]
requires-python = ">= 3.9"
dependencies = [
  "setproctitle; sys_platform != 'win32'",
  "typing_extensions",
]
[project.optional-dependencies]
test = [
    "mock",
    "pytest",
    "pytest-cov",
    "pytest-xdist"
]
oslo = [
    "oslo.config>=3.14.0",
]
doc = [
    "sphinx_rtd_theme",
    "sphinx"
]

[project.entry-points."oslo.config.opts"]
"cotyledon" = "cotyledon.oslo_config_glue:list_opts"

[project.urls]
"Home Page" = "https://github.com/sileht/cotyledon"

[tool.setuptools_scm]

[tool.setuptools.package-data]
cotyledon = ["py.typed"]

[tool.ruff]
line-length = 88
indent-width = 4
target-version = "py39"
exclude = ["doc/source/conf.py"]

[tool.ruff.lint]
preview = true
select = [
    "F",
    "E",
    "W",
    "I",
    "N",
    "UP",
    "YTT",
    "ANN",
    "ASYNC",
    "S",
    "BLE",
    "FBT",
    "B",
    "A",
    "COM",
    "C4",
    "DTZ",
    "T10",
    "EM",
    "FA",
    "ISC",
    "ICN",
    "G",
    "INP",
    "PIE",
    "T20",
    "PYI",
    "PT",
    "Q",
    "RSE",
    "RET",
    "SLF",
    "SLOT",
    "SIM",
    "TID",
    "TCH",
    "INT",
    # "ARG", # unused args
    # "PTH", # pathlib.Path
    "TD",
    "ERA",
    "PGH",
    "PL",
    "TRY",
    "FLY",
    "NPY",
    "PERF",
    "FURB",
    "LOG",
    "RUF",
]

ignore = [
    # NOTE(charly): line-length is up to the formatter
    "E501",
    # NOTE(charly): `subprocess` module is possibly insecure
    "S404",
    # NOTE(jd): likely a false positive https://github.com/PyCQA/bandit/issues/333
    "S603",
    # NOTE(charly): Starting a process with a partial executable path
    "S607",
    # NOTE(charly): Boolean-typed positional argument in function definition.
    # Interesting, but require some work.
    "FBT001",
    # NOTE(charly): Boolean default positional argument in function definition.
    # Interesting, but require some work.
    "FBT002",
    # NOTE(charly): Missing issue link on the line following this TODO
    "TD003",
    # NOTE(charly): Magic value used in comparison
    "PLR2004",
    # List comprehensions are most efficient in most cases now
    "PLR1702",
    # We use mock.patch.object, which automatically pass the mock as an
    # argument to the test if no `new` is specified, without needing the mock
    # itself.
    "PT019",
    # We don't want to enforce the number of statements
    "PLR0914", "PLR0912", "PLR0915",
]
[tool.ruff.lint.per-file-ignores]
"cotyledon/tests/*.py" = ["S101", "SLF001", "PLR6301"]

[tool.ruff.lint.isort]
force-single-line = true
force-sort-within-sections = true
lines-after-imports = 2
known-first-party = ["cotyledon"]

[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "all"

[tool.ruff.lint.flake8-pytest-style]
parametrize-values-type = "list"
parametrize-values-row-type = "tuple"

[tool.ruff.lint.flake8-type-checking]
strict = true
quote-annotations = true

[tool.mypy]
strict = true
warn_unreachable = true
exclude = [
    ".venv",
    "doc",
]
files = ["cotyledon"]
show_error_codes = true

[[tool.mypy.overrides]]
module = [
    "oslo_config.*"
]
ignore_missing_imports = true