canonical / kfp-operators

Kubeflow Pipelines Operators
Apache License 2.0
2 stars 12 forks source link

tools/get-images.sh when not using snap version of `yq` #562

Closed mvlassis closed 4 days ago

mvlassis commented 2 weeks ago

Bug Description

Running the tools/get-images.sh with bash tools/get-images.sh produces a syntax error when running a version yq that hasn't been installed via snap.

The error occurs because there are 2 different maintained versions of yq, one that uses Go and one that uses Python. While the Go version supports glob characters, the Python doesn't and produces this error message.

I noticed this because I tried running the script on an Arch Linux installation with yq installed via the package manager. However, this also occurs using Ubuntu, if you install yq with pip (because it installs the Python package).

To Reproduce

Environment

Relevant Log Output

jq: error: syntax error, unexpected '*', expecting FORMAT or QQSTRING_START or '[' (Unix shell quoting issues?) at <top-level>, line 1:
.options.*-image |  select(.) | .default         
jq: 1 compile error

Additional Context

To check the version of yq, you can run yq --version and inspect the output. When using the Go version, the output should be similar to:

yq (https://github.com/mikefarah/yq/) version v4.44.2

When using the Python version, the output should be similar to:

yq 3.4.3
syncronize-issues-to-jira[bot] commented 2 weeks ago

Thank you for reporting us your feedback!

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

This message was autogenerated