-
-
Notifications
You must be signed in to change notification settings - Fork 320
New issue
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
update/make default GHC 9.0 #1615
Conversation
@Xitian9 in case you have some spare time: Hledger.Data.Json is producing an unstable order for object fields, or at least different between our GHC 8.10 and GHC 9.0 builds. Possibly related to the *KV code ?
I think these are the package versions used in the GHC 8.10 build:
And these with the GHC 9.0 build:
|
containers-0.6.2.1 -> containers-0.6.4.1 maybe. |
Perhaps related to this: haskell/aeson#837 |
Just random speculation here: this might be related to the change in underlying integer representation in ghc-9.0. The question is what to do about it. The ordering of fields has never been guaranteed by the aeson library, and any choice we make may fail on other platforms or when versions change. Ideally we would find a way to test which does not care about field ordering: either with unit tests or some other non-functest. Alternately we could make sure to sort the output before printing, but this seems like unnecessary work just to make sure functests work. |
If we don't find a better solution (like requiring some newer lib version that guarantees stable ordering), I think sorting outselves is a good option. Nobody cares about the performance hit at this point and it would allow us to keep testing json as we migrate to GHC 9.0. It's also more usable for users.
|
Actually, it looks like |
Question: do we want to tweak the sort order so it is identical to identical to that in the tests (essentially manually defining the order: very labour intensive), or do we want a sensible order which differs from previous behaviour, like alphabetical? |
We'd prefer a sensible order, it's ok to change this.
|
Implemented in #1618. |
Thank you very much! Merging that and this, so we can now use GHC 9.0 by default. |
Update tests, stack, CI configs for GHC 9.0. Part of #1503.