-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathpyproject.toml
151 lines (140 loc) · 4.42 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
144
145
146
147
148
149
150
151
[tool.poetry]
name = "hs-test-python"
version = "0.1.0"
description = ""
authors = ["Hyperskill Team"]
readme = "README.md"
packages = [
{ include = "hstest" },
]
[tool.poetry.dependencies]
python = "^3.10"
psutil-wheels = "^5.8.0"
[tool.poetry.group.dev.dependencies]
mypy = "1.10.1"
ruff = "0.6.0"
matplotlib = "^3.9.2"
seaborn = "^0.13.2"
pandas = "^2.2.0"
scipy = "^1.12.0"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.ruff]
line-length = 100
target-version = "py310"
# Exclude a variety of commonly ignored directories.
exclude = [
".bzr",
".direnv",
".eggs",
".git",
".hg",
".mypy_cache",
".nox",
".pants.d",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"tests/outcomes",
"tests/projects",
"tests/sql",
"venv",
]
[tool.ruff.lint]
select = [
"ALL",
]
ignore = [
"ANN002", # Missing type annotation for `*args`
"ANN003", # Missing type annotation for `**kwargs`
"ANN101", # Missing type annotation for `self` in method
"ANN102", # Missing type annotation for `cls` in classmethod
"ANN401", # Dynamically typed expressions (typing.Any) are disallowed in
"ARG001", # Unused function argument
"ARG002", # Unused method argument
"ARG004", # Unused static method argument
"CPY001", # Missing copyright notice at top of file
"D100", # Missing docstring in public module
"D101", # Missing docstring in public class
"D102", # Missing docstring in public method
"D103", # Missing docstring in public function
"D104", # Missing docstring in public package
"D105", # Missing docstring in magic method
"D106", # Missing docstring in public nested class
"D107", # Missing docstring in __init__
"E203", # Whitespace before ':'
"EXE002", # The file is executable but no shebang is present
"FBT003", # Boolean positional value in function call
"FIX002", # Line contains TODO, consider resolving the issue
"N806", # Variable in function should be lowercase
"PLC0415", # `import` should be at the top-level of a file
"PLC1901", # `record['bio'] == ''` can be simplified to `not record['bio']` as an empty string is falsey
"PLR0904", # Too many public methods
"PLR0916", # Too many Boolean expressions
"PLR6301", # Method could be a function, class method, or static method
"PT", # Use a regular `assert` instead of unittest-style `assertEqual`
"S101", # Use of `assert` detected
"TD002", # Missing author in TODO
"TD003", # Missing issue link on the line following this TODO
# Ruff format recommend disable trid rule
"COM812", # Trailing comma missing
"COM819", # Checks for the presence of prohibited trailing commas
"D206", # Docstring should be indented with spaces, not tabs
"D300", # Use """triple double quotes"""
"E111", # Indentation is not a multiple of four
"E114", # Indentation is not a multiple of four (comment)
"E117", # Over-indented
"ISC001", # Conflict with ruff format | Checks for implicitly concatenated strings on a single line.
"ISC002", # Checks for implicitly concatenated strings across multiple lines.
"Q000", # Conflict with ruff format | Remove bad quotes
"Q001", # Checks for multiline strings that use single quotes or double quotes
"Q002", # Checks for docstrings that use single quotes or double quotes
"Q003", # Conflict with ruff format | Change outer quotes to avoid escaping inner quotes
"W191", # Indentation contains tabs
]
[tool.ruff.lint.mccabe]
max-complexity = 56
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.lint.pylint]
max-args = 11
max-branches = 27
max-returns = 7
max-statements = 153
max-nested-blocks = 7
[tool.ruff.lint.isort]
combine-as-imports = true
order-by-type = false
required-imports = ["from __future__ import annotations"]
[tool.mypy]
python_version = "3.10"
check_untyped_defs = true
disallow_any_generics = true
disallow_untyped_calls = true
disallow_untyped_decorators = true
explicit_package_bases = true
ignore_errors = false
ignore_missing_imports = true
implicit_reexport = true
strict_equality = true
strict_optional = true
warn_no_return = true
warn_redundant_casts = true
warn_unreachable = true
warn_unused_configs = true
warn_unused_ignores = true
exclude = [
"tests/outcomes",
"tests/projects",
"tests/sql",
"venv",
]