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

Check if commit is from bors #318

Merged
merged 1 commit into from
Jun 17, 2024
Merged

Check if commit is from bors #318

merged 1 commit into from
Jun 17, 2024

Conversation

ehuss
Copy link
Collaborator

@ehuss ehuss commented Feb 13, 2024

This fixes an issue where if a SHA commit is given that isn't a bors commit, it would result in a confusing panic message about two sha's not being equal.

The LocalGit backend handled this, but the GitHub backend did not. The solution here is to lift the check up to a higher level. It will fetch the start and end commits, and check the author of them.

This required a few code changes, since the committer info wasn't exposed. In summary:

  • Added the committer field to the Commit object. Then added the necessary code to add that info.
  • In bisect_ci_via, check the start/end are by bors before querying for the range of commits.
  • A few minor cleanups:
    • Added BORS_AUTHOR const.
    • Changed GithubCommit's author and committer to be Option to more correctly follow GitHub's API (since they can be nil).

@ehuss ehuss merged commit a05c97c into rust-lang:master Jun 17, 2024
4 checks passed
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.

2 participants