forked from mongodb/mongo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
274 lines (248 loc) · 7.68 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
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
[tool.poetry]
name = "mdb-python-deps"
version = "1.0.0"
description = "MongoDB python dependencies"
authors = ["MongoDB"]
readme = "README.md"
# These packages are included as a TODO if we want to run resmoke with pex
# Currently this does nothing
packages = [
{ include = "buildscripts/resmoke.py" },
{ include = "buildscripts/mongosymb.py" },
{ include = "buildscripts/build_system_options.py" },
{ include = "buildscripts/resmokelib" },
{ include = "buildscripts/idl" },
{ include = "buildscripts/util" },
]
[tool.poetry.dependencies]
python = ">=3.10,<4.0"
# OPTIONAL
# Libdeps depdencies
networkx = "*" # This is also used as a part of build_metrics so it is sort of required
flask = { version = "*", optional = true }
flask-cors = { version = "*", optional = true }
lxml = { version = "*", optional = true }
eventlet = { version = "*", optional = true }
gevent = { version = "*", optional = true }
progressbar2 = { version = "*", optional = true }
cxxfilt = { version = "*", optional = true }
pympler = { version = "*", optional = true }
pyright = "1.1.382"
[tool.poetry.group.aws.dependencies]
boto3 = "^1.34.156"
botocore = "^1.34.156"
[tool.poetry.group.build-metrics.dependencies]
jsonschema = "^4.23.0"
psutil = "^6.0.0"
memory-profiler = "^0.61.0"
puremagic = "^1.26"
tabulate = "^0.9.0"
[tool.poetry.group.compile.dependencies]
cheetah3 = "<=3.2.6.post1" # src/mongo/base/generate_error_codes.py
packaging = "^23.1"
regex = "^2021.11.10"
setuptools = "^58.1.0"
wheel = "0.37.0"
[tool.poetry.group.core.dependencies]
psutil = "^6.0.0"
pymongo = "4.3.3"
PyYAML = "5.3.1"
types-PyYAML = "^6.0.12.20240808"
requests = "^2.32.3"
typing-extensions = "^4.12.2"
typer = "^0.12.3"
tenacity = "^9.0.0"
[tool.poetry.group.export.dependencies]
pipx = "1.6.0"
# TODO: Add in pex as we move forward with this
# pex = "^2.1.137"
poetry = "1.8.3"
[tool.poetry.group.evergreen.dependencies]
click = "^8.1.7"
inject = "^5.2.1"
GitPython = "^3.1.43"
pydantic = "*"
structlog = "^24.4.0"
[tool.poetry.group.external-auth.dependencies]
# These are the dependencies of ldaptor
passlib = "^1.7.4"
pyOpenSSL = [
{ version = "19.0.0", markers = "platform_machine == 's390x' or platform_machine == 'ppc64le'" }, # Needed for pinned cryptography package - see SERVER-70845
{ version = "22.0.0", markers = "platform_machine != 's390x' and platform_machine != 'ppc64le'" },
]
pyparsing = "^2.4.7"
service_identity = "^18.1.0"
twisted = "^24.3.0"
'zope.interface' = "^5.5.2"
ldaptor = "19.0.0"
[tool.poetry.group.idl.dependencies]
unittest-xml-reporting = "3.0.4" # Pinned because newer versions require lxml which fails to install
packaging = "^23.1"
[tool.poetry.group.jira-client.dependencies]
jira = "<=3.1.1"
requests-oauth = "<=0.4.1"
PyJWT = "^2.9.0"
# We are omitting pycrypto based on https://github.com/pycontribs/jira/pull/629
[tool.poetry.group.lint.dependencies]
# Note: These versions are checked by python modules in buildscripts/linter/
GitPython = "^3.1.7"
mypy = "^1.11.1"
structlog = "^24.4.0"
yamllint = "^1.35.1"
types-setuptools = "57.4.12" # latest is 68.0.0.0, but that causes pip install requirements to fail
types-requests = "^2.32.0.20240712"
tqdm = "*"
colorama = "^0.4.6"
evergreen-lint = "^0.1.9"
ruff = "^0.5.6"
[tool.poetry.group.platform.dependencies]
pypiwin32 = { version = ">=223", markers = "sys_platform == 'win32'" }
pywin32 = { version = ">=225", markers = "sys_platform == 'win32'" }
cryptography = [
{ version = "2.3", markers = "platform_machine == 's390x' or platform_machine == 'ppc64le'" }, # Needed for oauthlib to use RSAAlgorithm # Version locked - see SERVER-36618
{ version = "36.0.2", markers = "platform_machine != 's390x' and platform_machine != 'ppc64le'" },
]
mongo-ninja-python = [
{ version = "1.11.1.7", markers = "platform_machine != 's390x' and platform_machine != 'ppc64le'" },
]
ninja = [
{ version = ">=1.10.0", markers = "platform_machine == 's390x' or platform_machine == 'ppc64le'" },
]
[tool.poetry.group.testing.dependencies]
curatorbin = "^1.2.4"
PyKMIP = "0.10.0"
evergreen-py = "^3.9.0"
jinja2 = "^3.1.4"
mock = "^5.1.0"
shrub-py = "^3.1.4"
ocspresponder = "^0.5.0"
flask = "^2.3.3"
ocspbuilder = "^0.10.2"
# Werkzeug is needed for ocsp tests in ocsp_mock.py
# version 3+ fails with "ImportError: cannot import name 'url_quote' from 'werkzeug.urls'"
Werkzeug = "<=2.3.7"
PyGithub = "^1.58"
urllib3 = "^2.2.2"
distro = "^1.9.0"
dnspython = "^2.6.1"
proxy-protocol = "^0.11.3"
pkce = "^1.0.3"
oauthlib = "^3.1.1"
requests-oauthlib = "^2.0.0"
packaging = "^23.1"
docker = "^7.1.0"
mongomock = "^4.1.2"
pyjwt = "^2.9.0"
selenium = "^4.23.1"
geckodriver-autoinstaller = "^0.1.0"
retry = "^0.9.2"
gdbmongo = "^0.15.0"
googleapis-common-protos = "^1.63.2"
gcovr = "7.2"
opentelemetry-api = "*"
opentelemetry-sdk = "*"
opentelemetry-exporter-otlp-proto-common = "*"
[tool.poetry.group.tooling-metrics.dependencies]
mongo-tooling-metrics = "1.0.8"
# This can be installed with "poetry install -E libdeps"
[tool.poetry.extras]
libdeps = [
"flask",
"flask-cors",
"lxml",
"eventlet",
"gevent",
"progressbar2",
"cxxfilt",
"pympler",
]
# This entrypoint is included as a TODO if we want to run resmoke with pex
# Currently this does nothing
[tool.poetry.scripts]
resmoke = "buildscripts.resmoke:entrypoint"
[tool.ruff]
extend-exclude = [
"site_scons/third_party",
"src/third_party",
]
extend-include = [
"SConstruct",
"*/SConscript"
]
line-length = 100
target-version = "py310"
[tool.ruff.lint]
extend-select = [
"I", # isort
]
ignore = [
"E402", # module-import-not-at-top-of-file
"E721", # type-comparison
"E722", # bare-except
"E741", # ambiguous-variable-name
"F402", # import-shadowed-by-loop-var
"F403", # undefined-local-with-import-star
"F405", # undefined-local-with-import-star-usage
"F811", # redefined-while-unused
"F821", # undefined-name
"F822", # undefined-export
]
[tool.pyright]
include = [
"buildscripts",
"src"
]
exclude = [
"**/third_party/**",
"**/external/**"
]
pythonVersion = "3.10"
# These should be set to "error" for basic functionality
reportInvalidTypeForm = "none"
reportMissingImports = "none"
reportUndefinedVariable = "none"
reportAbstractUsage = "none"
reportAssertTypeFailure = "none"
reportInconsistentOverload = "none"
reportInvalidTypeArguments = "none"
reportNoOverloadImplementation = "none"
reportOptionalCall = "none"
reportOptionalContextManager = "none"
reportRedeclaration = "none"
reportUnboundVariable = "none"
reportUnhashable = "none"
reportUnusedCoroutine = "none"
reportUnusedExcept = "none"
# These should be set to "warning" or "error" for standard checks
reportArgumentType = "none"
reportAssignmentType = "none"
reportAttributeAccessIssue = "none"
reportCallIssue = "none"
reportGeneralTypeIssues = "none"
reportIndexIssue = "none"
reportOperatorIssue = "none"
reportOptionalSubscript = "none"
reportOptionalMemberAccess = "none"
reportOptionalIterable = "none"
reportOptionalOperand = "none"
reportReturnType = "none"
reportTypedDictNotRequiredAccess = "none"
reportPrivateImportUsage = "none"
reportFunctionMemberAccess = "none"
reportIncompatibleMethodOverride = "none"
reportIncompatibleVariableOverride = "none"
reportOverlappingOverload = "none"
reportPossiblyUnboundVariable = "none"
# These are additional checks for strict mode
reportMissingTypeStubs = "none"
reportAssertAlwaysTrue = "none"
reportInvalidStringEscapeSequence = "none"
reportInvalidTypeVarUse = "none"
reportSelfClsParameterName = "none"
reportUnsupportedDunderAll = "none"
reportUnusedExpression = "none"
reportWildcardImportFromLibrary = "none"
reportConstantRedefinition = "none"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"