Skip to content

feat(pyo3): support Python 3.9 (abi3-py39 + pyarrow env-marker split) - #155

Merged
vikrantpuppala merged 1 commit into
mainfrom
feat/python-39-support
Jun 11, 2026
Merged

vikrantpuppala merged 1 commit into
mainfrom
feat/python-39-support

Conversation

@vikrantpuppala

Copy link
Copy Markdown
Collaborator

What

Lowers the PyO3 wheel floor from Python 3.10 to 3.9.

The PyO3 layer is built in abi3 (stable ABI) mode, so a single wheel covers the whole supported range — dropping the floor needs no Rust changes, only the ABI/floor pins. Nothing in pyo3/src/ uses a 3.10-only API.

Changes

  • pyo3/Cargo.toml — abi3-py310 → abi3-py39 (wheel tag cp39-abi3, loads on CPython 3.9+).
  • pyo3/pyproject.toml:
    • requires-python = ">=3.10" → ">=3.9".
    • Split the pyarrow dependency by interpreter via PEP 508 environment markers. pyarrow 23.x dropped Python 3.9 wheels, so:
      • 3.10+: keeps pyarrow>=23.0.1,<24 — aligned with databricks-sql-connector 5.0.0 and required for cp314 (3.14) wheels.
      • 3.9: takes the last 3.9-capable series pyarrow>=14,<19. 3.9 never sees 3.14, so the cp314 concern doesn't apply.
    • Both ceilings preserve the go/pinning-python-deps major-version upper bound.
  • .github/workflows/pyo3-checks.yml — add "3.9" to the build+test matrix, exercising the older-pyarrow resolution path.

Validation

  • cargo build -p databricks-sql-kernel-pyo3 — clean with abi3-py39.
  • cargo clippy -p databricks-sql-kernel-pyo3 --all-targets -- -D warnings — clean.
  • pyproject.toml env markers parse correctly.

Note

databricks-sql-connector 5.0.0 itself requires 3.10+, so a 3.9 kernel wheel only matters for a downstream consumer of databricks-sql-kernel on 3.9 that isn't going through connector 5.0.0. Filing this so the option exists; happy to hold if there's no 3.9 consumer.

Lowers the PyO3 wheel floor from 3.10 to 3.9. The abi3 stable-ABI
build means a single artifact covers the whole supported range, so
no Rust changes were needed — only the ABI/floor pins.

- Cargo.toml: abi3-py310 -> abi3-py39 (wheel tag cp39-abi3).
- pyproject.toml: requires-python >=3.9, and split the pyarrow
  dependency by interpreter via PEP 508 env markers. pyarrow 23.x
  dropped 3.9 wheels, so 3.9 takes the last 3.9-capable series
  (>=14,<19) while 3.10+ keeps the connector-5.0.0-aligned >=23.0.1
  floor (needed for cp314 wheels). Both ceilings preserve the
  go/pinning-python-deps major-version upper bound.
- pyo3-checks.yml: add 3.9 to the CI matrix, exercising the older
  pyarrow path.

Signed-off-by: Vikrant Puppala <vikrant.puppala@databricks.com>
@vikrantpuppala
vikrantpuppala added this pull request to the merge queue Jun 11, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jun 11, 2026
@vikrantpuppala
vikrantpuppala added this pull request to the merge queue Jun 11, 2026
Merged via the queue into main with commit e22b159 Jun 11, 2026
20 checks passed

This branch was previously deployed

1 inactive deployment
azure-prod — 82dcce33 Deployed Jun 11, 2026 by vikrantpuppala via PyO3 build + test (Python 3.12) #132
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants