Skip to content

Conversation

@reimerix
Copy link
Contributor

Summary

This PR modernizes the project's build system and development tooling infrastructure to use contemporary Python best practices.

Changes

Build System Modernization

  • ✅ Replace setup.py/setup.cfg with modern pyproject.toml (PEP 517/518)
  • ✅ Switch to hatchling build backend with hatch-vcs for git-based versioning
  • ✅ Update Python requirement to >=3.9 (from 3.7)
  • ✅ Upgrade pandas requirement to >=2.0 (from >=1.0)

Developer Tooling

  • ✅ Replace black with ruff for both linting and formatting
  • ✅ Add uv for fast, reliable dependency management (10-100x faster than pip)
  • ✅ Consolidate all tool configurations into pyproject.toml
  • ✅ Remove deprecated numpy.typing.mypy_plugin
  • ✅ Configure sensible ruff rules with per-file ignores

CI/CD Updates

  • ✅ Update GitHub Actions to use astral-sh/setup-uv@v4
  • ✅ Add Python 3.9-3.12 test matrix (previously only 3.7)
  • ✅ Replace tox with direct uv/pytest/ruff/mypy commands
  • ✅ Update to latest action versions (checkout@v4, setup-python@v5)

Code Quality Improvements

  • ✅ Apply ruff import sorting across codebase
  • ✅ Modernize type annotations (use built-in list, tuple instead of List, Tuple)
  • ✅ Fix all linting issues while preserving mathematical variable conventions

Documentation

  • ✅ Update README with uv installation and development workflow
  • ✅ Modernize PyPI publishing instructions to use uv build/uv publish
  • ✅ Add clear development setup section

Testing

All quality checks pass:

  • ruff check . - All checks passed
  • ruff format --check . - All files properly formatted
  • mypy gnss/ tests/ - No type errors
  • pytest -v - All 61 tests passing

Benefits

  • Faster: uv is 10-100x faster than pip for dependency resolution
  • Modern: PEP 517/518 compliant, declarative configuration
  • Simpler: Single tool (ruff) replaces multiple linters/formatters
  • Better DX: Clearer development workflow, faster CI/CD

Files Changed

  • Added: pyproject.toml
  • Removed: setup.py, setup.cfg, tox.ini, mypy.ini
  • Updated: .github/workflows/ci.yaml, README.md, code formatting

🤖 Generated with Claude Code

This commit modernizes the project's build system and tooling infrastructure:

## Build System
- Replace setup.py/setup.cfg with modern pyproject.toml
- Switch to hatchling build backend with hatch-vcs for versioning
- Update Python requirement to >=3.9 (from 3.7)
- Upgrade pandas requirement to >=2.0 (from >=1.0)

## Tooling
- Replace black with ruff for both linting and formatting
- Consolidate all tool configurations into pyproject.toml
- Remove deprecated numpy.typing.mypy_plugin
- Add uv for fast, reliable dependency management

## CI/CD
- Update GitHub Actions to use astral-sh/setup-uv@v4
- Add Python 3.9-3.12 test matrix (previously only 3.7)
- Replace tox with direct uv/pytest/ruff/mypy commands
- Update to latest action versions (checkout@v4, setup-python@v5)

## Code Quality
- Apply ruff import sorting and type annotation modernization
- Update typing imports to use built-in generics (list, tuple vs List, Tuple)
- Configure per-file ignores for public API and test conventions
- All tests pass, all quality checks green

## Documentation
- Update README with uv installation and development workflow
- Modernize PyPI publishing instructions to use uv build/publish

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@swift-nav swift-nav deleted a comment from sonarqubecloud bot Dec 22, 2025
Copy link

@martin4861 martin4861 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
- uses: actions/checkout@v4

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are already newer versions available. No need to fix this now, but consider to setup dependabot for GH Actions.

Configure Dependabot to automatically keep dependencies up to date:

- GitHub Actions: Weekly updates on Mondays
- Python dependencies: Weekly updates with patch grouping
- Proper labeling for easy triage (dependencies, github-actions, python)
- Conventional commit messages (ci: for actions, deps: for Python)

This ensures the repository stays secure and up-to-date with minimal
manual intervention.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@reimerix reimerix merged commit 636f829 into master Dec 22, 2025
5 checks passed
@reimerix reimerix deleted the modernize-tooling-uv-ruff branch December 22, 2025 13:15
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.

3 participants