JS-1513 peach-check skill: filter ANSI script-preview lines, clarify parallelism rule#6701
JS-1513 peach-check skill: filter ANSI script-preview lines, clarify parallelism rule#6701francois-mora-sonarsource wants to merge 36 commits intomasterfrom
Conversation
- Fix description to use triggering conditions only (not workflow summary) - Remove invalid disable-model-invocation frontmatter field - Flatten step numbering (remove single-phase wrapper) - Expand grep pattern to cover clone timeouts, project misconfiguration, and dep failures - Make parallel agents opt-in for ambiguous cases only (classify directly when obvious) - Compress agent prompt template (remove verbose XML block) - Fix cluster check to handle null completedAt by falling back to log timestamps Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
… new categories - Add Step 3b: when ≥80% of jobs fail, sample 5 jobs and apply the dominant verdict to all instead of triaging every job individually - Replace Phase 1 tail-based approach with grep: cleanup steps that run after scan failures push the exit code out of the tail window; grep is more reliable - Add two new IGNORE categories to docs/peach-main-analysis.md: - Peach server unreachable (HTTP 502/503 at scan start) - Artifact expired (HTTP 410 during JAR download) Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…ass failure verdict rules - Replace one-liner grep with multi-line sed -n scripts for readability - Add allowed-tools header and prerequisites section - Clarify mass failure verdict rules: CRITICAL takes priority when stack trace originates in org.sonar.plugins.javascript, even for mass failures - Add exit code 3 disambiguation: always run Phase 2 for exit code 3 failures - Rename "SonarJS Analyzer Crash" to "SonarJS Plugin Failure" to cover plugin initialization failures (not just sensor-level crashes) - Add example log excerpt for plugin initialization failure - Fix step numbering (3b → 4, renumber remaining steps accordingly) - Move cluster check to its own Step 7, after classification Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…lure - Fix forward ref in Step 2: completedAt null handling is in Step 7, not Step 8 - Add explicit flowchart branch for plugin initialization failure (no sensor name but org.sonar.plugins.javascript in stack trace → CRITICAL), preventing it from falling through to the IGNORE branch Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…d detection patterns - Save logs to target/peach-logs/ instead of piping, enabling Phase 2 without re-download - Inline --jq filter in gh api calls so only failed jobs are returned (no client-side filtering) - Add sed --sandbox flag to prevent e command injection from untrusted log content - Add Step 1b: auto-rerun cancelled runs and stop early - Add ETARGET/notarget/503 patterns to Phase 1 filter - Fix Phase 3 to use Read tool on saved log instead of re-fetching via gh api - Add command discipline section (no &&/;/| chaining) - Add mass failure CRITICAL-takes-priority rule - Add Detection patterns to every failure category in docs/peach-main-analysis.md - Add canonical sed pattern reference section to docs/peach-main-analysis.md Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…-preview lines - Clarify that the no-chaining rule (no &&/;/|) and parallel execution (multiple Bash calls in one response) are orthogonal concerns - Add /\[36;1m/b to Phase 1 and Phase 2 sed scripts to skip GitHub Actions script-preview lines, preventing spurious pattern matches on lines like `echo "All 3 attempts failed"` that appear in every job log as part of the pre-execution script display Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Keep HEAD changes: ANSI script-preview line filter (/\[36;1m/b) in Phase 1 and Phase 2 sed scripts, and the paragraph clarifying that parallel Bash calls are distinct from chaining. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
SummaryThis PR refines the peach-check skill for triaging SonarJS Peach Main Analysis workflow failures, with emphasis on filtering ANSI artifacts and clarifying failure classification. Core technical fix: Added Structural improvements:
Clarifications added:
What reviewers should knowStart here: Review Key decision points:
Testing notes:
Non-code changes:
|
Ruling Report✅ No changes to ruling expected issues in this PR |
|
README Freshness Check❌ The rules README is out of date. A fix PR has been created: #6752 Please review and merge it into your branch. |
…uidance - Fix missing spaces in allowed-tools frontmatter between Bash() entries - Add explicit callout of the echo && command anti-pattern in the Command discipline section - Clarify Phase 1 instructions: write job name as plain text, then issue sed as a standalone Bash call with no prefix Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
- Fix path inconsistency: create target/peach-logs upfront in Step 2 and write jobs.json to target/jobs.json; remove redundant mkdir in Step 5 - Clarify completedAt is reliably null in paginated API; always use log timestamps - Add SocketTimeoutException and ReportPublisher.upload to Phase 1 filter so report-upload timeout failures can be classified without needing Phase 2 - Sync docs/peach-main-analysis.md Phase 1 patterns section Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
|





Summary
/\[36;1m/bto Phase 1 and Phase 2sedscripts to skip GitHub Actions ANSI-colored script-preview lines, preventing false-positive matches (e.g.echo "All 3 attempts failed"being mistaken for a clone timeout).codexand Claude MCP config files to.gitignoreTest Plan
/peach-checkand verify Phase 1 output no longer includes spurious ANSI-colored script-preview lines🤖 Generated with Claude Code