Skip to content

Refresh lint/format tooling#45

Merged
snopoke merged 1 commit intomainfrom
sk/refresh-tooling
May 5, 2026
Merged

Refresh lint/format tooling#45
snopoke merged 1 commit intomainfrom
sk/refresh-tooling

Conversation

@snopoke
Copy link
Copy Markdown
Collaborator

@snopoke snopoke commented May 5, 2026

Summary

  • Bump ruff-pre-commit v0.2.1 → v0.15.12 and pre-commit-hooks v4.4.0 → v6.0.0 (both 2+ years stale)
  • Update ruff hook id from ruff (legacy alias) to ruff-check per the newer ruff-pre-commit naming
  • Apply lint findings the bumped ruff surfaces:
    • PT001: drop () from @pytest.fixture decorators (8 occurrences across tests/)
    • UP031: percent-format → f-string in taskbadger/utils.py:8
    • PT030: add match=... to a pytest.warns(DeprecationWarning) in test_project_key.py
    • UP007: Optional[X]X | None in hand-written code (cli_main.py, cli/utils.py, mug.py)
    • UP038: isinstance(x, (A, B))isinstance(x, A | B) in celery.py
    • UP035: drop now-unused typing.Union import in mug.py
  • Ignore UP* and F* rules in taskbadger/internal/ (generated by openapi-python-client; ~200 findings there are out of our hands)
  • Drop black and isort from the dev dependency group — ruff and ruff-format (already in pre-commit) cover both

The Optional[X] and isinstance findings only appeared after #44 merged (which bumped ruff target-version to py310); they're rolled into this PR since the rebase needed them anyway.

Test plan

  • `uv sync` resolves cleanly
  • `uv run pytest -v` — 104 pass
  • `uv run ruff check .` — all checks pass
  • `pre-commit run --all-files` — all hooks pass

🤖 Generated with Claude Code

- Bump pre-commit hooks: ruff-pre-commit v0.2.1 -> v0.15.12, pre-commit-hooks v4.4.0 -> v6.0.0 (both 2+ years stale)
- Update ruff hook id from `ruff` (legacy alias) to `ruff-check` per the newer ruff-pre-commit naming
- Apply lint findings the bumped ruff surfaces: PT001 (drop () from @pytest.fixture decorators), UP031 (percent-format -> f-string in utils.py), PT030 (add `match` to pytest.warns(DeprecationWarning))
- Drop black and isort from the dev dependency group; ruff and ruff-format already cover both

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@snopoke snopoke force-pushed the sk/refresh-tooling branch from f1791e0 to bad3a07 Compare May 5, 2026 15:19
@snopoke snopoke merged commit 64cdc84 into main May 5, 2026
6 checks passed
@snopoke snopoke deleted the sk/refresh-tooling branch May 5, 2026 15:21
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