Repository navigation
fix(health-digests): close prior daily digests (pr-review, runaway, docs-health) instead of accumulating - #1212
Conversation
Both digest steps ('PR Review Agent — failures detected <date>' and 'Runaway PR
candidate(s) detected <date>') embed the date in the title, so issues.create ran
every day — 20 + 6 open issues had accumulated. Close prior open digests (matching
title prefix, health-check label) before opening today's snapshot. Same pattern as
the fleet-monitor digest fix (#1204).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Juznz5V6su81ffSND8fg7s
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Warning Review limit reached
Next review available in: 48 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (2)
✨ 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 |
|
Note Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported. |
There was a problem hiding this comment.
Pull request overview
This PR updates the repo’s daily PR review health workflow to prevent date-stamped “digest” issues from accumulating by proactively closing older open digests before creating the current day’s snapshot.
Changes:
- Close prior open “PR Review Agent — failures detected …” digest issues before creating today’s digest.
- Close prior open “Runaway PR candidate(s) detected …” digest issues before creating today’s digest.
- Normalize digest title construction via shared
titlePrefixvariables.
Dev-Lead — review-changes (applied)Changes committed and pushed. |
'Docs Health Check — stale files detected <date>' embeds the date in its title, creating a fresh issue each run. Close prior open digests before opening today's, matching the other digest dedup fixes. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Juznz5V6su81ffSND8fg7s
7b8b152 to
e75b5d2
Compare
donpetry-bot
left a comment
There was a problem hiding this comment.
Automated review — APPROVED ✓
Risk: MEDIUM
Reviewed commit: e75b5d258de8fab2f47b96980ffcb1db7791ddf9
Review mode: triage-approved (single reviewer)
Summary
Confirms the triage assessment. The PR fixes digest-issue accumulation in three workflow steps (PR-review failures, runaway-PR candidates, docs-health stale files) by closing prior open digests — matched on constant title prefix plus both 'health-check' and 'automated-report' labels — before creating today's date-stamped issue. Same proven pattern as the fleet-monitor fix (#1204). Logic is safe: constant title prefixes (no untrusted interpolation), a !p.pull_request guard, and per-issue try/catch so a failed close cannot break the run.
Linked issue analysis
No linked issue (closingIssuesReferences is empty). The PR is a companion to #1204 and the body documents the problem directly: 20 + 6 open digest issues had accumulated from date-stamped titles. The diff substantively implements the described fix in all three digest-creating steps.
Findings
- Both Copilot review threads (scope the prior-digest search to
health-check,automated-report, not justhealth-check) were addressed in the dev-lead follow-up commit and are marked resolved. The final diff uses the dual-label filter in all three blocks. - No security concerns: constant title prefixes, no shell interpolation of untrusted data, no permission escalation (workflows already create issues, so
issues: writecovers the close). CodeQL (actions), gitleaks, AgentShield, SonarCloud, and shellcheck all pass. - MCP secret-scanning tool not available in this environment; relying on the passing gitleaks CI check.
- Minor (non-blocking): prior digests are only closed when a new digest is created, so if failures stop occurring the last digest stays open — arguably intended, since an open digest still reflects the latest unresolved snapshot.
- The two CANCELLED
dev-lead / dispatchanddev-lead / ci-relaycheck runs are dev-lead agent automation artifacts superseded by later pushes, not validation checks.
CI status
All validation checks green: CI (Lint, ShellCheck, Agent Security Scan, gitleaks, Compile agentic workflows), CodeQL (actions + python), SonarCloud quality gate, AgentShield, Lint suite (shellcheck, bats, template-drift, validate-agent-profiles, validate-personas, gh-aw-compile), Tests (unit-tests), Test AW Workflows, Holdout Guard, Test-Deletion Guard, CodeRabbit. Dependabot/dependency-audit jobs skipped (N/A). Two dev-lead agent check runs show CANCELLED (superseded automation, non-blocking); the review/review check is this run. Branch is BEHIND main but MERGEABLE.
Reviewed automatically by the PR-review agent (single-reviewer mode: fable 5). Reply if you need a human review.
donpetry-bot
left a comment
There was a problem hiding this comment.
Automated review — APPROVED ✓
Risk: MEDIUM
Reviewed commit: e75b5d258de8fab2f47b96980ffcb1db7791ddf9
Review mode: triage-approved (single reviewer)
Summary
Dedup fix for three date-stamped health digest issues (PR-review failures, runaway PR candidates, docs-health stale files). Each github-script step now closes prior open digests — matched by the 'health-check' + 'automated-report' labels and the exact title prefix, excluding PRs — before creating today's snapshot. Logic is correct, paginated, and failure-tolerant (per-issue try/catch → core.warning). No new permissions, actions, or untrusted-input interpolation.
Linked issue analysis
No linked closing issues. The PR is a companion to #1204 (fleet-monitor digest dedup) and applies the same validated pattern to the remaining health-check digest sources, matching the stated problem (20 + 6 accumulated open issues).
Findings
- Triage assessment confirmed: low-risk workflow-automation fix, no issues found.
- Both Copilot review threads (filter by both labels instead of only 'health-check') were addressed in the follow-up commit and are resolved.
- The two title prefixes within daily-pr-review-health.yml are distinct, so the second step cannot close the issue the first step just created.
- Minor, non-blocking: when a run finds nothing to report it returns early, so the previous day's digest stays open until the next non-empty run — pre-existing behavior, unchanged by this PR.
- Secret scan: run_secret_scanning MCP tool not available in this environment; gitleaks CI check passed (no secrets in the diff — workflow logic only).
CI status
All required checks green: Lint, ShellCheck, bats, CodeQL (actions + python), gitleaks secret scan, AgentShield, SonarCloud quality gate, unit tests, AW workflow validation, holdout-guard, test-deletion guard. Two CANCELLED 'dev-lead' checks are superseded agent-automation runs, not CI gates; the in-progress 'review / review' check is this review.
Reviewed automatically by the PR-review agent (single-reviewer mode: fable 5). Reply if you need a human review.
Superseded by automated re-review at e75b5d2.
|
Dev-Lead — waiting on PR blockers (intent: fix-reviews)PR: #1212 |
donpetry-bot
left a comment
There was a problem hiding this comment.
Automated review — APPROVED ✓
Risk: MEDIUM
Reviewed commit: 2e836a0c0a10587a335c5ca851b222c05a3d5fe7
Review mode: triage-approved (single reviewer)
Summary
Dedup fix for date-stamped health-check digest issues: before creating today's digest, the workflow now closes prior open digests matching the title prefix and both labels (health-check + automated-report). Applied to both digest blocks in daily-pr-review-health.yml and the stale-docs block in docs-health-check.yml. Logic is safe: paginated list scoped to both labels, PR guard, title-prefix match, per-issue try/catch with warning on failure. Neither workflow is a protected thin-caller stub.
Linked issue analysis
No linked closing issues. PR is a companion to #1204 (fleet-monitor digest dedup), applying the same pattern to the remaining health-check digest sources. The PR body slightly understates scope (it also fixes the Docs Health Check digest), but the change itself is consistent and correct.
Findings
No blocking findings. Both Copilot review threads (scope the prior-digest label filter to health-check,automated-report) were applied at the head commit and are resolved. Minor non-blocking note: priors are closed before the new digest is created, so a failed create would briefly leave no open digest — acceptable for a daily snapshot. Secret scanning MCP tool unavailable in this environment; gitleaks CI check is green and the diff contains no secret-like content.
CI status
All completed checks green (Lint, ShellCheck, CodeQL, gitleaks, agent-shield, SonarCloud, yaml/workflow validation, unit tests, bats). Cancelled/pending review and dev-lead entries are the review pipeline's own superseded runs, not code checks.
Reviewed automatically by the PR-review agent (single-reviewer mode: fable 5). Reply if you need a human review.
donpetry-bot
left a comment
There was a problem hiding this comment.
Automated review — APPROVED ✓
Risk: MEDIUM
Reviewed commit: 2e836a0c0a10587a335c5ca851b222c05a3d5fe7
Review mode: triage-approved (single reviewer)
Summary
Fixes digest-issue accumulation: before creating today's date-stamped digest, the workflows now close prior open digests (matched by title prefix + 'health-check,automated-report' labels, PRs excluded). Applied in 3 spots across daily-pr-review-health.yml and docs-health-check.yml. Confirms the triage assessment; head advanced past the previously approved SHA only via a merge of main (no changes to the PR's own files).
Linked issue analysis
No closing issue linked. PR body documents the problem (20 + 6 accumulated open digest issues) and cites #1204 as the companion fix for the fleet-monitor digest. Motivation is clear and the change substantively addresses it.
Findings
No blocking findings.
- Prior Copilot review suggestions (filter by both labels instead of only 'health-check') are implemented and both threads are resolved.
- Close calls are wrapped in try/catch with core.warning, so a single failure cannot abort digest creation.
- No new workflow permissions; issue titles are only compared via startsWith, never executed or shell-interpolated. Not a protected thin-caller workflow.
- MCP secret scanning tool unavailable in this run; gitleaks CI check passed (SUCCESS).
- Minor (non-blocking): PR body calls the Docs Health Check issues a 'separate source', but the diff now also patches docs-health-check.yml — body slightly stale after review-driven additions.
CI status
All checks green: shellcheck, CodeQL (actions + python), gitleaks secret scan, agent-shield, SonarCloud quality gate, workflow validation, unit tests, bats. The only PENDING check is this review run itself; CANCELLED entries are superseded runs on earlier commits.
Reviewed automatically by the PR-review agent (single-reviewer mode: fable 5). Reply if you need a human review.



Problem
daily-pr-review-health.ymlcreates two date-stamped digest issues unconditionally each run:PR Review Agent — failures detected <date>— 20 open accumulatedRunaway PR candidate(s) detected <date>— 6 open accumulatedSame dedup bug as the fleet-monitor digest and ContentTwin audit.
Fix
Before creating today's digest, close any prior open digests with the matching title prefix (
health-checklabel). Only the current snapshot stays open; history remains in closed issues.Validation
YAML parses; both github-scripts
node --checkclean (async-wrapped); yamllint clean (repo max 250).Companion to #1204 (fleet-monitor digest + fleet-tracker auto-close). Together they clear the health-check-only backlog. The remaining 3 'Docs Health Check' + 2 stub-drift issues are separate, lower-volume sources.
🤖 Generated with Claude Code
https://claude.ai/code/session_01Juznz5V6su81ffSND8fg7s