forked from fl4p/batmon-ha
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
181 lines (150 loc) · 3 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
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
[tool.poetry]
name = "batmon-ha"
version = "0.0.61"
description = "Monitor and control various battery management systems over Bluetooth"
authors = ["Fabian <[email protected]>", "Will Rouesnel <[email protected]>"]
readme = "README.md"
packages = [
{ include = "batmon", from = "." },
]
[tool.poetry.scripts]
batmon = "batmon.main:cli"
[tool.poetry.dependencies]
python = "^3.9"
paho-mqtt = "^1.6.1"
backoff = "^2.2.1"
bleak = {git = "https://github.com/jpeters-ml/bleak", rev = "feature/windowsPairing"}
[tool.poetry.group.dev.dependencies]
black = "^23.3.0"
mypy = "^1.3.0"
flake8 = "^6.0.0"
pytest = "^7.3.1"
isort = "^5.12.0"
pytest-cov = "^4.1.0"
flake8-pyproject = "^1.2.3"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.black]
line-length = 100
target-version = ['py310']
include = '\.pyi?$'
exclude = '''
(
/(
\.eggs # exclude a few common directories in the
| \.git # root of the project
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| venv
| venv\..*
| _build
| buck-out
| build
| dist
| setup\.py
| \.ipynb
| migrations
)/
)
'''
[tool.isort]
profile = "black"
filter_files = true
py_version = 310
skip_gitignore = true
skip_glob = [ "*.ipynb" ]
[tool.flake8]
exclude = [
'.vscode',
'.idea',
'.git',
'__pycache__',
'old',
'build',
'dist',
'venv',
'.venv',
'stubs',
'venv.*',
'migrations'
]
max-line-length = 160
ignore = [
'W503',
'E722',
'F403',
'E501',
'E231',
'C812',
'C819',
'E203',
'SC200',
'U101',
'R504',
'VNE001',
'D415',
'D202',
'D105',
'W291',
'W293',
'F401'
]
[tool.mypy]
exclude = '''
(
/(
\.eggs # exclude a few common directories in the
| \.git # root of the project
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| venv
| venv\..*
| _build
| buck-out
| build
| dist
| setup\.py
| \.ipynb
| migrations
)/
)
'''
mypy_path = "stubs"
python_version = "3.10"
namespace_packages = true
disallow_any_unimported = false
disallow_any_expr = false
# Can't practically disable yet.
disallow_any_decorated = false
# Can't practically disable Any yet.
disallow_any_explicit = false
# Also can't practically disable Any in generics.
disallow_any_generics = false
# This winds up not being practical at the moment
disallow_subclassing_any = false
disallow_untyped_calls = false
disallow_untyped_defs = true
disallow_incomplete_defs = true
check_untyped_defs = true
# Need to allow for click at this time
disallow_untyped_decorators = false
no_implicit_optional = true
strict_optional = true
warn_redundant_casts = true
warn_unused_ignores = true
warn_no_return = true
warn_return_any = true
warn_unreachable = true
ignore_errors = false
allow_untyped_globals = false
allow_redefinition = false
implicit_reexport = true
strict_equality = true
# Important!
show_absolute_path = true
warn_unused_configs = true