mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-18 13:02:11 +03:00
f01c7f4ee6
In the process of decoupling the schema parsers from the GraphQL Engine, we need to remove dependencies on `Hasura.Base.Error`. First of all, we have avoided using `QErr` in schema parsers code, instead returning a more appropriate data type which can be converted to a `Hasura.Base.Error.QErr` later. Secondly, we create a new `ParseErrorCode` type to represent parse failure types, which are then converted to a `Hasura.Base.Error.Code` later. PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5181 GitOrigin-RevId: 8655e26adb1e7d5e3d552c77a8a403f987b53467
12 lines
296 B
Haskell
12 lines
296 B
Haskell
{-# OPTIONS_GHC -Wno-orphans #-}
|
|
|
|
module Hasura.Base.Error.TestInstances () where
|
|
|
|
import Data.Text qualified as Text
|
|
import Hasura.Base.Error
|
|
import Hasura.Prelude
|
|
|
|
-- Orphan instance so that we can write assertions over 'Either QErr a'.
|
|
instance Show QErr where
|
|
show = Text.unpack . showQErr
|