-
Notifications
You must be signed in to change notification settings - Fork 38
/
pyproject.toml
149 lines (133 loc) · 4.21 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
[tool.poetry]
name = "renault-api"
version = "0.2.7"
description = "Renault API"
authors = ["epenet"]
license = "MIT"
readme = "README.rst"
homepage = "https://github.com/hacf-fr/renault-api"
repository = "https://github.com/hacf-fr/renault-api"
documentation = "https://renault-api.readthedocs.io"
classifiers = [
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
[tool.poetry.urls]
Changelog = "https://github.com/hacf-fr/renault-api/releases"
[tool.poetry.dependencies]
python = ">=3.8,<4.0"
# Warning: as of 2024-04-23, aiohttp is pinned to 3.9.5 on HA-core
aiohttp = ">=3.9.5"
# Warning: as of 2023-07-19, pyjwt is pinned to 2.8.0 on HA-core
PyJWT = ">=2.8.0"
#ensure cryptography (for pyjwt) is greater than 42.0.5 to account for PVE-2024-65647
cryptography = ">=42.0.5"
marshmallow-dataclass = ">=8.2.0"
click = { version = ">=8.0.1", optional = true }
tabulate = { version = ">=0.8.7", optional = true }
dateparser = {version = ">=1.0.0", optional = true}
#ensure six (for dateparser) is greater than 1.16 for python 3.12 compatibility
six = {version = "^1.16", optional = true}
[tool.poetry.group.dev.dependencies]
pytest = ">=7.3.1,<9.0.0"
coverage = {extras = ["toml"], version = "^7.2"}
safety = ">=2.3.5,<4.0.0"
mypy = "^1.2"
typeguard = ">=4.1.3,<5.0.0"
xdoctest = {extras = ["colors"], version = "^1.1.1"}
sphinx = ">=4.3.2,<8.0.0"
sphinx-autobuild = "^2021.3.14"
pre-commit = ">=2.21,<4.0"
ruff = ">=0.3.7"
darglint = "^1.8.1"
pre-commit-hooks = ">=4.4,<6.0"
sphinx-rtd-theme = ">=1.2,<3.0"
sphinx-click = ">=4.4,<7.0"
Pygments = "^2.15.0"
pytest-asyncio = ">=0.21,<0.25"
aioresponses = "^0.7.4"
pytest-cov = ">=4,<6"
#ensure urllib3 (for requests/sphinx) is greater than 1.26.5 to account for CVE-2021-33503
urllib3 = ">=1.26.15,<3.0.0"
#ensure certifi (for requests/sphinx) is greater than 2023.7.22 to account for CVE-2023-37920
certifi = ">=2023.7.22,<2025.0.0"
#ensure requests (for sphinx) is greater than 2.31.0 to account for CVE-2023-32681
requests = "^2.31.0"
#ensure tornado (for sphinx) is greater than 6.3.3 to account for GHSA-qppv-j76h-2rpx
tornado = "^6.3.3"
#ensure PyYAML (for sphinx) is greater than 6.0.1 to fix Cython wheel
PyYAML = "^6.0.1"
#ensure virtualenv (for pre-commit) is greater than 20.21.0 to account for PVE-2024-68477
virtualenv = ">=20.21.0"
[tool.poetry.extras]
cli = ["click", "tabulate", "dateparser"]
[tool.poetry.scripts]
renault-api = "renault_api.cli.__main__:main"
[tool.coverage.paths]
source = ["src", "*/site-packages"]
[tool.coverage.run]
branch = true
source = ["renault_api"]
[tool.coverage.report]
show_missing = true
fail_under = 100
[tool.mypy]
check_untyped_defs = true
disallow_any_generics = true
disallow_incomplete_defs = true
disallow_subclassing_any = true
disallow_untyped_calls = true
disallow_untyped_decorators = true
disallow_untyped_defs = true
no_implicit_optional = true
no_implicit_reexport = true
pretty = true
show_column_numbers = true
show_error_codes = true
show_error_context = true
strict_equality = true
warn_redundant_casts = true
warn_return_any = true
warn_unreachable = true
warn_unused_configs = true
warn_unused_ignores = true
[tool.ruff]
line-length = 88
target-version = "py38"
[tool.ruff.lint]
ignore = [
"A001", # Variable is shadowing a Python builtin
"A002", # Argument is shadowing a Python builtin
"N815", # Variable in class scope should not be mixedCase
"PLR0911", # Too many return statements
"PLR0913", # Too many arguments in function definition
]
select = [
"A", # flake8-builtins
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"C90", # mccabe
"E", # pycodestyle error
"ERA", # eradicate
"F", # Pyflakes
"I", # isort
"N", # pep8-naming
"PL", # Pylint
"PT", # flake8-pytest-style
"UP", # pyupgrade
]
[tool.ruff.lint.isort]
force-single-line = true
known-local-folder = [
"renault_api",
]
[tool.ruff.lint.mccabe]
max-complexity = 10
[tool.ruff.lint.pydocstyle]
convention = "google"
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"