Skip to content

feat(ci): add Python lint job with ruff#30

Merged
kphunter merged 1 commit into
mainfrom
devin/1779684136-add-python-lint
May 25, 2026
Merged

feat(ci): add Python lint job with ruff#30
kphunter merged 1 commit into
mainfrom
devin/1779684136-add-python-lint

Conversation

@devin-ai-integration

Copy link
Copy Markdown
Contributor

Summary

Adds an unconditional lint job to CI that runs ruff check and ruff format --check on every PR and push. This matches hriv's pattern where quality-gate jobs (backend-tests, frontend-checks) always run and the build jobs depend on them.

Why: The build-qcon-api / build job uses the reusable oci-build.yaml workflow which has change detection — it skips when only metadata files change (e.g. release-please PRs). When build-qcon-api / build is a required check, skipped runs leave the status as "Waiting for status to be reported", blocking merge. The lint job always runs and always reports a status.

Changes:

  • New lint job: installs Python 3.11 + ruff, runs ruff check . and ruff format --check .
  • Both lint steps use continue-on-error: true (advisory) since the codebase hasn't been linted before
  • build-qcon-api now has needs: [lint] so builds gate on lint passing

After merging: Update branch protection to require lint instead of (or in addition to) build-qcon-api / build. This ensures release-please PRs can merge without bypassing checks.

Review & Testing Checklist for Human

Risk: 🟡 Medium (CI workflow change)

  • Verify the lint job appears and passes (with advisory warnings) in this PR's CI
  • After merging, update branch protection rulesets: add lint as required, optionally remove build-qcon-api / build
  • Verify the next release-please PR shows all required checks as passing

Notes

  • ruff runs with default config (no pyproject.toml config). Once pre-existing issues are triaged, remove continue-on-error: true and optionally add a [tool.ruff] section to pyproject.toml for rule customization.
  • This pattern should be applied to other repos during migration (conversion-guide, course-workload-estimator, etc.) — see org knowledge update.

Link to Devin session: https://app.devin.ai/sessions/c8038ad2684a4fd786c6aa2a07ce9425
Requested by: @kphunter

Adds an unconditional lint job that runs ruff check and ruff format
on every PR and push. Both steps are advisory (continue-on-error)
until pre-existing issues are resolved.

The build job now depends on lint (needs: [lint]), matching the
hriv pattern where build jobs gate on quality checks.

This also fixes the release-please required checks issue: the lint
job always runs and reports a status, unlike build-qcon-api which
skips via change detection on metadata-only PRs.

Co-Authored-By: kyle_hunter@bcit.ca <kyle_hunter@bcit.ca>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

devin-ai-integration[bot]

This comment was marked as resolved.

@kphunter kphunter merged commit e11b144 into main May 25, 2026
6 checks passed
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