canonical / charmed-kubeflow-workflows

Repository that containes GitHub workflows and shareable configs for Charmed Kubeflow
0 stars 0 forks source link

`get-rocks-modified-and-build-scan-test-publish.yaml` fails if no rocks need to be published #43

Open ca-scribner opened 7 months ago

ca-scribner commented 7 months ago

Bug Description

If get-rocks-modified.yaml returns an empty list because no rock dirs have experienced changes for this push, the CI passes an empty list as the rock-dir and the later workflows fail because the matrix vector must contain something. An example of this is this dex-auth-rocks run which happened when cutting a new track from main (and thus, no changes to the repo happened during the push).

To Reproduce

Run the workflow without a change to a file in a rock dir

Environment

-

Relevant Log Output

https://github.com/canonical/dex-auth-rocks/actions/runs/7573552116

Specifically:

Annotations
1 error
On Push: .github#L1
Error when evaluating 'strategy' for job 'build-scan-test-publish-rock'. canonical/charmed-kubeflow-workflows/.github/workflows/get-rocks-modified-and-build-scan-test-publish.yaml@main (Line: 37, Col: 19): Matrix vector 'rock-dir' does not contain any values

Additional Context

This might be solvable just by adding a check in get-rocks-modified.yaml to make sure if we find no dirs, we return an empty list []

syncronize-issues-to-jira[bot] commented 7 months ago

Thank you for reporting us your feedback!

The internal ticket has been created: https://warthogs.atlassian.net/browse/KF-5218.

This message was autogenerated

orfeas-k commented 7 months ago

Should we include this in canonical/bundle-kubeflow#765?