flake-update-20260505

FixCI Workflow

Steps

1. Verify Authentication

gh auth status

If not authenticated, stop and ask user to run gh auth login.

2. Resolve PR

If user provided a PR number or URL, use it. Otherwise resolve from current branch:

gh pr view --json number,url

3. Inspect Failing Checks

Run the bundled script first:

python3 "<skill-dir>/scripts/inspect_pr_checks.py" --repo "." --pr "<number>"

The script:

  • Fetches all PR checks
  • Filters to failing ones (failure, cancelled, timed_out, action_required)
  • Pulls GitHub Actions logs for each failure
  • Extracts failure snippets around error markers
  • Reports run metadata (workflow, branch, SHA)

4. Analyze Failures

For each failing check:

  1. Read the failure snippet from script output
  2. Identify the root cause category:
    • Test failure: Which test(s) failed, what assertion broke
    • Build failure: Compilation error, missing dependency
    • Lint/format: Style violation, formatting issue
    • Timeout: Which step hung, resource exhaustion
    • Infra: Runner issue, network failure, flaky setup
  3. Check if the failure is actionable (code fix needed) vs transient (retry may fix)

For GitHub Actions-specific issues (workflow config, permissions, caching), delegate to reviewer-ghactions subagent for deeper analysis.

5. Summarize and Plan

Present a summary:

## CI Failures for PR #<number>

### <Check Name> — <Category>
**Status:** <conclusion>
**Workflow:** <workflow name>
**Cause:** <one-line explanation>
**Evidence:**
``` **Fix:**


### 6. Wait for Approval

**CRITICAL: Do NOT edit code without explicit user approval.**

Ask: "Should I implement these fixes?" or present options if multiple approaches exist.

### 7. Implement Fix

After approval:
1. Make the code changes
2. Run relevant local tests to verify
3. Report what was changed

### 8. Verify

After fix is pushed:
```bash
gh pr checks <number> --watch

Or suggest user to check CI status after push.