add wont fix feature - #1222
Conversation
Signed-off-by: Jefferson <jefferson.rios.caro@gmail.com>
|
Important Review skippedNo new commits to review since the last review. ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
WalkthroughReconciliation now fetches closed stream issues, recognizes case-insensitive “won’t fix” labels, suppresses matching vulnerabilities using current or legacy keys, and reports skipped items in the final summary. ChangesWon’t-fix vulnerability suppression
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant Reconcile
participant Gh
participant GitHubIssues
participant DesiredVulnerabilities
Reconcile->>Gh: Fetch closed issues for stream
Gh->>GitHubIssues: List closed issues with stream filter
GitHubIssues-->>Gh: Return issue JSON
Gh-->>Reconcile: Return issues or raise on pagination limit
Reconcile->>Reconcile: Normalize labels and collect current or legacy keys
Reconcile->>DesiredVulnerabilities: Compare primary and legacy keys
DesiredVulnerabilities-->>Reconcile: Matching vulnerability
Reconcile-->>Reconcile: Skip processing and increment skipped
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
dep_checker/reconcile_issues.py (1)
333-343: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick winCheck suppression before updating an existing issue.
Because
issueis resolved before the suppression condition, a matching open issue is edited and counted asupdated; the won’t-fix branch only runs when no open issue exists. This violates the stated “skip creating or updating” behavior.Move the suppression check before
edit_body()/sync_labels()and handle any existing open duplicate explicitly.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@dep_checker/reconcile_issues.py` around lines 333 - 343, In the reconciliation flow around issue resolution, check whether the vulnerability’s pkey or legacy key is in suppressed before entering the existing-issue update path. For suppressed vulnerabilities, skip editing, label synchronization, and updated counting; explicitly handle any matching open issue as skipped while preserving the existing behavior for unsuppressed issues.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@dep_checker/reconcile_issues.py`:
- Around line 219-230: Update list_closed_issues so it never returns a truncated
closed-issue suppression list: paginate the query until all matching issues are
retrieved, or fail closed with an error when the limit is reached. Do not
continue reconciliation with the incomplete issues result, and preserve the
existing warning or reporting context as appropriate.
---
Outside diff comments:
In `@dep_checker/reconcile_issues.py`:
- Around line 333-343: In the reconciliation flow around issue resolution, check
whether the vulnerability’s pkey or legacy key is in suppressed before entering
the existing-issue update path. For suppressed vulnerabilities, skip editing,
label synchronization, and updated counting; explicitly handle any matching open
issue as skipped while preserving the existing behavior for unsuppressed issues.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 0884e45e-a439-4c96-b33e-9ed2b4b38b97
📒 Files selected for processing (1)
dep_checker/reconcile_issues.py
Signed-off-by: Jefferson <jefferson.rios.caro@gmail.com>
|
@coderabbitai review this again |
|
✅ Action performedReview finished.
|
|
✅ Action performedReview finished.
|
Summary by CodeRabbit