Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automerge can happen after a force-push without waiting for tests #3099

Closed
abraham opened this issue Jan 22, 2019 · 6 comments
Closed

Automerge can happen after a force-push without waiting for tests #3099

abraham opened this issue Jan 22, 2019 · 6 comments

Comments

@abraham
Copy link

abraham commented Jan 22, 2019

What Renovate type are you using?

Renovate GitHub App

Describe the bug

V8.0.0 of ts-node was released an update PR was opened, and the tests pass. v8.0.1 of ts-node is released and the PR is force-pushed with the new version, the PR is immediately merged without waiting for a new CI run.

Did you see anything helpful in debug logs?

Based on 40758419 it looks like the PR was updated and merged in the same job.

To Reproduce

Get an update PR, have CI succeed, find new update for same package.

Expected behavior

I would expect force-pushing a PR to wait until CI runs succeed to merge.

Screenshots

This is a screenshot of the PR just after the PR was merged showing pending checks:

screenshot from 2019-01-21 20-22-13

Additional context

This seems to have happened on a half-dozen or so of my repos.

@rarkins
Copy link
Collaborator

rarkins commented Jan 22, 2019

What do the logs show for the run where that happened? We normally should log the result of the commit status checks.

@rarkins
Copy link
Collaborator

rarkins commented Jan 22, 2019

Also, if you need to enforce that Travis tests pass before merging, you can add that as part of branch protection for master - this is the correct and foolproof way to ensure commits can't be merged without tests.

@rarkins
Copy link
Collaborator

rarkins commented Jan 22, 2019

I missed the exact log link you gave originally. Copy/pasting from that run:

No branch protection found
getBranchStatus(renovate/ts-node-8.x)
"state":"pending","statuses":[],"msg":"branch status check result"
"result":{"total_count":0,"check_runs":[]},"msg":"No check runs found"
automerge":true,"automergeType":"pr","automergeComment":"automergeComment","msg":"Checking #217 for automerge"
PR is configured for automerge
Automerging #217
mergePr(217, renovate/ts-node-8.x)

@rarkins
Copy link
Collaborator

rarkins commented Jan 22, 2019

Added an extra branch status check to check for this edge case where we're pushing to a PR that had previously passed tests. Thanks @abraham

@renovate-bot
Copy link
Collaborator

🎉 This issue has been resolved in version 13.179.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

@abraham
Copy link
Author

abraham commented Jan 22, 2019

Awesome! Thanks.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 16, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants