Repository navigation
chore(.github): add stale PR workflow - #1170
andrewdennis117 wants to merge 1 commit into
Conversation
|
@codex review |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 40a75ad6b8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (commit.author?.login === author || commit.committer?.login === author) { | ||
| activity.lastAuthorAt = Math.max( | ||
| activity.lastAuthorAt, | ||
| toTime(commit.commit?.committer?.date), |
There was a problem hiding this comment.
Use the actual push time for author activity
When an author responds to review by pushing a commit that was created earlier—for example, an old local commit—commit.commit.committer.date remains earlier than the review because it is commit metadata, not the time the branch was pushed. lastAuthorAt therefore is not advanced, so the workflow can leave the stale label in place and automatically close an actively updated PR. Track the branch update time rather than the embedded commit timestamp.
Useful? React with 👍 / 👎.
35C4n0r
left a comment
There was a problem hiding this comment.
@andrewdennis117 let's handle the case for
/commandcases, for example/scorecardshould not start the timer.- Bot PRs opened by @blink or Dependabot
Description
Adds a daily workflow that marks and closes PRs that are waiting on their author.
stalelabel. If there's still no response 3 days later, it's closed. Stale and close messages are empty, matchingcoder/coder.stalelabel if it doesn't exist. Issues aren't affected.dry_runoption that only logs what would change.Plain
actions/staleonly tracks last-updated time, so the "waiting on the author" check lives in.github/scripts/stale-prs.js, run throughactions/github-script.Type of Change
Testing & Validation
bun fmt)dry_runand review the logs