forked from dosisod/refurb
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
117 lines (101 loc) · 2.4 KB
/
pyproject.toml
File metadata and controls
117 lines (101 loc) · 2.4 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
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
[tool.poetry]
name = "refurb"
version = "1.17.0"
description = "A tool for refurbish and modernize Python codebases"
authors = ["dosisod"]
license = "GPL-3.0-only"
readme = "README.md"
repository = "https://github.com/dosisod/refurb"
classifiers = [
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Topic :: Software Development :: Testing",
"Typing :: Typed"
]
[tool.poetry.dependencies]
python = ">=3.10"
mypy = ">=0.981"
tomli = {version = "^2.0.1", python = "<3.11"}
[tool.poetry.dev-dependencies]
black = "^22.6.0"
isort = "^5.10.1"
pytest = "^7.1.2"
[tool.poetry.scripts]
refurb = "refurb.__main__:main"
[tool.isort]
multi_line_output = 3
include_trailing_comma = true
color_output = true
[tool.mypy]
allow_redefinition = true
disallow_any_decorated = true
disallow_any_explicit = true
disallow_any_unimported = true
namespace_packages = true
pretty = true
strict = true
warn_unreachable = true
[[tool.mypy.overrides]]
module = "test.*"
allow_untyped_defs = true
[tool.coverage.run]
omit = [
"refurb/__main__.py",
"refurb/gen.py"
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"if TYPE_CHECKING:",
]
skip_covered = true
skip_empty = true
[tool.black]
exclude = "test/data/*"
line-length = 79
check = true
diff = true
color = true
[tool.pytest.ini_options]
addopts = "--cov=refurb --cov-report=html --cov-report=term-missing --cov-fail-under=100"
testpaths = ["test"]
[tool.ruff]
line-length = 79
select = ["ALL"]
# TODO: fix RUF100 not playing well with refurb
extend-ignore = [
"A001", "A002", "A003",
"ANN101", "ANN102", "ANN401", "ARG001",
"B905",
"C901",
"COM812",
"D100", "D101", "D102", "D103", "D104", "D105", "D107", "D200", "D202", "D203",
"D205", "D212", "D214", "D400", "D401", "D404", "D405", "D406", "D407", "D412",
"D415", "D416",
"EM101", "EM102",
"F821",
"FBT001",
"FIX002", "FIX004",
"I001",
"INP001",
"N813", "N818",
"PGH003",
"PLR0911", "PLR0912", "PLR0915", "PLR2004",
"PT012",
"RUF100",
"S101",
"SIM102",
"SLF001",
"T201",
"TD002", "TD003",
"TRY003", "TRY004",
]
extend-exclude = ["test/data*"]
[tool.ruff.per-file-ignores]
"test/*" = ["ANN201", "ARG001", "E501", "TCH001", "TCH002"]
"refurb/main.py" = ["E501"]
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"