-
Notifications
You must be signed in to change notification settings - Fork 9
/
pyproject.toml
86 lines (76 loc) · 2.71 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
[project]
name = "spark-substrait-gateway"
description = "Implements a gateway that speaks the SparkConnect protocol and drives a backend using Substrait (over ADBC Flight SQL)."
authors = [{name = "Substrait contributors", email = "substrait@googlegroups.com"}]
license = {text = "Apache-2.0"}
readme = "README.md"
requires-python = ">=3.8.1"
dependencies = ["protobuf >= 3.20", "datafusion == 41.0.*", "pyarrow >= 17.0.0", "substrait == 0.21.0", "duckdb == 1.1.0"]
dynamic = ["version"]
[tool.setuptools_scm]
write_to = "src/gateway/_version.py"
[project.optional-dependencies]
gen_proto = ["protobuf == 3.20.1", "protoletariat >= 2.0.0"]
test = ["pytest >= 7.0.0"]
[tool.pytest.ini_options]
pythonpath = "src"
addopts = "--ignore=third_party"
markers = [
"spark: mark a test as running against Spark",
"gateway-over-arrow: mark a test as running against the gateway using Arrow",
"gateway-over-duckdb: mark a test as running against the gateway using DuckDB",
"gateway-over-datafusion: mark a test as running against the gateway using DataFusion",
"general: mark a test as not specific to a backend",
"sql: marks a test as having SQL as its source",
]
[build-system]
requires = ["setuptools>=61.0.0", "setuptools_scm[toml]>=6.2.0"]
build-backend = "setuptools.build_meta"
[tool.ruff]
line-length = 100
respect-gitignore = true
# should target minimum supported version
target-version = "py310"
# never autoformat upstream or generated code
exclude = ["third_party/"]
[tool.ruff.lint]
select = [
"B", # flake8-bugbear
"BLE", # flake8-blind-except
"C4", # comprehensions
"D", # pydocstyle
"E", # pycodestyle
"F", # pyflakes
"I", # isort
"ICN", # flake8-import-conventions
"ISC", # flake8-implicit-str-concat
"PGH", # pygrep-hooks
"PLC", # pylint
"PLE", # pylint
"PLW", # pylint
"RET", # flake8-return
"RUF", # ruff-specific rules
"SIM", # flake8-simplify
"T10", # flake8-debugger
"T20", # flake8-print
"TID", # flake8-tidy-imports
"UP", # pyupgrade
"W", # pycodestyle
"YTT", # flake8-2020
]
unfixable = [
"F401", # unused imports
"T201", # print statements
"E712", # truth comparison checks
]
[tool.ruff.lint.per-file-ignores]
"*test*.py" = ["D"] # ignore all docstring lints in tests
"__init__.py" = ["D"]
[tool.pylint.MASTER]
extension-pkg-allow-list = ["pyarrow.lib"]
[project.scripts]
spark-substrait-gateway-server = "gateway.server:click_serve"
spark-substrait-client-demo = "gateway.demo.client_demo:click_run_demo"
spark-substrait-create-tls-keypair = "gateway.setup.tls_utilities:click_create_tls_keypair"
spark-substrait-create-jwt = "gateway.utilities.create_jwt:main"
spark-substrait-create-client-demo-data = "gateway.demo.generate_tpch_parquet_data:click_generate_tpch_parquet_data"