-
Notifications
You must be signed in to change notification settings - Fork 23
/
pyproject.toml
143 lines (123 loc) · 2.57 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
137
138
139
140
141
142
143
[build-system]
requires = ["setuptools>=42", "wheel"]
build-backend = "setuptools.build_meta"
[tool.pytest.ini_options]
log_level = "INFO"
testpaths = ["tests"]
filterwarnings = [
"ignore:The _yaml extension module is now located at yaml._yaml",
]
[tool.coverage.run]
branch = true
source = ["src"]
omit = [
"src/suitable/_modules.py",
"src/suitable/_module_types.py",
"src/suitable/types.py",
]
[tool.bandit]
exclude_dirs = ["tests"]
skips = ["B101"]
[tool.mypy]
python_version = "3.8"
follow_imports = "silent"
namespace_packages = true
explicit_package_bases = true
strict = true
mypy_path = "$MYPY_CONFIG_FILE_DIR/src"
[[tool.mypy.overrides]]
module = ["suitable._module_types"]
warn_return_any = false
[tool.bumpversion]
current_version = "0.20.3"
commit = true
message = "Release {new_version}"
tag = true
tag_message = "Release {new_version}"
[[tool.bumpversion.files]]
filename="setup.cfg"
[[tool.bumpversion.files]]
filename="docs/conf.py"
[[tool.bumpversion.files]]
filename="CHANGELOG.rst"
search = """
Changelog
---------
"""
replace = """
Changelog
---------
{new_version} ({now:%Y-%m-%d})
~~~~~~~~~~~~~~~~~~~
"""
[tool.tox]
legacy_tox_ini = """
[tox]
envlist =
py{38,39,310}-ansible6
py{39,310,311}-ansible7
py{39,310,311}-ansible8
py{310,311,312}-ansible9
py{310,311,312}-ansible10
flake8
bandit
mypy
report
[gh-actions]
python =
3.8: py38
3.9: py39
3.10: py310,flake8,bandit,mypy
3.11: py311
3.12: py312
[testenv]
usedevelop = true
setenv =
py{38,39,310,311,312}: COVERAGE_FILE = .coverage.{envname}
deps =
-e{toxinidir}[tests]
ansible6: ansible==6.*
ansible6: ansible-core==2.13.*
ansible7: ansible==7.*
ansible7: ansible-core==2.14.*
ansible8: ansible==8.*
ansible8: ansible-core==2.15.*
ansible9: ansible==9.*
ansible9: ansible-core==2.16.*
ansible10: ansible==10.*
ansible10: ansible-core==2.17.*
commands = pytest --cov --cov-report= {posargs}
passenv = *
[testenv:flake8]
basepython = python3.10
skip_install = true
deps =
flake8
flake8-bugbear
commands = flake8 src/ tests/
[testenv:bandit]
basepython = python3.10
skip_install = true
deps =
bandit[toml]
commands = bandit -q -c pyproject.toml -r src
[testenv:mypy]
basepython = python3.10
deps =
-e{toxinidir}
mypy
mitogen
commands =
mypy -p suitable --python-version 3.8
mypy -p suitable --python-version 3.9
mypy -p suitable --python-version 3.10
mypy -p suitable --python-version 3.11
mypy -p suitable --python-version 3.12
[testenv:report]
deps =
coverage
skip_install = true
commands =
coverage combine
coverage report -m
"""