ci(python): fail the lint workflow on fixable vulnerabilities - #3807
Merged
Conversation
Run uv audit after uv sync --frozen in the ruff job and filter the JSON report to advisories that have a fix_versions entry, so the build only breaks on vulnerabilities that can actually be resolved by bumping a dependency. Audit exit code 1 means vulnerabilities were found and is handled; anything higher is a network or configuration failure and is propagated unchanged rather than being reported as a clean audit. Co-Authored-By: Claude Opus 5 (1M conte
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3807 +/- ##
==========================================
- Coverage 79.20% 79.19% -0.02%
==========================================
Files 894 894
Lines 67034 67034
Branches 2553 2601 +48
==========================================
- Hits 53095 53086 -9
- Misses 13278 13287 +9
Partials 661 661
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Add .github/workflows/python_lint.yml to the pull_request paths filter so edits to the workflow are exercised by the PR that makes them, instead of only running once a Python file happens to change. Co-Authored-By: Claude Opus 5 (1M context)
- Switch uv audit to --output-format sarif and upload the report to code scanning and as an artifact, matching how ty is published; uv emits SARIF natively so no converter is needed - Publish every advisory, including ones with no fix yet, and gate only on results carrying uv/fixVersions, replacing the jq rewrite that dropped unfixable findings before they were reported - Move the gate after the ruff steps so a vulnerable dependency no longer skips lint results in the same run - Grant the ruff job security-events: write, which the code scanning upload requires and the workflow-level contents: read did not give Co-Authored-By: Claude Opus 5 (1M context)
Contributor
|
You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool. What Enabling Code Scanning Means:
For more information about GitHub Code Scanning, check out the documentation. |
|
mcosgriff
marked this pull request as ready for review
September 2, 2026 21:10
clayandgen
approved these changes
Sep 2, 2026
calmonroe
approved these changes
Sep 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Run uv audit after uv sync --frozen in the ruff job and filter the JSON report to advisories that have a fix_versions entry, so the build only breaks on vulnerabilities that can actually be resolved by bumping a dependency.
Audit exit code 1 means vulnerabilities were found and is handled; anything higher is a network or configuration failure and is propagated unchanged rather than being reported as a clean audit.
What changed
Making use of
uv auditto check our python dependencies against fixed CVEsWhy it changed
Testing out the ability to check the python dependencies for fixable CVEs
uv auditworkflow for enterprise in https://github.com/OpenC3/cosmos-enterprise/pull/716