Repository navigation
feat: implement issue #851 — [#850 A] Automated standards-deploy driver (scheduled fleet sweep → standards-sync PRs) - #854
Conversation
…er (scheduled fleet sweep → standards-sync PRs)
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Warning Review limit reached
Next review available in: 25 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 (4)
✨ 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 |
Dev-Lead — review-changes (no-changes)No changes were needed for this PR. |
There was a problem hiding this comment.
Pull request overview
Adds a scheduled + on-demand GitHub Actions “driver” to run the existing deploy-standard-workflows.sh fleet sweep automatically, so drifted repos get standards-sync PRs without manual intervention (issue #851 / Epic #850-A).
Changes:
- Introduces
scripts/standards-deploy-driver.shto mapworkflow_dispatchinputs (env vars) todeploy-standard-workflows.shflags. - Adds a new scheduled/dispatch workflow
.github/workflows/standards-deploy.ymlto run the driver weekly (and on demand). - Adds a dedicated bats suite for the driver and wires it into the existing
standards-deploy-tests.ymlquality gates.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
scripts/standards-deploy-driver.sh |
Thin wrapper that translates workflow env inputs into deploy-script flags and executes the deploy sweep. |
.github/workflows/standards-deploy.yml |
New scheduled + dispatch workflow that runs the fleet sweep using the org PAT. |
test/scripts/standards-deploy-driver/driver.bats |
Bats coverage for argv mapping plus drift/no-op paths via a gh stub. |
.github/workflows/standards-deploy-tests.yml |
Extends existing lint+bats gating to include the new driver script, tests, and workflow. |
Superseded by automated re-review at
|
🤖 CodeAnt AI — Review Status
Updated in place by CodeAnt AI · last 5 reviews |
- driver: simplify exec to "${args[@]}" (empty-array-safe in modern bash;
drops the redundant ${args[@]+...} guard and its shellcheck noise)
- workflow: use a boolean literal `default: false` for the type:boolean
dry_run input (was quoted string)
- workflow: map DRY_RUN explicitly to the "true"/"false" strings the driver
checks, instead of mixing boolean/string via `|| 'false'`
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CoxYr15rT5ceo7UKZ6r86Y
codeant (Major): `grep -vq 'Would open PR'` passes whenever ANY line does not match, so the no-op test couldn't prove PR-absence. Use a true absence check `! ... | grep -q` so a regression that plans a PR on the compliant path fails. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CoxYr15rT5ceo7UKZ6r86Y
|
donpetry-bot
left a comment
There was a problem hiding this comment.
Automated review — APPROVED ✓
Risk: MEDIUM
Reviewed commit: dc0ed12dffd10160cd1b2689c9d10cffcfe709bf
Review mode: triage-approved (single reviewer)
Summary
Adds a scheduled (Mon 08:00 UTC) + workflow_dispatch driver that runs the existing deploy-standard-workflows.sh fleet sweep, opening standards-sync PRs for drifted repos (issue #851, Epic #850-A). The driver stays deliberately thin (env→flag mapping only) and ships with a bats suite covering argv mapping plus drift/no-op paths against the real deploy script. This is cycle 2: the prior review at cd60399 escalated solely on 3 unresolved Copilot threads (gate 4) plus a minor bats tautology — all four points are now fixed in commits ec5864a and dc0ed12, and every review thread is resolved.
Linked issue analysis
Issue #851 substantively addressed: (1) scheduled + dispatch workflow standards-deploy.yml, Monday cadence offset from the Friday compliance audit; (2) reuses the existing deploy script and standards-sync label — the driver adds no deploy logic; (3) idempotency and SKIP_REPOS/SKIP_OVERRIDES remain in the deploy script, exercised by the no-op bats test; (4) dispatch supports fleet, single-repo, single-workflow, and dry-run sweeps; (5) uses the established ORG_SCORECARD_TOKEN org PAT with least-privilege workflow permissions (top-level 'permissions: {}', job-level contents: read); (6) bats tests cover drift-detection and no-op paths, wired into the standards-deploy-tests.yml gate.
Findings
All prior-cycle findings resolved, no new issues:
- ✅
${args[@]+"${args[@]}"}idiom simplified to plain"${args[@]}"(scripts/standards-deploy-driver.sh:45) — thread resolved; ShellCheck green on bash 5.x runners. - ✅
default: 'false'string → boolean literaldefault: falseon the dry_run input (standards-deploy.yml:34). - ✅
${{ inputs.dry_run || 'false' }}type-mixing replaced with explicit mapping${{ inputs.dry_run == true && 'true' || 'false' }}(standards-deploy.yml:53). - ✅ bats no-op tautology fixed:
grep -vq→! grep -q 'Would open PR'— a true absence check (driver.bats, commit dc0ed12).
The merge of main (11eae23) brings no conflicts with this PR's files. Security posture unchanged and good: schedule/dispatch-only triggers, no untrusted input interpolation (inputs pass via env), SHA-pinned checkout, established org PAT. All 4 review threads resolved; CodeRabbit approved; no unanswered human-reviewer questions.
Secret scan: run_secret_scanning MCP tool unavailable in this run; gitleaks CI check passed. No secrets in the diff.
CI status
All checks green at dc0ed12: Lint, ShellCheck, bats (incl. new driver suite), Agent Security Scan, Secret scan (gitleaks), CodeQL (actions), SonarCloud (quality gate passed), AgentShield, npm audit, Lint and bats. Remaining skips are ecosystem-not-present audits (pip/cargo/govulncheck/pnpm).
Reviewed automatically by the PR-review agent (single-reviewer mode: fable 5). Reply if you need a human review.



User description
Closes #851
Implemented by dev-lead agent. Please review.
CodeAnt-AI Description
Add scheduled standards deployment for drifting repos
What Changed
standards-syncpull requests when a repo is missing a required workflow stub or is out of sync.Impact
✅ Fewer manual standards-sync runs✅ Faster cleanup of drifted repos✅ Safer dry-run checks before changes💡 Usage Guide
Checking Your Pull Request
Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.
Talking to CodeAnt AI
Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:
This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.
Example
Preserve Org Learnings with CodeAnt
You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:
This helps CodeAnt AI learn and adapt to your team's coding style and standards.
Example
Retrigger review
Ask CodeAnt AI to review the PR again, by typing:
Check Your Repository Health
To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.