Skip to content

Python(chore): add uv for dev#581

Merged
alexluck-sift merged 9 commits into
mainfrom
al/python/chore/uv-for-legacy-version-support
May 26, 2026
Merged

Python(chore): add uv for dev#581
alexluck-sift merged 9 commits into
mainfrom
al/python/chore/uv-for-legacy-version-support

Conversation

@alexluck-sift

@alexluck-sift alexluck-sift commented May 21, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Migrate the Python dev workflow and CI from pip install + venv/ to uv: python/scripts/dev bootstraps via uv sync --extra dev-all, every subcommand runs through uv run, and pre-push hooks (extras.sh, fmt-lint.sh, stubs.sh, lock.sh) follow suit.

  • Commit uv.lock so dev and CI share a single resolved dependency set. Fork resolution across python_version < '3.9', == '3.9.*', and >= '3.10' ([tool.uv].environments) lets each minor pick its own valid solution — 3.8 lands on numpy 1.24 + rosbags 0.9.23, 3.10+ on numpy 2.x + rosbags 0.11.2 — without the lockfile having to find a single set that fits the whole range.

  • python_ci.yaml: a static-checks job (lint/format/mypy/pyright/stubs/extras/stubtest + uv lock --check) plus a matrix test-python job that syncs from the lockfile and runs pytest under the 3.8 floor interpreter. Adds a mypy --platform=win32 pass to catch Windows-only stub breakage (e.g. fcntl).

  • Add test-floor (3.8) and test-ceiling (3.14) dev subcommands for local floor/ceiling exercises.

  • Mark optional extras with their real version floors: rosbags ; python_full_version >= '3.8.2' (rosbags 0.9.23's lower bound), and docs entries with python_version >= '3.10' so the <3.10 forks resolve without docs tooling. Base requires-python stays at >=3.8.

  • Add a mypy override for alive_progress to neutralize its overly tight alive_it stubs.

@github-actions

github-actions Bot commented May 21, 2026

Copy link
Copy Markdown
Contributor

Python docs preview: https://sift-stack.github.io/sift/python/pr-581/

Deployed from a8e6cae. The link may take up to a minute to become live as GitHub Pages propagates.

@alexluck-sift alexluck-sift marked this pull request as ready for review May 22, 2026 21:06
wei-qlu
wei-qlu previously approved these changes May 26, 2026
@alexluck-sift alexluck-sift enabled auto-merge (squash) May 26, 2026 18:26
@alexluck-sift alexluck-sift disabled auto-merge May 26, 2026 18:33
@alexluck-sift alexluck-sift requested a review from wei-qlu May 26, 2026 18:44
@alexluck-sift alexluck-sift merged commit b0da0cf into main May 26, 2026
23 checks passed
@alexluck-sift alexluck-sift deleted the al/python/chore/uv-for-legacy-version-support branch May 26, 2026 19:29
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