Make WordPress Core

Opened 6 months ago

Last modified 3 weeks ago

#61887 new task (blessed)

Add automation to close stale pull requests

Reported by: swissspidy's profile swissspidy Owned by:
Milestone: Future Release Priority: normal
Severity: normal Version:
Component: Build/Test Tools Keywords: needs-patch
Focuses: Cc:

Description

Right now we have over 1600 open PRs on the GitHub repository.

Some of them are stale because the Trac tickets have long been closed, maybe even through another PR.

We could implement an automated GitHub Action that goes through old PRs and closes them if the referenced Trac ticket has been closed in the meantime.

Other things we could consider:

  • Update the PR from the base branch if it's super out of date
  • Add needs-refresh on Trac if there are merge conflicts (not sure if we can do that from within an action)

Change History (3)

#1 @dmsnell
6 months ago

Update the PR from the base branch if it's super out of date

Of note, Github already maintains an updated merge of each PR into its target branch up to the point of merge conflicts. This is what shows on a PR's diff view. That is, there's no need to update from the base branch unless a conflict prevents Github from updating the /merge branch for the PR, and if there's a conflict, this can't be done automatically.

https://fluffyandflakey.blog/2022/12/21/what-is-a-github-pull-request-merge-branch/

an automated GitHub Action that goes through old PRs and closes them

Might toss out the idea of leaving a comment and asking the PR author to confirm if it's still necessary, or ask to add a label to keep it open. Can be quite frustrating to have long-running work frequently closed without asking. I know most PRs can be relatively short lived, but as you know, sometimes work takes years to get done and requires a cascade of changes to the system before they can be finally reviewed and merged.

Alternatively, instead of closed, could they be switched to draft status?

This ticket was mentioned in Slack in #core by swissspidy. View the logs.


3 weeks ago

#3 @desrosj
3 weeks ago

  • Keywords needs-patch added
  • Milestone changed from Awaiting Review to Future Release

Related #62817.

Note: See TracTickets for help on using tickets.