-
Notifications
You must be signed in to change notification settings - Fork 116
/
pyproject.toml.in
122 lines (104 loc) · 2.91 KB
/
pyproject.toml.in
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
[project]
name = "pcs"
version = "@VERSION@"
requires-python = ">=3.12"
description = "Pacemaker/Corosync Configuration System"
authors = [
{name = "Chris Feist", email = "[email protected]"},
]
readme = "README.md"
[project.urls]
Repository = "https://github.com/ClusterLabs/pcs"
[build-system]
requires = ["setuptools >= 66.1"]
build-backend = "setuptools.build_meta"
[project.scripts]
pcs = "pcs.entry_points.cli:main"
pcsd = "pcs.entry_points.daemon:main"
pcs_snmp_agent = "pcs.entry_points.snmp_agent:main"
pcs_internal = "pcs.entry_points.internal:main"
[tool.setuptools]
# True by default in pyproject.toml, keeping old behavior
include-package-data = false
# If newly excluded packages still persist, try to remove `./*.egg-info` and
# `./build`. Don't waste time: https://stackoverflow.com/a/59686298/22796102
[tool.setuptools.packages.find]
exclude = [
"pcs_*",
"@PACKAGE_WEBUI_BACKEND@",
]
[tool.setuptools.package-data]
pcs = ["py.typed"]
################################################################################
# NON-BUILD TOOLS
################################################################################
# Required versions of linter tools: see dev_requirements.txt
# This project should not contain any issues reported by any linter when using
# this command to run linters on the whole project:
# $ make check
[tool.black]
line-length = 80
target-version = ['py312']
[tool.isort]
profile = "black"
line_length = 80
multi_line_output = 3
force_grid_wrap = 2
atomic = true
py_version = 312
skip_gitignore = true
sections = ['FUTURE', 'STDLIB', 'THIRDPARTY', 'FIRSTPARTY', 'TESTS', 'LOCALFOLDER']
known_first_party = ["pcs"]
known_tests = ["pcs_test"]
supported_extensions = ["py", "py.in"]
[tool.pylint.main]
disable = [
# not critical, plus we use str.format() for readability
"consider-using-f-string",
# TODO is used to mark e.g. deprecations which are to be resolved in next pcs
# major version
"fixme",
# handled by black
"line-too-long",
# we dont require pointless docstring to be present
"missing-docstring",
"similarities",
"unspecified-encoding",
# lot of dict() in code to be replaced, not worth the effort now
"use-dict-literal",
# handled by isort
"wrong-import-order",
]
extension-pkg-allow-list = ["lxml.etree", "pycurl"]
load-plugins = ["pylint.extensions.no_self_use"]
persistent = false
reports = false
score = false
[tool.pylint.basic]
# Everything in module context is a constant, but our naming convention allows
# constants to have the same name format as variables
const-rgx = "(([A-Z_][A-Z0-9_]*)|(__.*__))|([a-z_][a-z0-9_]*)$"
good-names = [
"e",
"i",
"op",
"ip",
"el",
"maxDiff",
"cm",
"ok",
"T",
"dr",
"setUp",
"tearDown",
]
[tool.pylint.design]
max-args = 8
max-parents = 10
max-positional-arguments = 8
min-public-methods = 0
[tool.pylint.format]
max-module-lines = 1500
max-line-length = 80
[tool.pylint.variables]
dummy-variables-rgx = "_$|dummy"