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

.github/workflows: checkout action use head commit #1891

Merged
merged 3 commits into from
May 18, 2021
Merged

Conversation

yondonfu
Copy link
Member

@yondonfu yondonfu commented May 17, 2021

What does this pull request do? Explain your changes. (required)

Always checkout the head commit for GH actions.

When a pull_request event triggers a GH action, the @actions/checkout action will checkout from the repo using the value of github.ref. The value of github.ref in this scenario is the SHA hash of the merge commit that is created by merging the base to the head. The problem with this is that the merge commit hash will be referenced in the go-livepeer version string, but the merge commit might not be present in the commit history (see #1887) which makes it difficult to debug builds.

Specific updates (required)

Set github.ref to the SHA of the head commit when checking out.

How did you test each of these updates (required)

Ran CI.

Does this pull request close any open issues?

Fixes #1887

Checklist:

@yondonfu yondonfu force-pushed the yf/fix-ci-hash branch 2 times, most recently from 7045a2d to 3652159 Compare May 17, 2021 20:57
@yondonfu yondonfu marked this pull request as ready for review May 17, 2021 21:22
@darkdarkdragon
Copy link
Contributor

@yondonfu windows build still has wrong hash

@yondonfu yondonfu mentioned this pull request May 17, 2021
5 tasks
@yondonfu
Copy link
Member Author

@yondonfu windows build still has wrong hash

@darkdarkdragon Should be fixed by c240ef9 and 5feadf5.

Copy link
Contributor

@darkdarkdragon darkdarkdragon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

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.

wrong hash in go-livepeer version string
2 participants