Closed wizardishungry closed 10 months ago
Strange. Seem to work with golang 1.21.4 on macOS
$ uname -a
Darwin C02WW1K9HV2R 22.6.0 Darwin Kernel Version 22.6.0: Wed Oct 4 21:25:26 PDT 2023; root:xnu-8796.141.3.701.17~4/RELEASE_X86_64 x86_64
$ go version
go version go1.21.4 darwin/amd64
$ go run github.com/itchyny/gojq/cmd/gojq < swagger.json . | wc -l
8155
What does it say if you do
go run github.com/itchyny/gojq/cmd/gojq . swagger.json; echo $?
But i did noticed that the "."
should probably be an argument to gojq and not a file to redirect. For me with zsh i get an error if i try to redirect (.: Is a directory
)
go run github.com/itchyny/gojq/cmd/gojq . < swagger.json | wc -l
I'm not sure what was going on. I tried skipping the asdf shim and deleting my mod cache. Finally I just did a clean reinstall of go and that fixed it. Not sure why it was only that particular document, but this is all on me. Thanks and sorry to bother you.
No worries, been there :)
swagger.json downloaded from https://eastus.dev.cognitive.microsoft.com/docs/services/speech-to-text-api-v3-0/
Same behavior for other queries. Other JSON works fine.