Reputation: 209
Started seeing this issue with jq suddenly out of the blue for my system where its failing for simplest of use-cases:
$ echo '{"foo": 0}' | jq .
jq: error: syntax error, unexpected $end (Unix shell quoting issues?) at <builtin>, line 29:
)
jq: 1 compile error
Here's a description of my environment:
OS and Version: MacOS Catalina 10.15.7, 64-bit jq versions: 1.6, 1.5, 1.4
I tried installing jq with brew (brew install jq
) as well as using binaries directly provided here for OSX 64-bit and getting same error. It works strangely however with jq-1.3 but thats a pretty old version missing some important filters like gsub
.
Upvotes: 4
Views: 4136
Reputation: 209
Posted this issue in jq github repo and got prompted for issue with ~/.jq file. Indeed my ~/.jq file had the said syntax error. Fixing my ~/.jq file fixed the issue.
Upvotes: 2