Bug in IF conditions on inputs for reusable workflows #25293
-
Problem:When a reusable workflow (called workflow), contains if conditions (based on the input of the job) at job level, there is a observation that the if condition seems to execute and use value globally (causing jobs which are being skipped because of a check). Example
Observation
Which implies of some sort of “state” of the IF condition (since there is no relationship between Job 4 and Job 3).
The observation of runs can be found in this repository here → push stuff · action-foobar/action-testing@500bca2 · GitHub |
Beta Was this translation helpful? Give feedback.
Replies: 10 comments
-
Same issue seen on our pipelines here:
MOV-AI/.github/blob/a20d4764cadcdaa8f206dc247255d5ee28dea354/.github/workflows/reusable-ros-build-pack.yml#L141 |
Beta Was this translation helpful? Give feedback.
-
Faced same issue, our CI/CD is pretty much blocked now |
Beta Was this translation helpful? Give feedback.
-
I’ve even removed the IF, and the second job continues to be skipped. We are really blocked! |
Beta Was this translation helpful? Give feedback.
-
Seems to happen when a sibling job gets skipped, any subsequent jobs then get skipped, even if they are not related. See run Create main.yml · wongjn/test@f05463b · GitHub. |
Beta Was this translation helpful? Give feedback.
-
Thanks for the info. With this we are able to workaround temporarily. Also opened a github ticket pointing to this thread to see if we raise the criticality on this. |
Beta Was this translation helpful? Give feedback.
-
Watch this issue - Bug in IF conditions on inputs for reusable workflows · Issue #1602 · actions/runner · GitHub |
Beta Was this translation helpful? Give feedback.
-
@Surveyforcustomers invalid link |
Beta Was this translation helpful? Give feedback.
-
If i realy understend, you need change the job 3 like this:
Will run |
Beta Was this translation helpful? Give feedback.
-
You need to wrap the whole expression in
With partial expressions the output is just a string (e.g. “true && false”) and a non-empty string evaluates to |
Beta Was this translation helpful? Give feedback.
-
This is resolved from Bug in IF conditions on inputs for reusable workflows · Issue #1602 · actions/runner · GitHub . |
Beta Was this translation helpful? Give feedback.
This is resolved from Bug in IF conditions on inputs for reusable workflows · Issue #1602 · actions/runner · GitHub .