problem-specifications icon indicating copy to clipboard operation
problem-specifications copied to clipboard

Automatic merging

Open SaschaMann opened this issue 4 years ago • 4 comments

We may want to think about implementing an automatic merging strategy/bot. That could prevent further frustration, such as:

  • PRs are merged before people can chime in
  • PRs get stale after some discussion due to a lack of decision
  • PRs need 3 approving reviews, even if they're trivial
  • People have to wait for an unspecific time and don't know when they can continue their work if it relies on the PR being merged.

Further it would allow some automation to be more seamless, e.g. automatically formatting files or adding UUIDs for test-cases before merging without any kind of manual labour.


The exact criteria would have to be discussed, there are a lot of things to be considered. A basic starting point, inspired by Julia's General package registry, could look like this:

  • PRs by people with push access that contain only additions are automatically merged after 3 days if there are no comments (incl comments by the PR creator).
  • PRs by people without push access that contain only additions are automatically merged after 3 days if there are no comments (incl comments by the PR creator) and there is at least one approving review by someone with push access.
  • Comments block the automerging.
  • Merging can also be triggered manually or once a certain threshold of approving reviews has been reached, so that the "PR processing" can run.
  • Comments containing [noblock] (or whatever) do not block comments. This allows people to thank the contributor, or add additional information.

These could be extended to cover other cases. Some ideas:

  • Automerge all PRs regardless of the kind of change, unless they're blocked by a comment.
  • When discussions have gone stale for 3 days, post a reminder. If there are no additional comments after another 2 days, and there are no "requesting changes" reviews, merge the PR.

The numbers are arbitrary suggestions. 3 days is what the Julia registry uses but might be a bit short for Exercism.

SaschaMann avatar Oct 13 '20 13:10 SaschaMann