forked from ip-tools/python-epo-ops-client
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
95 lines (82 loc) · 1.8 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
# ==================
# Build system setup
# ==================
[build-system]
requires = [
"setuptools>=42", # At least v42 of setuptools required!
"versioningit",
]
build-backend = "setuptools.build_meta"
[tool.ruff]
line-length = 80
select = [
# Bandit
"S",
# Bugbear
"B",
# Builtins
"A",
# comprehensions
"C",
# eradicate
"ERA",
# flake8-2020
"YTT",
# isort
"I",
# pandas-vet
"PD",
# print
"T20",
# Pycodestyle
"E",
"W",
# Pyflakes
"F",
# return
"RET",
# from `.flake8` file
"T", # T4
"B9",
]
extend-exclude = [
"__init__.py",
]
ignore = [
"E203",
"E266",
"E501",
"ERA001", # Found commented-out code
"RET505", # Unnecessary `else` after `return` statement
# "W503", # Unknown rule selector
]
# from `.isort.cfg` file
[tool.ruff.isort]
combine-as-imports = true
force-wrap-aliases = true
known-third-party = ["dateutil", "dogpile", "dotenv", "pytest", "requests", "six"]
split-on-trailing-comma = false
# from `.flake8` file
[tool.ruff.mccabe]
# Flag errors (`C901`) whenever the complexity level exceeds the configured value.
max-complexity = 7
[tool.ruff.per-file-ignores]
"tests/*" = [
"S101", # Use of `assert` detected
]
"epo_ops/api.py" = [
"A001", # Variable `range` is shadowing a Python builtin
"A002", # Argument `input` is shadowing a Python builtin
"C408", # Unnecessary `dict` call (rewrite as a literal)
]
# FIXME: Improve this situation wrt. SQL injection, even it is not be an actual attack vector.
"*sqlite.py" = [
"S608", # Possible SQL injection vector through string-based query construction
]
"tests/middlewares/throttle/conftest.py" = [
"S311", # Standard pseudo-random generators are not suitable for cryptographic purposes
]
[tool.versioningit]
[tool.versioningit.vcs]
method = "git"
default-tag = "0.0.0"