We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
$ cue version cue version v0.11.0-alpha.1.0.20240920112956-687464eb1846+dirty go version devel go1.24-165bf241f2 2024-09-19 00:40:50 +0000 -buildmode exe -compiler gc DefaultGODEBUG asynctimerchan=1,gotypesalias=0,httpservecontentkeepheaders=1,multipathtcp=0,randseednop=0,tls3des=1,tlskyber=0,x509keypairleaf=0,x509negativeserial=1 CGO_ENABLED 1 GOARCH amd64 GOOS linux GOAMD64 v3 vcs git vcs.revision 687464eb1846e51628bb62e8e8804968bd300d69 vcs.time 2024-09-20T11:29:56Z vcs.modified true cue.lang.version v0.11.0
I would expect the following testscript to succeed:
env CUE_DEBUG_SORT_ARCS=2 env CUE_EXPERIMENT= exec cue export cmp stdout out.gold env CUE_EXPERIMENT=evalv3 exec cue export cmp stdout out.gold -- file.cue -- package p x: [_]: set: [string]: bool x: [_]: { set: "aaa": true set: "zzz": true // Note that this bug depends on this field name sorting before the other. asList: [for p, _ in set {p}] } x: image1: set: ddd: true -- out.gold -- { "x": { "image1": { "asList": [ "aaa", "ddd", "zzz" ], "set": { "aaa": true, "ddd": true, "zzz": true } } } }
However, it fails:
> env CUE_EXPERIMENT=evalv3 > exec cue export [stdout] { "x": { "image1": { "asList": [ "ddd", "aaa", "zzz" ], "set": { "aaa": true, "ddd": true, "zzz": true } } } } > cmp stdout out.gold diff stdout out.gold --- stdout +++ out.gold @@ -2,8 +2,8 @@ "x": { "image1": { "asList": [ - "ddd", "aaa", + "ddd", "zzz" ], "set": { FAIL: repro-evalv3.txtar:9: stdout and out.gold differ
evalv3 fails to sort the fields when looping in the list comprehension, so we get a non-sorted result.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I would expect the following testscript to succeed:
However, it fails:
evalv3 fails to sort the fields when looping in the list comprehension, so we get a non-sorted result.
The text was updated successfully, but these errors were encountered: