chore: enhance account summary table with links to issues and PRs#15177
chore: enhance account summary table with links to issues and PRs#15177
Conversation
mnkiefer
commented
Feb 12, 2026
- Improves account summary table and ensures review submissions are properly included in user activity tracking.
There was a problem hiding this comment.
Pull request overview
Enhances the bot-detection workflow’s account summary output by making counts clickable (linking to relevant GitHub searches) and by including PR review submissions in the “user activity” data used to identify high-risk new accounts.
Changes:
- Add linked counts in the Step Summary account table (issues/PRs/comments).
- Include PR review submissions via
pulls.listReviewsso non-comment reviews are tracked as activity.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| const openIssuesLink = linkCount(openIssues, `${baseRepoURL}/issues?q=is%3Aissue+is%3Aopen+author%3A${encodedLogin}`); | ||
| const closedIssuesLink = linkCount(closedIssues, `${baseRepoURL}/issues?q=is%3Aissue+is%3Aclosed+author%3A${encodedLogin}`); | ||
| const openPRsLink = linkCount(openPRs, `${baseRepoURL}/pulls?q=is%3Apr+is%3Aopen+author%3A${encodedLogin}`); | ||
| const closedPRsLink = linkCount(closedPRs, `${baseRepoURL}/pulls?q=is%3Apr+is%3Aclosed+author%3A${encodedLogin}`); | ||
| const commentsLink = linkCount(comments, `${baseRepoURL}/issues?q=commenter%3A${encodedLogin}`); | ||
|
|
There was a problem hiding this comment.
The table counts issues/PRs/comments from data.*, which are filtered to created_at >= cutoff elsewhere in this script, but the new links here don’t include any time filter. Clicking the linked counts can therefore show more results than the count displayed. Consider passing the cutoff (or at least the cutoff date) into buildAccountSummaryTable and adding a created:>=... qualifier (or otherwise making the linked query match the same window as the counts).
| const openIssuesLink = linkCount(openIssues, `${baseRepoURL}/issues?q=is%3Aissue+is%3Aopen+author%3A${encodedLogin}`); | |
| const closedIssuesLink = linkCount(closedIssues, `${baseRepoURL}/issues?q=is%3Aissue+is%3Aclosed+author%3A${encodedLogin}`); | |
| const openPRsLink = linkCount(openPRs, `${baseRepoURL}/pulls?q=is%3Apr+is%3Aopen+author%3A${encodedLogin}`); | |
| const closedPRsLink = linkCount(closedPRs, `${baseRepoURL}/pulls?q=is%3Apr+is%3Aclosed+author%3A${encodedLogin}`); | |
| const commentsLink = linkCount(comments, `${baseRepoURL}/issues?q=commenter%3A${encodedLogin}`); | |
| const cutoffIso = cutoff.toISOString(); | |
| const cutoffQuery = `+created%3A%3E%3D${encodeURIComponent(cutoffIso)}`; | |
| const openIssuesLink = linkCount( | |
| openIssues, | |
| `${baseRepoURL}/issues?q=is%3Aissue+is%3Aopen+author%3A${encodedLogin}${cutoffQuery}`, | |
| ); | |
| const closedIssuesLink = linkCount( | |
| closedIssues, | |
| `${baseRepoURL}/issues?q=is%3Aissue+is%3Aclosed+author%3A${encodedLogin}${cutoffQuery}`, | |
| ); | |
| const openPRsLink = linkCount( | |
| openPRs, | |
| `${baseRepoURL}/pulls?q=is%3Apr+is%3Aopen+author%3A${encodedLogin}${cutoffQuery}`, | |
| ); | |
| const closedPRsLink = linkCount( | |
| closedPRs, | |
| `${baseRepoURL}/pulls?q=is%3Apr+is%3Aclosed+author%3A${encodedLogin}${cutoffQuery}`, | |
| ); | |
| const commentsLink = linkCount( | |
| comments, | |
| `${baseRepoURL}/issues?q=commenter%3A${encodedLogin}${cutoffQuery}`, | |
| ); |