-
Notifications
You must be signed in to change notification settings - Fork 132
Skip self-hosted tests and benchmarks for draft PRs #1262
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -151,7 +151,7 @@ jobs: | |||||
|
|
||||||
| self: | ||||||
| name: "${{ matrix.cluster_name }} (${{ matrix.device }}${{ matrix.interface != 'none' && format('-{0}', matrix.interface) || '' }})" | ||||||
| if: github.repository == 'MFlowCode/MFC' && needs.file-changes.outputs.checkall == 'true' | ||||||
| if: github.repository == 'MFlowCode/MFC' && needs.file-changes.outputs.checkall == 'true' && github.event.pull_request.draft != true | ||||||
|
||||||
| if: github.repository == 'MFlowCode/MFC' && needs.file-changes.outputs.checkall == 'true' && github.event.pull_request.draft != true | |
| if: github.repository == 'MFlowCode/MFC' && needs.file-changes.outputs.checkall == 'true' && (github.event_name != 'pull_request' || github.event.pull_request.draft != true) |
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
if:now referencesgithub.event.pull_request.draftoutside of anygithub.event_nameguard. Forworkflow_dispatchruns there is nopull_requestobject in the event payload, and accessinggithub.event.pull_request.draftmay fail evaluation. To keepworkflow_dispatchworking while skipping drafts, guard it with(github.event.pull_request == null || github.event.pull_request.draft != true)or move the draft check inside thepull_request/pull_request_reviewbranches.