Conversation
Group PRs by author (bold heading) instead of a flat list, with PRs sorted by age within each group and author groups ordered by oldest PR. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Pull request overview
This PR updates the CorePing Slack notification formatting so Core/Important PRs are grouped by PR author instead of being displayed as a single flat list, improving readability and helping reviewers prioritize by author and age.
Changes:
- Added logic to group PRs by
author, sort PRs within each group bystatusAt(oldest first), and order groups by their oldest PR. - Updated Slack message rendering to output grouped sections with
*@author*:headers for both “pending review” and “keep in mind” lists.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ? `Congratulations! All Core/Important PRs are reviewed! 🎉🎉🎉` | ||
| : `Hey <@comfy>, Here's x${pendingReviewCorePRs.length} Core/Important PRs waiting your feedback! | ||
| - ${pendingReviewCorePRs.map((pr) => `@${pr.author}: <${pr.url}|${pr.title}> (${pr.labels}) is ${pr.status} ${forDuration(pr.statusAt)}`).join("\n- ")}`; | ||
| ${formatGroupedPRs(groupByAuthor(pendingReviewCorePRs), (pr) => `<${pr.url}|${pr.title}> (${pr.labels}) is ${pr.status} ${forDuration(pr.statusAt)}`)}`; |
There was a problem hiding this comment.
The template literal adds a leading space before the grouped PR output (there’s a literal space after the newline before ${formatGroupedPRs(...)}). This will indent the first *@author*: line in Slack and can subtly affect formatting; consider removing the leading whitespace (e.g., put the interpolation immediately after the newline or trim the inserted block).
|
|
||
| const keepInMindMessage = | ||
| remainingOpeningCorePRs.length > 0 | ||
| ? `\n\nAdditionally, there ${remainingOpeningCorePRs.length === 1 ? "is" : "are"} ${remainingOpeningCorePRs.length} other open Core/Important ${remainingOpeningCorePRs.length === 1 ? "PR" : "PRs"} that ${remainingOpeningCorePRs.length === 1 ? "is" : "are"} pending for author's change/update, lets wait for them. |
There was a problem hiding this comment.
The "Additionally..." message has the same leading-whitespace issue: there is a literal space after the newline before the grouped PR output, which will indent the first *@author*: line in Slack. Also, the sentence uses "lets wait" (should be "let's wait").
| ? `\n\nAdditionally, there ${remainingOpeningCorePRs.length === 1 ? "is" : "are"} ${remainingOpeningCorePRs.length} other open Core/Important ${remainingOpeningCorePRs.length === 1 ? "PR" : "PRs"} that ${remainingOpeningCorePRs.length === 1 ? "is" : "are"} pending for author's change/update, lets wait for them. | |
| ? `\n\nAdditionally, there ${remainingOpeningCorePRs.length === 1 ? "is" : "are"} ${remainingOpeningCorePRs.length} other open Core/Important ${remainingOpeningCorePRs.length === 1 ? "PR" : "PRs"} that ${remainingOpeningCorePRs.length === 1 ? "is" : "are"} pending for author's change/update, let's wait for them. |
Summary
*@author*:heading) instead of a flat listBefore:
After:
Test plan
bun build --no-bundle app/tasks/coreping/coreping.ts)🤖 Generated with Claude Code