-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathpyproject.toml
More file actions
120 lines (101 loc) · 2.49 KB
/
pyproject.toml
File metadata and controls
120 lines (101 loc) · 2.49 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
118
[project]
authors = [
{name = "Daniel Sanz", email = "imsdn4z@gmail.com"},
{name = "Sergio Castillo", email = "s.cast.lara@gmail.com"},
{name = "Ludo van Orden"},
{name = "Dmitrii Fedotov"},
]
maintainers = [
{name = "Daniel Sanz", email = "imsdn4z@gmail.com"},
{name = "Sergio Castillo", email = "s.cast.lara@gmail.com"},
]
requires-python = "<4,>=3.9"
dependencies = [
"requests<3.0.0,>=2.32.4",
"dparse<1.0.0,>=0.6.4",
"click<9.0.0,>=8.1.8",
"rich<15.0.0,>=14.0.0",
"rapidfuzz<4.0.0,>=2.13.7",
"pyparsing<4.0.0,>=3.2.3",
"tomlkit<0.14.0,>=0.11.6",
"tomli<3.0.0,>=2.2.1; python_version < \"3.13\"",
]
name = "twyn"
description = "Security tool against dependency typosquatting attacks"
readme = "README.md"
dynamic = ["version"]
[tool.hatch.version]
path = "VERSION"
pattern = "v(?P<version>[^\\s]+)"
[tool.hatch.build.targets.wheel]
packages = ["src/twyn"]
[tool.hatch.build.targets.sdist]
include = [
"/src",
"/README.md",
"/LICENSE",
"/VERSION",
"/pyproject.toml",
]
[project.scripts]
twyn = "twyn.cli:entry_point"
[dependency-groups]
dev = [
"pytest<9.0.0,>=7.1.3",
"mypy>=0.982,<1.18",
"pytest-cov<7,>=4",
"ipdb<1.0.0,>=0.13.9",
"commitizen<5.0,>=2.38",
"pdbpp<1.0.0,>=0.11.6",
"ruff<0.12.4,>=0.5.1",
"types-requests<3.0.0.0,>=2.32.4.20250611",
]
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.ruff]
target-version = "py39"
line-length = 120
src = ["twyn", "tests"]
[tool.ruff.lint]
select = [
"C9", # mccabe
"E", # pycodestyle error
"W", # pycodestyle warning
"F", # pyflakes
"B", # bugbear
"D", # pydocstyle
"I", # isort
"C4", # comprehensions
"SIM", # simplify
"N", # pep8-naming
"TRY", # tryceratops
]
ignore = [
'D1', # pydocstyle enforcement of docstrings everywhere
'TRY003', # tryceratops too noisy
"E501", # line length (black handles it)
]
[tool.ruff.lint.pydocstyle]
convention = "pep257"
[tool.mypy]
python_version = "3.9"
ignore_missing_imports = true
namespace_packages = true
explicit_package_bases = true
warn_no_return = false
warn_unused_ignores = true
disallow_any_generics = true
[tool.pytest.ini_options]
addopts = """
-s
--cov
--cov-report term-missing
--cov-report=xml:./tests/coverage.xml
--junitxml=./tests/junit.xml
"""
[tool.coverage.run]
omit = ["tests/*"]
[tool.coverage.report]
fail_under = 95
exclude_lines = ["if TYPE_CHECKING:", "pragma: no cover"]