-
Notifications
You must be signed in to change notification settings - Fork 28
Expand file tree
/
Copy pathpyproject.toml
More file actions
186 lines (162 loc) · 3.67 KB
/
pyproject.toml
File metadata and controls
186 lines (162 loc) · 3.67 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
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
182
183
184
185
186
# Copyright 2021 Canonical Ltd.
# See LICENSE file for licensing details.
[tool.poetry]
package-mode = false
requires-poetry = ">=2.0.0"
[tool.poetry.dependencies]
python = "^3.12"
ops = "^2.23.1"
boto3 = "^1.40.31"
pgconnstr = "^1.0.1"
requests = "^2.32.5"
tenacity = "^9.1.2"
psycopg2 = "^2.9.10"
pydantic = "^2.11.4"
jinja2 = "^3.1.6"
pysyncobj = "^0.3.14"
psutil = "^7.0.0"
charm-refresh = "^3.1.0.2"
httpx = "^0.28.1"
postgresql-charms-single-kernel = "16.0.1"
[tool.poetry.group.charm-libs.dependencies]
# data_platform_libs/v0/data_interfaces.py
ops = ">=2.0.0"
# data_platform_libs/v0/data_models.py
pydantic = "*"
# grafana_agent/v0/cos_agent.py
cosl = ">=0.0.50"
# tls_certificates_interface/v2/tls_certificates.py
cryptography = "*"
# certificate_transfer_interface/v0/certificate_transfer.py
# tls_certificates_interface/v2/tls_certificates.py
jsonschema = "*"
# tempo_coordinator_k8s/v0/charm_tracing.py
opentelemetry-exporter-otlp-proto-http = "1.21.0"
[tool.poetry.group.format]
optional = true
[tool.poetry.group.format.dependencies]
ruff = "^0.13.0"
[tool.poetry.group.lint]
optional = true
[tool.poetry.group.lint.dependencies]
codespell = "^2.4.1"
pyright = "^1.1.405"
[tool.poetry.group.unit]
optional = true
[tool.poetry.group.unit.dependencies]
coverage = { extras = ["toml"], version = "^7.10.6" }
pytest = "^8.4.2"
pytest-asyncio = "*"
parameterized = "^0.9.0"
jsonschema = "^4.25.1"
tomli-w = "^1.2.0"
[tool.poetry.group.integration]
optional = true
[tool.poetry.group.integration.dependencies]
pytest = "^8.4.2"
pytest-operator = "^0.43.1"
# renovate caret doesn't work: https://github.com/renovatebot/renovate/issues/26940
juju = "<=3.6.1.3"
jubilant = "^1.4.0"
boto3 = "*"
tenacity = "*"
landscape-api-py3 = "^0.9.0"
mailmanclient = "^3.3.5"
psycopg2-binary = "^2.9.10"
allure-pytest = "^2.15.0"
allure-pytest-default-results = "^0.1.3"
tomli = "^2.2.1"
tomli-w = "^1.2.0"
[tool.poetry.group.build-refresh-version]
optional = true
[tool.poetry.group.build-refresh-version.dependencies]
charm-refresh-build-version = "^0.4.0"
# Testing tools configuration
[tool.coverage.run]
branch = true
[tool.coverage.report]
show_missing = true
exclude_lines = ["logger\\.debug"]
[tool.pytest.ini_options]
minversion = "6.0"
log_cli_level = "INFO"
asyncio_mode = "auto"
markers = ["juju3", "juju_secrets"]
# Formatting tools configuration
[tool.black]
line-length = 99
target-version = ["py38"]
# Linting tools configuration
[tool.ruff]
# preview and explicit preview are enabled for CPY001
preview = true
target-version = "py312"
src = ["src", "."]
line-length = 99
[tool.ruff.lint]
explicit-preview-rules = true
select = [
"A",
"E",
"W",
"F",
"C",
"N",
"D",
"I001",
"B",
"CPY",
"RUF",
"S",
"SIM",
"UP",
"TC",
]
extend-ignore = [
"D203",
"D204",
"D213",
"D215",
"D400",
"D404",
"D406",
"D407",
"D408",
"D409",
"D413",
"B904",
]
# Ignore E501 because using black creates errors with this
# Ignore D107 Missing docstring in __init__
ignore = ["E501", "D107"]
[tool.ruff.lint.per-file-ignores]
"tests/*" = [
"D100",
"D101",
"D102",
"D103",
"D104",
# Asserts
"B011",
# Disable security checks for tests
"S",
]
[tool.ruff.lint.flake8-copyright]
# Check for properly formatted copyright header in each file
author = "Canonical Ltd."
notice-rgx = "Copyright\\s\\d{4}([-,]\\d{4})*\\s+"
min-file-size = 1
[tool.ruff.lint.mccabe]
max-complexity = 10
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.pyright]
include = ["src", "scripts"]
extraPaths = ["./lib"]
pythonVersion = "3.12"
pythonPlatform = "All"
typeCheckingMode = "basic"
reportIncompatibleMethodOverride = false
reportImportCycles = false
reportMissingModuleSource = true
stubPath = ""