Closed noisyscanner closed 4 years ago
@noisyscanner what version of jq are you using? Because I know this command is being used by at least 4 company's pipelines with no issues. Maybe I should also check for versions in the beginning part of the script
Hmm we are on the same version of jq jq-1.5-1-a5b5cbe
Could you paste a code snippet of how you are calling the orb. I remember running into this myself. It was weirdness with jq I think.
Here is the sample monorepo: https://github.com/swissknife/circle-monorepo
the recent pipelines seem to work.
Also here is how the jq -cr
is supposed to work in your case. My guess is that some invalid js or is the case. The reason we don't need ''
to -cr is that the input is coming from the piped command. But maybe there is some weird case I haven't encountered yet :D
Also I'm glad you are trying the orb out :) It has saved us a TON of time.
That was a quick response! Locally I installed the same version as you mention, and dry-ran it through as you see in the commands echoed above, and got the same issue. Adding the quote after like jq -cr ''
fixed it for me:
@roopakv the command you posted also worked fine for me, but try appending > file
to the end - then I get the error
@noisyscanner all right lets give it a shot, send me a PR.
I'll have to make sure it works on the sample repo and some internal repos. as long it does we should be good :)
you are right, the command files when adding > file
. However im so confused. We are using this daily, and no pipelines are failing 🤷
oh wells! thanks for the catch
@noisyscanner published. you should be able to use version 0.44.0
with the fix.
You should see the latest version at https://orb.swissknife.dev
thanks for the fix :)
Hey, super useful orb - thank you! We are hoping that
trigger-workflows-for-all-modified
will substantially speed up our CI and bring the cost down.When using the above step, it fails with the following error:
I copied the source of this into our pipeline and added
set -x
for debugging - it looks likejq -cr
is the culprit. Trying this locally I got the same error and it seems thatjq -cr ''
is correct if you want to redirect the output to a file. I will put in a PR to fix this.