feat(stale): name the repo on every PR line in the Slack digest (BE-4574)#76
feat(stale): name the repo on every PR line in the Slack digest (BE-4574)#76mattmillerai wants to merge 1 commit into
Conversation
…574)
The digest only carried the repo name once, in the header, so an individual
line ('• #3523 ...') was ambiguous about which repo it came from once quoted,
forwarded, or read on its own. Carry $REPO into fmt() so every 'Marked stale'
and 'Closed as stale' line renders as '<url|Comfy-Org/cloud#3523> title'.
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 29 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 Plus Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
Comment |
There was a problem hiding this comment.
🔍 Cursor Review — Consolidated panel
Triggered by @mattmillerai.
✅ No high-signal findings.
Panel: 8/8 reviewers contributed findings.
ELI-5
The Stale PR bot posts a Slack digest listing the PRs it just marked stale or closed. Each line only said
#3523— no repo. That reads fine when one repo is posting, but the same bot runs (and will increasingly run) in several repos into the same channel, so#3523is ambiguous the moment a line is quoted, forwarded, or read on its own. This makes every line sayComfy-Org/cloud#3523instead.What changed
fmt()— the one line-builder used for BOTH the "Marked stale" and "Closed as stale" lists — now interpolates$REPO(github.repository, already in the step'senv:) into the Slack link label:The header (
*Stale PR bot — ${REPO}*) is unchanged and still names the repo — the per-line name is additive, not a replacement. Comments + the README catalog entry are updated to match.BE-2776 built this reusable and deliberately scoped out per-line naming ("keep the per-PR link lines as-is — they already resolve correctly"). This is the follow-up that adds it.
Why it's safe
actions/staleinputs, to theif:gating, or to the Slack POST/error handling.slack_escapeon the title is untouched, and$REPOitself needs no escaping — GitHub constrainsgithub.repositoryto[A-Za-z0-9._-]+/[A-Za-z0-9._-]+, which contains none of& < >.$REPO, so the label now simply matches the URL it points at.Testing
jqexpression against a fixture matchingactions/stale's output shape (a normal PR, a PR with a hostile title containing<!channel>/&/ a masked<url|label>link, and a PR with notitlekey) plus the empty-string and[]inputs. Output:[]inputs still produce no lines.actionlint .github/workflows/stale.yml— clean.zizmor v1.22.0 --no-online-audits— no findings.cloudandcomfy-infrastill run their own standalone copies), so no scheduled run exercises it yet. The companion PR below makescloudthe first caller.Companion / merge order
Comfy-Org/cloud#5588 migrates
cloud's standalonestale.ymlto a thin caller of this reusable. Merge this PR first, then bump the SHA pin in that PR to the resultingmaincommit before merging it — otherwisecloudcalls the pre-change reusable and the digest gets the repo name in the header only.Follow-ups (not in this PR)
comfy-infra/.github/workflows/stale.ymlis also still a standalone copy — same migration applies there; the ticket calls it out as a follow-up.bump-stale-callers.ymlalongside the existingbump-*-callers.ymlworkflows, so caller SHA pins for this reusable have to be bumped by hand. Worth adding once it has real callers.