chore(ci): auto-close resolved issues in the vulnerability triage pipeline#1501
Draft
brendan-kellam wants to merge 2 commits into
Draft
Conversation
The triage pipeline created/reopened Linear issues for vulnerabilities but never closed them once resolved, so a fixed CVE could linger as an open, SLA-breaching issue. Reconcile open pipeline-created issues against the current findings each run and move any whose vulnerability is no longer reported to Done. Run triage on the canonical repo even when scans are clean so reconciliation happens, and guard the close step on successful scans to avoid mass-closing on scan failure. Co-authored-by: linear-code[bot] <222613912+linear-code[bot]@users.noreply.github.com>
Contributor
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Co-authored-by: linear-code[bot] <222613912+linear-code[bot]@users.noreply.github.com>
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.
The vulnerability triage pipeline created and reopened Linear issues for CVEs/alerts, but never closed them once the vulnerability was resolved. So a fix that landed (e.g. #1474) left the corresponding issue open and it kept breaching SLA.
This adds a reconciliation step that closes resolved issues:
[<repository>]title prefix) and close any whose finding id no longer appears in the current scan results, moving it to the team'sDone(completed) state.Linear Triagejob now also runs on the canonical repo when scans come back clean, so reconciliation happens even when there are zero findings (the exact case where a resolved CVE would otherwise linger open).done_state_id) alongside the existingTriagestate to perform the close.Since create/reopen only touch issues whose id is present in findings and close only touches issues whose id is absent, the two operate on disjoint sets and don't conflict.