-
Notifications
You must be signed in to change notification settings - Fork 11
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
fix: don’t build anew if a PR was simply edited, edited again #336
Conversation
e1fdcb7
to
8f48a95
Compare
Hm. I wonder if this is a good idea 🤔 Suppose we create a PR and the pull-request.yaml workflow fails because build.yaml fails; next, we make a comment on that same PR and now the workflow succeeds because it wouldn’t build again… |
Ok, run 3182767662 (6m 36s) was the initial run when we opened this PR which built the artifacts. Then we changed the PR title, thus triggering run 3182834503 (20s). Next, let’s change the title back. Adding comments to a PR doesn’t seem to trigger the workflow, though. |
How about creating two separate workflows for checking PR title and PR code changes to avoid the issue? |
8f48a95
to
78edf05
Compare
Commit 78edf05. |
.github/workflows/pr-change-set.yaml
Outdated
# This workflow checks and tests the package code, and it builds all package | ||
# artifacts whenever there were changes to a pull request. | ||
|
||
name: 'Pull Request: change set' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think Pull Request
in the name is not necessary because the trigger should appear in the workflow run.
How about "Check change set"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On the website the action run shows the name:
of the Action:
with
name: Scorecards supply-chain security |
How about "Check change set"?
Sure.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Commit bd8d88b.
@@ -3,7 +3,7 @@ | |||
# tool to check the title of the PR and all commit messages of the branch | |||
# which triggers this Action. | |||
|
|||
name: Pull Request | |||
name: 'Pull Request: conventional commits' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same comment regarding the name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Commit bd8d88b.
pull_request: | ||
branches: | ||
- main | ||
- staging |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed shall we change the target branches to *
to make sure the checks run on all pull requests?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR or a separate one?
See also issue #330: there’s no need to run the build.yaml workflow if a PR was merely edited (i.e. no code was changed).