-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
79 lines (67 loc) · 3.11 KB
/
Copy pathpyproject.toml
File metadata and controls
79 lines (67 loc) · 3.11 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
[project]
name = "python-project-template"
version = "0.1.0"
description = "Add your description here"
readme = "README.md"
requires-python = ">=3.10"
dependencies = []
[dependency-groups]
dev = [
"pytest>=9.1.1",
"ruff>=0.15.18",
"ty>=0.0.51",
]
[build-system]
requires = ["uv_build<0.12"]
build-backend = "uv_build"
[tool.uv.build-backend]
module-name = "python_project_template"
module-root = "."
[tool.uv]
required-version = ">=0.8.4"
[tool.ruff]
target-version = 'py313'
line-length = 95
indent-width = 4
[tool.ruff.lint]
select = [
"A", # flake8-builtins ---------------> https://docs.astral.sh/ruff/rules/#flake8-builtins-a
"ANN", # flake8-annotations ------------> https://docs.astral.sh/ruff/rules/#flake8-annotations-ann
"B", # flake8-bugbear ----------------> https://docs.astral.sh/ruff/rules/#flake8-bugbear-b
"C4", # flake8-comprehensions ---------> https://docs.astral.sh/ruff/rules/#flake8-comprehensions-c4
"C90", # mccabe complexity -------------> https://docs.astral.sh/ruff/rules/#mccabe-c90
"DTZ", # flake8-datetimez --------------> https://docs.astral.sh/ruff/rules/#flake8-datetimez-dtz
"E", # pycodestyle errors ------------> https://docs.astral.sh/ruff/rules/#error-e
"ERA", # eradicate ---------------------> https://docs.astral.sh/ruff/rules/#eradicate-era
"F", # pyflakes ----------------------> https://docs.astral.sh/ruff/rules/#pyflakes-f
"I", # isort -------------------------> https://docs.astral.sh/ruff/rules/#isort-i
"LOG", # flake8-logging ---------------> https://docs.astral.sh/ruff/rules/#flake8-logging-log
"N", # pep8-naming -------------------> https://docs.astral.sh/ruff/rules/#pep8-naming-n
"RUF", # Ruff specific rules -----------> https://docs.astral.sh/ruff/rules/#ruff-specific-rules-ruf
"S", # flake8-bandit -----------------> https://docs.astral.sh/ruff/rules/#flake8-bandit-s
"TRY", # tryceratops -------------------> https://docs.astral.sh/ruff/rules/#tryceratops-try
"UP", # pyupgrade ---------------------> https://docs.astral.sh/ruff/rules/#pyflakes-f
"W", # pycodestyle warnings ----------> https://docs.astral.sh/ruff/rules/#warning-w
]
ignore = [
"ANN002", # missing type annotation for *args ------> https://docs.astral.sh/ruff/rules/missing-type-args/
"ANN003", # missing type annotation for **kwargs----> https://docs.astral.sh/ruff/rules/missing-type-kwargs/
"E501", # line-too-long --------------------------> https://docs.astral.sh/ruff/rules/line-too-long/
]
[lint.extend-per-file-ignores]
"tests/**/test*.py" = [ # in tests files ignore:
"S101", # - use of `assert` ---------------> https://docs.astral.sh/ruff/rules/assert/
"TRY002", # - rasing vanilla exceptions -----> https://docs.astral.sh/ruff/rules/raise-vanilla-class/
]
[tool.ruff.lint.isort]
combine-as-imports = true
[tool.ty.environment]
root = ["python_project_template"]
python = "./.venv"
[tool.uv-secure.vulnerability_criteria]
show_severity = true
ignore_unfixed = true
[tool.uv-secure.maintainability_criteria]
forbid_yanked = true
forbid_deprecated = true
forbid_quarantined = true