Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,9 @@ jobs:
- name: Python Lint - PyRight
env:
MATURIN_PEP517_ARGS: "--profile dev"
run: uv run basedpyright vortex-python
run: |
uv sync --all-packages
uv run basedpyright vortex-python

python-test:
name: "Python (test)"
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -238,3 +238,6 @@ sweep.timestamp
# Perfetto
trace*.json
trace*.pb

# pytest-benchmark output
vortex-python/.benchmarks/
15 changes: 2 additions & 13 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,28 +14,17 @@ build-backend = "hatchling.build"
packages = ["dummy"] # Required for workspace project

[dependency-groups]
# Currently, all dev dependencies live in the root since uv doesn't have transitive dev dependencies.
# See: https://github.com/astral-sh/uv/issues/7541
# Shared dev tooling. Member-specific dev deps live in each member's pyproject.toml.
# `uv sync --all-packages` picks up dev groups from all workspace members.
dev = [
"basedpyright>=1.31",
"duckdb>=1.1.2",
"ipython>=8.26.0",
"maturin>=1.7.2",
"pandas-stubs>=2.2.3.241126",
"pandas[output-formatting]>=2.2.3",
"pcodec>=0.3.3",
"pip>=23.3.2",
"polars>=1.9.0",
"pyarrow-stubs>=17.16",
"pytest-benchmark>=4.0.0",
"pytest>=7.4.0",
"ruff>=0.7.1",
"ray>=2.48",
"pytest-benchmark>=5.1.0",
# forced transitive bumps
"urllib3>=2.6.3",
"filelock>=3.20.3",
"protobuf>=6.33.5",
]

[tool.uv]
Expand Down
35 changes: 12 additions & 23 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 10 additions & 4 deletions vortex-python/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -67,16 +67,22 @@ include = [
{ path = "python/vortex/py.typed", format = "sdist" },
]

[tool.basedpyright]
exclude = ["python/vortex/_lib/store/**.pyi"]

[dependency-groups]
dev = [
"basedpyright>=1.31",
"duckdb>=1.1.2",
"maturin>=1.7.2",
"numpy>=2.2.2",
"pandas-stubs>=2.2.3.241126",
"pandas[output-formatting]>=2.2.3",
"pcodec>=0.3.3",
"polars>=1.9.0",
"pyarrow-stubs>=17.16",
"pytest-benchmark>=5.1.0",
"pytest-xdist>=3.5.0",
"ray>=2.48",
# forced transitive bumps
"protobuf>=6.33.5",
]

[tool.basedpyright]
exclude = ["python/vortex/_lib/store/**.pyi"]
28 changes: 28 additions & 0 deletions vortex-python/run_benchmarks.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#!/bin/bash
# SPDX-License-Identifier: Apache-2.0
# SPDX-FileCopyrightText: Copyright the Vortex contributors

# Run Python benchmarks with a release-profile build of the native extension.
#
# Usage:
# ./run_benchmarks.sh # run all benchmarks
# ./run_benchmarks.sh -k "test_scan" # run benchmarks matching a pattern
# ./run_benchmarks.sh --benchmark-only # skip non-benchmark tests (if any)
#
# All arguments are forwarded to pytest.

set -ex -o pipefail

ROOT=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )/.." &> /dev/null && pwd )
PYTHON_DIR="$ROOT/vortex-python"

# Ensure all packages are synced (includes pytest-benchmark dev dependency).
uv sync --all-packages

source "$ROOT/.venv/bin/activate"

# Build the native extension in release mode so benchmarks reflect production performance.
maturin develop --release --manifest-path "$PYTHON_DIR/Cargo.toml"

# Run benchmarks. Extra args are forwarded to pytest.
pytest "$PYTHON_DIR/benchmark" "$@"
Loading