Skip to content

Modernize packaging and CI with pyproject.toml and uv#159

Open
izkgao wants to merge 8 commits intodevfrom
zhenkai/migrate_to_uv
Open

Modernize packaging and CI with pyproject.toml and uv#159
izkgao wants to merge 8 commits intodevfrom
zhenkai/migrate_to_uv

Conversation

@izkgao
Copy link
Copy Markdown

@izkgao izkgao commented Apr 2, 2026

Closes #158.

Summary

Modernize packaging and CI around pyproject.toml and uv, move CI linting to ruff, and raise the minimum supported Python version to 3.10 while keeping the existing pip install . flow documented for users.

Changes

Packaging & dependencies

  • Replace setup.py with a PEP 621 pyproject.toml
  • Add uv.lock for reproducible dependency resolution
  • Add .python-version and set the minimum supported Python version to 3.10
  • Define dependency groups for lint, test, docs, and dev
  • Move selenium into the optional browser extra

CI workflows

  • Switch GitHub Actions jobs to astral-sh/setup-uv@v7 with locked environment syncs
  • Update style check CI from flake8 to ruff check
  • Update the unit test matrix to Python 3.10 through 3.14
  • Build docs in CI with uv sync --group docs and sphinx-build
  • Bump actions/checkout to v6

Docs & developer guidance

  • Pin docs/requirements.txt via uv export for Read the Docs
  • Add fail_on_warning: true and install the package itself in .readthedocs.yaml
  • Update README.md to keep the existing pip/pytest workflow and add uv as an alternative contributor setup
  • Update the quickstart docs to call out the Python 3.10+ requirement and the optional browser extra

Compatibility notes

  • End-user installation remains pip install .
  • Existing style helper scripts remain available for developers who already use them
  • The main user-visible compatibility change in this PR is the minimum supported Python version becoming 3.10

How to test

uv sync
uv run pytest -v tests/
uv run ruff check
uv run sphinx-build -W -b html docs/source docs/build/html

@izkgao izkgao changed the title Migrate build toolchain from setup.py/pip/flake8 to pyproject.toml/uv/ruff Modernize packaging and CI with pyproject.toml and uv Apr 9, 2026
@izkgao izkgao marked this pull request as ready for review April 9, 2026 07:50
@izkgao izkgao requested review from confluence and kswang1029 April 9, 2026 07:51
@izkgao izkgao added awaiting code review For pull requests that require code review awaiting testing For pull requests that require testing labels Apr 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting code review For pull requests that require code review awaiting testing For pull requests that require testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Migrate development toolchain from setup.py/pip/flake8 to pyproject.toml/uv/ruff

2 participants