forked from mlflow/mlflow
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
319 lines (294 loc) · 9.19 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
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
[build-system]
requires = ["setuptools"]
build-backend = "setuptools.build_meta"
[project]
name = "mlflow"
version = "2.19.1.dev0"
description = "MLflow is an open source platform for the complete machine learning lifecycle"
readme = "README.md"
keywords = ["mlflow", "ai", "databricks"]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: End Users/Desktop",
"Intended Audience :: Science/Research",
"Intended Audience :: Information Technology",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Software Development :: Libraries :: Python Modules",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3.9",
]
requires-python = ">=3.9"
dependencies = [
"Flask<4",
"Jinja2<4,>=2.11; platform_system != 'Windows'",
"Jinja2<4,>=3.0; platform_system == 'Windows'",
"alembic<2,!=1.10.0",
"cachetools<6,>=5.0.0",
"click<9,>=7.0",
"cloudpickle<4",
"databricks-sdk<1,>=0.20.0",
"docker<8,>=4.0.0",
"gitpython<4,>=3.1.9",
"graphene<4",
"gunicorn<24; platform_system != 'Windows'",
"importlib_metadata<9,>=3.7.0,!=4.7.0",
"markdown<4,>=3.3",
"matplotlib<4",
"numpy<3",
"opentelemetry-api<3,>=1.9.0",
"opentelemetry-sdk<3,>=1.9.0",
"packaging<25",
"pandas<3",
"protobuf<6,>=3.12.0",
"pyarrow<19,>=4.0.0",
"pydantic<3,>=1.0",
"pyyaml<7,>=5.1",
"requests<3,>=2.17.3",
"scikit-learn<2",
"scipy<2",
"sqlalchemy<3,>=1.4.0",
"sqlparse<1,>=0.4.0",
"typing-extensions<5,>=4.0.0",
"waitress<4; platform_system == 'Windows'",
]
[[project.maintainers]]
name = "Databricks"
email = "[email protected]"
[project.license]
file = "LICENSE.txt"
[project.optional-dependencies]
extras = [
"pyarrow",
"requests-auth-aws-sigv4",
"boto3",
"botocore",
"google-cloud-storage>=1.30.0",
"azureml-core>=1.2.0",
"pysftp",
"kubernetes",
"virtualenv",
"prometheus-flask-exporter",
]
databricks = [
"azure-storage-file-datalake>12",
"google-cloud-storage>=1.30.0",
"boto3>1",
"botocore",
]
mlserver = ["mlserver>=1.2.0,!=1.3.1", "mlserver-mlflow>=1.2.0,!=1.3.1"]
gateway = [
"fastapi<1",
"uvicorn[standard]<1",
"watchfiles<2",
"aiohttp<4",
"boto3<2,>=1.28.56",
"tiktoken<1",
"slowapi<1,>=0.1.9",
]
genai = [
"fastapi<1",
"uvicorn[standard]<1",
"watchfiles<2",
"aiohttp<4",
"boto3<2,>=1.28.56",
"tiktoken<1",
"slowapi<1,>=0.1.9",
]
sqlserver = ["mlflow-dbstore"]
aliyun-oss = ["aliyunstoreplugin"]
xethub = ["mlflow-xethub"]
jfrog = ["mlflow-jfrog-plugin"]
langchain = ["langchain>=0.1.0,<=0.3.10"]
[project.urls]
homepage = "https://mlflow.org"
issues = "https://github.com/mlflow/mlflow/issues"
documentation = "https://mlflow.org/docs/latest/index.html"
repository = "https://github.com/mlflow/mlflow"
[project.scripts]
mlflow = "mlflow.cli:cli"
[project.entry-points."mlflow.app"]
basic-auth = "mlflow.server.auth:create_app"
[project.entry-points."mlflow.app.client"]
basic-auth = "mlflow.server.auth.client:AuthServiceClient"
[project.entry-points."mlflow.deployments"]
databricks = "mlflow.deployments.databricks"
http = "mlflow.deployments.mlflow"
https = "mlflow.deployments.mlflow"
openai = "mlflow.deployments.openai"
[tool.setuptools.package-data]
mlflow = [
"store/db_migrations/alembic.ini",
"temporary_db_migrations_for_pre_1_users/alembic.ini",
"pypi_package_index.json",
"pyspark/ml/log_model_allowlist.txt",
"server/auth/basic_auth.ini",
"server/auth/db/migrations/alembic.ini",
"recipes/resources/**/*",
"recipes/cards/templates/**/*",
"models/resources/**/*",
"models/container/**/*",
"server/js/build/**/*",
]
[tool.setuptools.packages.find]
where = ["."]
include = ["mlflow", "mlflow.*"]
exclude = ["tests", "tests.*"]
# Package metadata: can't be updated manually, use dev/pyproject.py
# -----------------------------------------------------------------
# Dev tool settings: can be updated manually
[tool.ruff]
line-length = 100
target-version = "py39"
required-version = "0.7.4"
force-exclude = true
extend-include = ["*.ipynb"]
extend-exclude = [
"examples/llama_index/workflow",
"examples/recipes",
"mlflow/protos",
"mlflow/ml_package_versions.py",
"mlflow/server/graphql/autogenerated_graphql_schema.py",
"mlflow/server/js",
"mlflow/store/db_migrations",
"tests/protos",
]
[tool.ruff.format]
docstring-code-format = true
docstring-code-line-length = 88
[tool.ruff.lint]
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
select = [
"B006", # multiple-argument-default
"B015", # useless-comparison
"D209", # new-line-after-last-paragraph
"D411", # no-blank-line-before-section
"D417", # undocumented-param
"E", # error
"F", # Pyflakes
"C4", # flake8-comprehensions
"I", # isort
"ISC001", # single-line-implicit-string-concatenation
"PIE790", # unnecessary-placeholder
"PLR0402", # manual-from-import
"PLE1205", # logging-too-many-args
"PLW0602", # global-variable-not-assigned
"PT001", # pytest-fixture-incorrect-parentheses-style
"PT002", # pytest-fixture-positional-args
"PT003", # pytest-extraneous-scope-function
"PT006", # pytest-parameterize-names-wrong-type
"PT007", # pytest-parameterize-values-wrong-type
"PT009", # pytest-unittest-assertion
"PT010", # pytest-raises-without-exception
"PT011", # pytest-raises-too-broad
"PT012", # pytest-raises-with-multiple-statements
"PT013", # pytest-incorrect-pytest-import
"PT014", # pytest-duplicate-parametrize-test-cases
"PT018", # pytest-composite-assertion
"PT022", # pytest-useless-yield-fixture
"PT023", # pytest-incorrect-mark-parentheses-style
"PT026", # pytest-use-fixtures-without-parameters
"PT027", # pytest-unittest-raises-assertion
"RET504", # unnecessary-assign
"RUF010", # explicit-f-string-type-conversion
"RUF013", # implicit-optional
"RUF100", # unused-noqa
"S307", # suspicious-eval-usage
"S324", # hashlib-insecure-hash-function
"SIM101", # duplicate-isinstance-call
"SIM108", # if-else-block-instead-of-if-exp
"SIM114", # if-with-same-arms
"SIM115", # open-file-with-context-handler
"SIM210", # if-expr-with-true-false
"SIM910", # dict-get-with-none-default
"T20", # flake8-print
"TID251", # banned-api
"TID252", # relative-improt
"TRY203", # useless-try-except
"UP004", # useless-object-inheritance
"UP006", # non-pep585-annotation
"UP008", # super-call-with-parameters
"UP011", # lru-cache-without-parameters
"UP012", # unecessary-encode-utf8
"UP015", # redundant-open-modes
"UP030", # format-literals
"UP031", # printf-string-format
"UP034", # extraneous-parenthesis
"W", # warning
]
ignore = [
"E402", # module-import-not-at-top-of-file
"E721", # type-comparison
"E741", # ambiguous-variable-name
"F811", # redefined-while-unused
]
[tool.ruff.lint.per-file-ignores]
"dev/*" = ["T201", "PT018"]
"examples/*" = ["T20", "RET504", "E501"]
"docs/*" = ["T20", "RET504", "E501"]
"mlflow/*" = ["PT018"]
[tool.ruff.lint.flake8-pytest-style]
mark-parentheses = false
fixture-parentheses = false
raises-require-match-for = ["*"]
[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "all"
[tool.ruff.lint.isort]
forced-separate = ["tests"]
[tool.ruff.lint.flake8-tidy-imports.banned-api]
"pkg_resources".msg = "Do not use pkg_resources. Use importlib.resources or importlib.metadata instead."
"entrypoints".msg = "Do not use entrypoints. Use importlib.metadata.entry_points instead."
"pip".msg = "Importing pip can cause undesired side effects such as https://github.com/scikit-learn/scikit-learn/issues/26992. Consider using `subprocess.run([sys.executable, '-m', 'pip', ...])` instead."
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.clint]
exclude = [
"mlflow/protos",
"mlflow/ml_package_versions.py",
"mlflow/server/js",
"mlflow/store/db_migrations",
"tests/protos",
]
typing-extensions-allowlist = [
# Docs: https://typing-extensions.readthedocs.io/en/latest/
"typing_extensions.Self", # Added in 4.0.0
]
[tool.clint.forbidden-top-level-imports]
"mlflow/gateway/providers/*" = ["fastapi", "starlette"]
# typos
[tool.typos.default.extend-words]
als = "als" # alternating least squares
mape = "mape" # mean absolute percentage error
fpr = "fpr" # false positive rate
gam = "gam" # generalized additive models
ser = "ser" # serialization
yhat = "yhat" # ŷ
# https://github.com/crate-ci/typos/blob/master/docs/reference.md
[tool.typos.files]
extend-exclude = [
# Ignore proto files
"mlflow/protos/**/*",
# Vendored files
"mlflow/utils/gorilla.py",
]
[tool.typos.default]
extend-ignore-re = [
# Line ignore with trailing `# spellchecker: disable-line`
"(?Rm)^.*#\\s*spellchecker: disable-line$",
# Line block with `# spellchecker: <on|off>`
"(?s)(#|//)\\s*spellchecker: off.*?\\n\\s*(#|//)\\s*spellchecker: on",
# numpy.arange
"(?i)(numpy|np)\\.arange",
# nd array
"(?i)nd( |_|\\.)?array",
"aNothEr",
# German words/sentences used for testing
"MLflow ist",
"Ich habe eine schöne Haufe von Kokos",
"Ich bin das Modell eines modernen General",
# pytorch-lightning
"lightning",
# `typos` flags 'lok' as a typo of 'look'
"(?i)daniel lok",
]