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

Warn when try build SHA is mismatched #540

Merged
merged 1 commit into from
Sep 7, 2020

Conversation

Aaron1011
Copy link
Member

Fixes #539

If the latest commit on the PR does not match the base commit for the
detected try build, we add a warning message to the bot comment.

Verified

This commit was signed with the committer’s verified signature.
Aaron1011 Aaron Hill
Fixes rust-lang#539

If the latest commit on the PR does not match the base commit for the
detected try build, we add a warning message to the bot comment.
@pietroalbini
Copy link
Member

Thanks!

@bors r+

@bors
Copy link
Contributor

bors commented Sep 7, 2020

📌 Commit c865f7f has been approved by pietroalbini

@bors
Copy link
Contributor

bors commented Sep 7, 2020

⌛ Testing commit c865f7f with merge 966d5d6...

@bors
Copy link
Contributor

bors commented Sep 7, 2020

☀️ Test successful - checks-actions
Approved by: pietroalbini
Pushing 966d5d6 to master...

@bors bors merged commit 966d5d6 into rust-lang:master Sep 7, 2020
@Aaron1011 Aaron1011 deleted the feature/warn-try-build branch September 15, 2020 20:39
Aaron1011 added a commit to Aaron1011/crater that referenced this pull request Jan 2, 2021

Verified

This commit was signed with the committer’s verified signature.
Aaron1011 Aaron Hill
In rust-lang#540, I used the `build_sha`
field to detect when the current PR head does not match the PR head used
when creating the 'try' build. However, 'build_sha' corresponds to the
*first* parent of the merge commit, which corresponds to the commit on
the rust-lang/rust 'master' branch.

We now retrieve the parents of the merge commit from GitHub, and check
the first parent against the current head commit of the PR.

During local testing, I had created a merge commit with the order of the
parents reversed, so the check appeared to work fine for me.
bors added a commit that referenced this pull request Apr 21, 2021
Use second parent of merge commit when detecting outdated 'try' build

In #540, I used the `build_sha`
field to detect when the current PR head does not match the PR head used
when creating the 'try' build. However, 'build_sha' corresponds to the
*first* parent of the merge commit, which corresponds to the commit on
the rust-lang/rust 'master' branch.

We now retrieve the parents of the merge commit from GitHub, and check
the first parent against the current head commit of the PR.

During local testing, I had created a merge commit with the order of the
parents reversed, so the check appeared to work fine for me.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Warn when auto-detected try build is not the latest commit
3 participants