regro / cf-scripts

Flagship repo for cf-regro-autotick-bot
Other
49 stars 74 forks source link

delayed automerge #1342

Open isuruf opened 3 years ago

isuruf commented 3 years ago

An automerge option that would send a reminder in X amount of days after the PR is open that the bot would merge in Y amount of days would be good to have that we could then enable by default for some migrations like abi migrations.

isuruf commented 3 years ago

And maybe a label that would prevent the bot from merging.

isuruf commented 3 years ago

cc @ocefpaf

We could then enable this by default.

CJ-Wright commented 3 years ago

To be fair the automerge logic isn't really handled by the bot. The bot knows which PRs are eligible for automerge and marks them as such but once that's done the bot doesn't interact with the PR unless it is in conflict or a rerun is requested. Also since the bot doesn't have permissions it can't add the label for automerge. I guess it could request the admin bot to add it? Would it be possible to handle the delay on the automerge side? https://github.com/conda-forge/automerge-action

isuruf commented 3 years ago

I guess the bot can make a comment to trigger the automerge action and the logic can be handled by the automerge-action.

beckermr commented 3 years ago

We can encode this information in the slug in the PR title the bot uses to label PRs that can be merged.

beckermr commented 3 years ago

The logic will have to be in the automerge scripts as @CJ-Wright says.

isuruf commented 3 years ago

Yes, but without the bot, we can't trigger it right?

beckermr commented 3 years ago

Ah yes, you are right ofc.

CJ-Wright commented 3 years ago

Is the delay from PR open or from latest update? (Also do we have both of those pieces of metadata available currently?)

beckermr commented 3 years ago

PR open and only if there are no other committers on the PR. TBH we probably should have another service altogether just go look at the correct set of PRs using the metadata in the cf-scripts repo.