Skip to content

feat(release): pinned-version report — Safe Release SC8 (#502) - #724

Merged
don-petry merged 10 commits into
mainfrom
feat/pinned-version-report-502
Jul 14, 2026
Merged

feat(release): pinned-version report — Safe Release SC8 (#502)#724
don-petry merged 10 commits into
mainfrom
feat/pinned-version-report-502

Conversation

@don-petry

Copy link
Copy Markdown
Contributor

Closes the SC8 residual of #502 (the rollback half already ships via cut-release.sh --promote).

What

scripts/pinned-version-report.sh + a weekly workflow that publishes who is on what version across the fleet. For each repo × ring reusable it:

  • finds the caller-stub uses: pin,
  • resolves the @<agent>/<channel> tag to the immutable <agent>/vX.Y.Z release it points at (matching tag SHAs on the host repo),
  • reports ring tier · pinned channel · resolved version, and
  • flags ring-tier drift + unresolved pins.

Read-only (GET-only, no mutation). Runs Mondays 08:00 UTC + workflow_dispatch, writing to the run's step summary.

Live output (real fleet, today)

Renders a full repo×reusable table with resolved versions (e.g. dev-lead → v1.5.4, auto-rebase → v2.1.1) plus a per-reusable version fan-out. It already surfaces 2 real drifts — including broodly/feature-ideation pinned to a raw SHA that resolves to no release.

Validation

bash -n + shellcheck (0 findings); workflow YAML valid; executed live against the fleet.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Juznz5V6su81ffSND8fg7s

The Safe Release epic (#495) had drift detection (ring-pins.sh, canary-rings lint,
template_stub_drift.sh) but no single 'who is on what version' surface (SC8). Add
scripts/pinned-version-report.sh + a weekly workflow: for each fleet repo x ring
reusable it finds the caller-stub uses: pin, resolves the @<agent>/<channel> tag
to the immutable <agent>/vX.Y.Z release it points at (matching tag SHAs on the
host repo), reports ring tier / pinned channel / resolved version, and flags
ring-tier drift. Read-only. Live run already surfaces real drift (e.g. a
SHA-pinned feature-ideation stub that never resolved to a release).

Closes the SC8 residual of #502 (rollback half already shipped via cut-release).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Juznz5V6su81ffSND8fg7s
Copilot AI review requested due to automatic review settings July 14, 2026 20:52
@don-petry
don-petry requested a review from a team as a code owner July 14, 2026 20:52
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@coderabbitai

coderabbitai Bot commented Jul 14, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@don-petry, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 36 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

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 configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 71271fa1-6b8f-43fa-9280-92163ebd406e

📥 Commits

Reviewing files that changed from the base of the PR and between 8bbfac6 and eeaf55f.

📒 Files selected for processing (5)
  • .github/workflows/pinned-version-report-tests.yml
  • .github/workflows/pinned-version-report.yml
  • scripts/pinned-version-report.sh
  • test/scripts/pinned-version-report/resolve-and-drift.bats
  • test/scripts/pinned-version-report/stubs/gh
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/pinned-version-report-502

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@don-petry

Copy link
Copy Markdown
Contributor Author

Dev-Lead — review-changes (no-changes)

No changes were needed for this PR.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new Bash script, scripts/pinned-version-report.sh, which generates a Markdown report detailing each ring consumer's currently-pinned channel and its resolved immutable version. The code review feedback provides several actionable improvements to enhance performance and robustness: replacing expensive sed subshells inside the nested loop with built-in Bash parameter expansion and regex matching, handling potential missing trailing newlines and carriage returns when reading TSV data, storing regular expressions in variables for safer matching, and using .content // empty in jq to prevent the literal string "null" from bypassing empty checks.

Comment thread scripts/pinned-version-report.sh Outdated
Comment thread scripts/pinned-version-report.sh Outdated
Comment thread scripts/pinned-version-report.sh Outdated
Comment thread scripts/pinned-version-report.sh Outdated
@don-petry
don-petry disabled auto-merge July 14, 2026 20:54

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds an org-wide reporting surface to answer “who is pinned to what version” for ring-released reusable workflows, by scanning fleet repos’ workflow stubs, resolving each pinned channel to an immutable release version, and publishing the results on a weekly schedule (and on-demand).

Changes:

  • Introduces scripts/pinned-version-report.sh to scan fleet repos, detect each reusable’s pinned ref, resolve it to a vX.Y.Z release tag (when possible), and render a Markdown report (including drift flags and a version fan-out summary).
  • Adds a scheduled GitHub Actions workflow to run the report weekly and publish it to the run step summary.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 6 comments.

File Description
scripts/pinned-version-report.sh New Bash reporter that enumerates org repos, extracts pinned uses: refs for ring reusables, resolves channel→release versions, and renders a Markdown summary.
.github/workflows/pinned-version-report.yml Weekly + manual workflow to execute the report in CI and write output to the step summary.

Comment thread scripts/pinned-version-report.sh Outdated
Comment thread scripts/pinned-version-report.sh Outdated
Comment thread scripts/pinned-version-report.sh
Comment thread scripts/pinned-version-report.sh
Comment thread .github/workflows/pinned-version-report.yml
Comment thread scripts/pinned-version-report.sh
coderabbitai[bot]
coderabbitai Bot previously approved these changes Jul 14, 2026
@don-petry

Copy link
Copy Markdown
Contributor Author

Dev-Lead — fix-reviews (applied)

Changes committed and pushed.

coderabbitai[bot]
coderabbitai Bot previously approved these changes Jul 14, 2026
@don-petry
don-petry disabled auto-merge July 14, 2026 21:00
@don-petry

Copy link
Copy Markdown
Contributor Author

Dev-Lead — review-changes (applied)

Changes committed and pushed.

@don-petry
don-petry disabled auto-merge July 14, 2026 21:11
@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 21:15
@don-petry
don-petry disabled auto-merge July 14, 2026 21:16
@don-petry

Copy link
Copy Markdown
Contributor Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
Issues addressed: 0
Status: Quality Gate passed — no actionable issues found
Tier 1 blockers: 0
Files changed: scripts/pinned-version-report.sh, .github/workflows/pinned-version-report.yml, .github/workflows/pinned-version-report-tests.yml, test/scripts/pinned-version-report/*
Skipped (informational): 0
The PR has a clean bill of health. SonarCloud shows no new issues, security hotspots, or code quality concerns. All CI checks pass and no reviewer has requested changes. Ready to merge.
```

@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 21:17
@don-petry
don-petry disabled auto-merge July 14, 2026 22:05
@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 22:07
@don-petry
don-petry disabled auto-merge July 14, 2026 22:10
@don-petry

Copy link
Copy Markdown
Contributor Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
Issues addressed: 0
Files changed: none
Skipped (informational): 0 — SonarCloud quality gate passed with no new issues or security hotspots detected
```
The SonarCloud bot found no actionable issues. The pull request is in a good state and ready for merge from a code quality and security perspective.

@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 22:11

@donpetry-bot donpetry-bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated review — APPROVED ✓

Risk: MEDIUM
Reviewed commit: 4f2149768edab90af1c91a334f90be5c798c1cfc
Review mode: triage-approved (single reviewer)

Summary

Adds a read-only weekly pinned-version report (scripts/pinned-version-report.sh + workflow) for Safe Release SC8, with a bats suite, gh stub, and a dedicated CI test workflow. Purely additive (5 new files, 383+/0-), all CI green, triage assessment confirmed.

Linked issue analysis

Linked work item is petry-projects/.github-private#502 ([Phase 2] One-action rollback + per-version observability report, targets SC4/SC8). The rollback half (SC4) already shipped via cut-release.sh --promote; this PR delivers the SC8 residual — a per-version observability report showing each consumer's pinned channel and the immutable release it resolves to, plus ring-tier drift flags. Done-when criterion ('a which-version report shows tag→commit per ring/consumer') is substantively met. Note: the PR body's bare '#502' resolves to an unrelated item in the .github repo — the reference is cross-repo, not missing.

Findings

Security (no blockers):

  • New scheduled workflow consumes the org PAT (GH_PAT_WORKFLOWS) — usage is read-only (GET-only script), triggers are schedule/workflow_dispatch (not attacker-controllable), permissions are contents: read, actions are SHA-pinned with persist-credentials: false, and no untrusted input is interpolated into run blocks. PAT usage drives the MEDIUM classification but follows this repo's established pattern.
  • MCP secret scanning tool unavailable in this run; the gitleaks CI check passed and no secret-like content appears in the diff.

Correctness (minor, non-blocking):

  • printf '%b' "$rows" would interpret backslash escapes in repo names — cosmetic only, org repo names are controlled.
  • Drift case pattern *"$tier" is a suffix match; an unconventional channel name (e.g. 'unstable' vs tier 'stable') could false-negative — report-only impact, covered channels follow the vN-ringN/stable convention.

Review threads: 9 of 10 threads resolved. The one UI-unresolved thread (Copilot: add bats tests + CI wiring) is substantively resolved — the requested bats suite, gh stub, and test workflow are all in this PR, the author replied in detail, and the 'Lint and bats' check passes. The bot cannot resolve its own thread.

CI status

All required checks green at 4f21497: CI (Lint, ShellCheck, Agent Security Scan, gitleaks), Pinned-version-report Tests (Lint and bats), CodeQL, SonarCloud (Quality Gate passed, 0 new issues / 0 hotspots), AgentShield, Dependency audit, CodeRabbit. Skipped checks are conditional ecosystem audits (pip/pnpm/cargo/govulncheck) — expected. 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.

@don-petry
don-petry disabled auto-merge July 14, 2026 22:29
@don-petry

Copy link
Copy Markdown
Contributor Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
- ✅ **0 New issues**
- ✅ **0 Accepted issues**
- ✅ **0 Security Hotspots**
- ✅ **0.0% Coverage on New Code**
- ✅ **0.0% Duplication on New Code**
**Tier 1 blockers assessment:**
- No failed CI checks (Lint, ShellCheck, SonarCloud, Agent Security Scan, and pinned-version-report tests all passed)
- No `CHANGES_REQUESTED` reviews
- CodeRabbit approved; donpetry-bot approved with MEDIUM risk assessment
**Conclusion:** The SonarCloud bot found zero actionable issues. The code quality gate passed cleanly. No fixes are required.

@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 22:30
@don-petry
don-petry disabled auto-merge July 14, 2026 22:37
@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 22:41
@don-petry
don-petry disabled auto-merge July 14, 2026 23:05
@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 23:07
@don-petry
don-petry disabled auto-merge July 14, 2026 23:08
@don-petry

Copy link
Copy Markdown
Contributor Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
Issues addressed: 0
Files changed: None
Status: Quality Gate passed — no actionable issues from bot
```
The PR has no code issues flagged by the SonarCloud bot. All required CI checks are green, and the automated review (donpetry-bot) approved the changes. The PR is ready to merge.

@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 23:08
@don-petry
don-petry disabled auto-merge July 14, 2026 23:22
@sonarqubecloud

Copy link
Copy Markdown

@don-petry
don-petry enabled auto-merge (squash) July 14, 2026 23:25
@don-petry
don-petry disabled auto-merge July 14, 2026 23:25
@don-petry

Copy link
Copy Markdown
Contributor Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
- 0 Security Hotspots  
- 0.0% Coverage/Duplication on New Code
✅ **CI Status: ALL GREEN**
- All required checks passed (Lint, ShellCheck, CodeQL, SonarCloud, AgentShield, etc.)
- Pinned-version-report Tests workflow passes bats suite
✅ **Review Threads: ALL RESOLVED**
- **Resolved:** Copilot thread about missing bats tests — confirmed test suite exists at `test/scripts/pinned-version-report/resolve-and-drift.bats` and CI workflow at `.github/workflows/pinned-version-report-tests.yml` [replied + thread resolved]
- All prior Copilot/Gemini threads marked resolved or outdated
### Conclusion
**No actionable issues from the SonarCloud bot comment.** The Quality Gate passed with zero new issues. The PR includes a comprehensive bats test suite and dedicated CI workflow that both execute successfully. All review threads are now resolved. The branch is ready to merge.

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@don-petry
don-petry merged commit b112956 into main Jul 14, 2026
24 of 28 checks passed
@don-petry
don-petry deleted the feat/pinned-version-report-502 branch July 14, 2026 23:27

@donpetry-bot donpetry-bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated review — APPROVED ✓

Risk: MEDIUM
Reviewed commit: eeaf55f1fe4ad6009e089fb8cfd2bec4be17573b
Review mode: triage-approved (single reviewer)

Summary

Adds a read-only pinned-version reporting surface (SC8 residual of #502): scripts/pinned-version-report.sh scans fleet repos' caller stubs, resolves each @/ pin to its immutable vX.Y.Z release via tag-SHA matching, and flags ring-tier drift. Shipped with a weekly scheduled workflow (Mondays 08:00 UTC + workflow_dispatch, contents: read, SHA-pinned checkout), a bats test suite covering resolution/drift/fan-out paths, and a PATH-stubbed gh binary so tests need no live API. Confirms the triage assessment: the script is strictly GET-only, the org PAT (GH_PAT_WORKFLOWS) is guarded and used only for cross-repo reads, and no mutation paths exist. Since the prior automated approval at 4f21497, only main-branch merges landed (README/LICENSE/SECURITY.md/workflow-permissions); none touch this PR's files.

Linked issue analysis

No closing-issue link, by design: the PR closes the SC8 residual of #502 (rollback half already shipped via cut-release.sh --promote). The body documents live-fleet validation including two real drift findings, so the reporting goal of SC8 is substantively addressed.

Findings

  • No blocking findings. All 10 prior review threads (gemini, copilot) are resolved — dev-lead fix-reviews commits addressed the sed-subshell, --limit 500, error-suppression, trailing-space fan-out, and PAT-guard items, with regression tests added (e.g. the #502 trailing-space bats test).
  • Security: workflows use least-privilege permissions (contents: read), actions pinned by SHA, persist-credentials: false; the report script performs only GET calls; markdown output goes to the step summary (no workflow-command injection surface). Gitleaks and Agent Security Scan are green; the tests' GH_TOKEN is an explicit dummy. The run_secret_scanning MCP tool was unavailable in this session — gitleaks CI + manual inspection found no secrets.
  • Minor (non-blocking): printf '%b' on repo-derived row content would interpret backslash escapes in odd repo/channel names (cosmetic rendering only); ref_regex in resolve_version is not declared local.

CI status

All required checks green at eeaf55f: ShellCheck, Lint and bats (new suite), CodeQL, SonarCloud quality gate, Agent Security Scan, Secret scan (gitleaks), npm audit, agent-shield. Two CANCELLED dev-lead dispatch/ci-relay entries are superseded duplicates of later SUCCESS runs.


Reviewed automatically by the PR-review agent (single-reviewer mode: fable 5). Reply if you need a human review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants