--no-sort option is unstable
Author: slafsCreated Jun 29, 2022Updated Jan 12, 2024
For a simple JSON doc
{"z": "first", "a": "last"}gron --no-sort keeps producing wrong results at around 12% rate.
Tried it with:
$ for i in $( seq 1000 ); do echo '{"z": "first", "a": "last"}' | gron --no-sort | column -x; done | sort | uniq -c
125 json = {}; json.a = "last"; json.z = "first";
875 json = {}; json.z = "first"; json.a = "last";Tried it with:
$ gron --version
gron version dev$ brew info gron
gron: stable 0.7.1 (bottled), HEAD
Make JSON greppable
https://github.com/tomnomnom/gron
/usr/local/Cellar/gron/0.7.1 (4 files, 5MB) *
Poured from bottle on 2022-06-29 at 13:56:51
From: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/gron.rb
License: MIT
==> Dependencies
Build: go ✘
==> Options
--HEAD
Install HEAD version
==> Analytics
install: 878 (30 days), 2,899 (90 days), 5,560 (365 days)
install-on-request: 876 (30 days), 2,899 (90 days), 5,561 (365 days)
build-error: 0 (30 days)
$ brew list gron
/usr/local/Cellar/gron/0.7.1/bin/gronSource: tomnomnom/gron