-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
56 lines (49 loc) · 1.35 KB
/
pyproject.toml
File metadata and controls
56 lines (49 loc) · 1.35 KB
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
[tool.ruff]
line-length = 100
target-version = "py310"
fix = true
cache-dir = ".cache/.ruff"
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
"I", # isort
"UP", # pyupgrade
"B", # flake8-bugbear
"S", # flake8-bandit (security)
"D", # pydocstyle
"C4", # flake8-comprehensions
"SIM", # flake8-simplify
"RUF", # ruff-specific rules
]
ignore = [
"E501", # line length handled by formatter
"D100", # missing module docstring (filter module files are documented via YAML sidecar)
"D104", # missing package docstring (__init__.py files)
]
[tool.ruff.lint.isort]
known-first-party = ["ansible_collections.network.compliance"]
lines-after-imports = 2
required-imports = ["from __future__ import annotations"]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.lint.per-file-ignores]
"tests/**" = [
"S101", # assert allowed in tests
"S106", # pass_msg parameter triggers false positive for hardcoded password
"D", # no docstring requirements for tests
]
"plugins/filter/__init__.py" = ["D"]
[tool.pytest.ini_options]
addopts = ["-vvv", "--color", "yes"]
testpaths = ["tests"]
filterwarnings = [
"ignore::DeprecationWarning:ansible.*",
]
[tool.coverage.run]
branch = true
source = ["plugins"]
[tool.coverage.report]
fail_under = 80
show_missing = true