From 4cfc580c2a4db53e2f8ecc934c882dce52e1b2dd Mon Sep 17 00:00:00 2001 From: AI DevOps Date: Sun, 8 Mar 2026 15:34:05 -0600 Subject: [PATCH 1/3] fix: filter out approving reviews from quality-debt issue creation (t1406) Replace the weak body-length filter (>100 chars) for APPROVED reviews with content analysis that detects actionable language. APPROVED reviews without suggestions, warnings, security concerns, or code fix proposals are now excluded from quality-debt issue creation. Actionable patterns kept: should, consider, instead, suggest, recommend, warning, caution, avoid, don't, vulnerable, insecure, injection, xss, csrf, nit:, todo:, fixme, hardcoded, deprecated, race condition, deadlock, leak, overflow, workaround, hack, suggestion/diff blocks. Ambiguous words removed from filter (common in positive descriptions): bug, error, fix, patch, missing, incorrect, wrong, broken. Closes #2958 --- .agents/scripts/quality-feedback-helper.sh | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/.agents/scripts/quality-feedback-helper.sh b/.agents/scripts/quality-feedback-helper.sh index 659891abf7..da51e9444b 100755 --- a/.agents/scripts/quality-feedback-helper.sh +++ b/.agents/scripts/quality-feedback-helper.sh @@ -714,8 +714,23 @@ _scan_single_pr() { select($sev_num >= $min_num) | - # Skip approval-only reviews with no substantive body - select(.state != "APPROVED" or (.body | length) > 100) | + # Filter out approving reviews with no actionable feedback (t1406). + # APPROVED reviews from bots often contain long summaries/walkthroughs + # that are purely positive — these should not create quality-debt issues. + # Keep the review only if: (a) not APPROVED, or (b) body contains + # actionable language (suggestions, warnings, bugs, fix proposals). + (if .state == "APPROVED" then + ($body | test( + "\\bshould\\b|\\bconsider\\b|\\binstead\\b|\\bsuggest|\\brecommend|" + + "\\bwarning\\b|\\bcaution\\b|\\bavoid\\b|\\bdon.t\\b|\\bdo not\\b|" + + "\\bvulnerab|\\binsecure|\\binjection\\b|\\bxss\\b|\\bcsrf\\b|" + + "\\bnit:|\\btodo:|\\bfixme|\\bhardcoded|\\bdeprecated|" + + "\\brace.condition|\\bdeadlock|\\bleak|\\boverflow|" + + "\\bworkaround\\b|\\bhack\\b|" + + "```(suggestion|diff)"; "i")) + else true + end) | + select(.) | { pr: ($pr | tonumber), From e122f69df8e23d7a4f5bf7e2f12d74fec5694df7 Mon Sep 17 00:00:00 2001 From: AI DevOps Date: Sun, 8 Mar 2026 15:43:10 -0600 Subject: [PATCH 2/3] fix: improve actionable-language regex patterns (Gemini review) - Match 'dont' (no apostrophe) via (don ?'?t|do not) group - Allow whitespace between backticks and language identifier in code block detection (e.g., '``` suggestion') --- .agents/scripts/quality-feedback-helper.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.agents/scripts/quality-feedback-helper.sh b/.agents/scripts/quality-feedback-helper.sh index da51e9444b..78621efea0 100755 --- a/.agents/scripts/quality-feedback-helper.sh +++ b/.agents/scripts/quality-feedback-helper.sh @@ -722,12 +722,12 @@ _scan_single_pr() { (if .state == "APPROVED" then ($body | test( "\\bshould\\b|\\bconsider\\b|\\binstead\\b|\\bsuggest|\\brecommend|" + - "\\bwarning\\b|\\bcaution\\b|\\bavoid\\b|\\bdon.t\\b|\\bdo not\\b|" + + "\\bwarning\\b|\\bcaution\\b|\\bavoid\\b|\\b(don ?'?t|do not)\\b|" + "\\bvulnerab|\\binsecure|\\binjection\\b|\\bxss\\b|\\bcsrf\\b|" + "\\bnit:|\\btodo:|\\bfixme|\\bhardcoded|\\bdeprecated|" + "\\brace.condition|\\bdeadlock|\\bleak|\\boverflow|" + "\\bworkaround\\b|\\bhack\\b|" + - "```(suggestion|diff)"; "i")) + "```\\s*(suggestion|diff)"; "i")) else true end) | select(.) | From dfd185493f763a9d974d0a9d1a3a4cb99d5ab298 Mon Sep 17 00:00:00 2001 From: marcusquinn <6428977+marcusquinn@users.noreply.github.com> Date: Mon, 9 Mar 2026 04:10:26 +0000 Subject: [PATCH 3/3] fix: escape single quote in jq regex to fix ShellCheck parsing errors (SC1073, SC1089, SC1056, SC1072) --- .agents/scripts/quality-feedback-helper.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.agents/scripts/quality-feedback-helper.sh b/.agents/scripts/quality-feedback-helper.sh index 78621efea0..912371fcae 100755 --- a/.agents/scripts/quality-feedback-helper.sh +++ b/.agents/scripts/quality-feedback-helper.sh @@ -722,7 +722,7 @@ _scan_single_pr() { (if .state == "APPROVED" then ($body | test( "\\bshould\\b|\\bconsider\\b|\\binstead\\b|\\bsuggest|\\brecommend|" + - "\\bwarning\\b|\\bcaution\\b|\\bavoid\\b|\\b(don ?'?t|do not)\\b|" + + "\\bwarning\\b|\\bcaution\\b|\\bavoid\\b|\\b(don ?'"'"'?t|do not)\\b|" + "\\bvulnerab|\\binsecure|\\binjection\\b|\\bxss\\b|\\bcsrf\\b|" + "\\bnit:|\\btodo:|\\bfixme|\\bhardcoded|\\bdeprecated|" + "\\brace.condition|\\bdeadlock|\\bleak|\\boverflow|" +