Workflow on PR labeled action always fails if there is already OK workflow for the same commit

Workflow on pull_request labeled action always fails if there is already completed workflow for the same commit.

Failed workflow is displayed in “Actions” tab but is not even accessible, click on the failed workflow (that was triggered by labeled action) always opens completed workflow (that was triggered by open or synchronize action).

see config https://github.com/researchspace/researchspace/blob/github-actions-ci/.github/workflows/main.yml

@aindlq ,

The workflow run triggered by PR labeled to be failed is not caused by the previous completed workflow run, the root cause is an incorrect syntax to get the label name on the if condition.
The correct syntax should be:

if: github.event.action != 'labeled' || github.event.label.name == 'build_image'
1 Like

@brightran  thanks, that fixed the problem?

What confused me is that it was not possible to access failed build at all, it always redirected to the successful one.