Skip to content

Conversation

@webjunkie
Copy link
Contributor

Summary

CI was only running ruff format --check but never ruff check, allowing lint errors to accumulate undetected on master.

Problem

The code quality checks in CI only verified formatting:

- name: Check formatting with ruff
  run: |
      ruff format --check .

But never ran linting checks, so errors like unused imports, duplicate function names, and lambda expressions were merging undetected.

Changes

  1. Add ruff check step to CI workflow
  2. Fix all existing lint errors on master:
    • F401: Add explicit re-exports for public API types (InconclusiveMatchError as InconclusiveMatchError, etc.)
    • F811: Rename duplicate test_openai_reasoning_tokens to test_openai_reasoning_tokens_o4_mini
    • E731: Convert lambda to def function in test_middleware.py
    • Unused imports: Remove unused imports from client.py and test files (auto-fixed)

Testing

$ ruff check .
All checks passed!

Impact

Going forward, ruff check will run in CI and catch lint errors before they merge, maintaining code quality standards.

- Add 'Lint with ruff' step to CI workflow (was only running format check)
- Fix F401: Add explicit re-exports for public API types in __init__.py
- Fix F811: Rename duplicate test_openai_reasoning_tokens to test_openai_reasoning_tokens_o4_mini
- Fix E731: Convert lambda to def function in test_middleware.py
- Fix unused imports in client.py and test files (auto-fixed)

Without ruff check in CI, lint errors were accumulating on master undetected.
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

6 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

@webjunkie webjunkie requested a review from oliverb123 October 29, 2025 09:42
@webjunkie webjunkie enabled auto-merge (squash) October 29, 2025 09:42
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