Skip to content

refactor: migrate setup.py to pyproject.toml and adopt uv/ruff#62

Merged
lan496 merged 8 commits intodevelopfrom
refactor/migrate-setup-to-pyproject
Mar 31, 2026
Merged

refactor: migrate setup.py to pyproject.toml and adopt uv/ruff#62
lan496 merged 8 commits intodevelopfrom
refactor/migrate-setup-to-pyproject

Conversation

@lan496
Copy link
Copy Markdown
Owner

@lan496 lan496 commented Mar 31, 2026

Summary

  • Consolidate package configuration from setup.py, setup.cfg, and MANIFEST.in into pyproject.toml
  • Replace black, flake8, isort, and pyupgrade with ruff for linting and formatting
  • Migrate CI workflows (testing + deploy) from pip to uv
  • Bump minimum Python version to 3.10, remove typing_extensions dependency
  • Update pre-commit hooks and add pyproject-fmt, uv-lock, check-github-workflows

Test plan

  • CI passes on all Python versions (3.10, 3.11, 3.12)
  • uv sync --extra dev && uv run pytest -v tests/ passes locally
  • uv run ruff check hsnf/ tests/ reports no errors
  • Package builds correctly with uv build

[Claude Code] Generated with Claude Code

lan496 and others added 8 commits March 31, 2026 20:37
… ruff

Consolidate package configuration from setup.py, setup.cfg, and
MANIFEST.in into pyproject.toml. Replace black, flake8, isort, and
pyupgrade with ruff for linting and formatting. Bump minimum Python
version to 3.10 and remove typing_extensions dependency.

Co-Authored-By: Claude <noreply@anthropic.com>
Add stacklevel=2 to warnings.warn (B028) and rename ambiguous
variable `l` to `exp` (E741).

Co-Authored-By: Claude <noreply@anthropic.com>
Bump pre-commit hook versions, add check-toml/check-merge-conflict/
detect-private-key/uv-lock/check-github-workflows/pyproject-fmt hooks.
Reformat pyproject.toml via pyproject-fmt.

Co-Authored-By: Claude <noreply@anthropic.com>
Update test matrix to 3.10/3.11/3.12, deploy workflow to Python 3.12,
and CI branch targets to develop.

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Replace pip install with uv sync/uv build in testing and deploy
workflows. Remove pip cache step (uv handles caching natively).

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
@lan496 lan496 marked this pull request as ready for review March 31, 2026 11:46
@lan496 lan496 merged commit 2f782e3 into develop Mar 31, 2026
4 checks passed
@lan496 lan496 deleted the refactor/migrate-setup-to-pyproject branch March 31, 2026 11:46
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.

1 participant