graphql-engine/server/src-lib/Hasura/GraphQL/Transport
Samir Talwar 40617719ef server: Remove the Show instance from QErr and anything that touches it.
We only use these `Show` instances in error messages (where we call
`show` explicitly anyway) and test cases (in which Hspec requires `Show
a` for any `a` in an assertion).

This removes the instance in favor of a custom `showQErr` function
(which serializes the error to JSON). It is then used in certain error
message production which previously called `show` on a `QErr`.

There are two places where we serialize a QErr and then construct a new
QErr from the resulting string. Instead, we modify the existing QErr to
add extra information.

An orphan `Show QErr` instance is retained for tests so that we can have
nice test failure messages.

This is preparation for future changes in which the error message within
`QErr` will not be exposed directly, and therefore will not have a
`Show` instance. That said, it feels like a sensible kind of cleanup
anyway.

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4897
GitOrigin-RevId: 8f79f7a356f0aea571156f39aefac242bf751f3a
2022-07-01 11:48:26 +00:00
..
HTTP server: migrate to aeson-2 in preparation for ghc 9.2 upgrade 2022-06-08 15:32:27 +00:00
WebSocket server: GHC 9.2 changes compatible with 8.10 (#3550) 2022-06-25 22:09:05 +00:00
Backend.hs server: streaming subscriptions execution (Incremental PR - 2) 2022-04-07 14:43:01 +00:00
HTTP.hs Move Hasura.GraphQL.Parser.Column to .RQL.IR. and .GraphQL.Schema. 2022-05-30 22:07:57 +00:00
Instances.hs Rename Data Wrapper to Data Connector [GDW-89] 2022-05-02 05:04:07 +00:00
WebSocket.hs server: Remove the Show instance from QErr and anything that touches it. 2022-07-01 11:48:26 +00:00
WSServerApp.hs Remove RQL/Types.hs 2022-04-27 13:58:47 +00:00