fix(users/Profpatsch/whatcd-resolver): better show ApplicationError
Change-Id: I7a1087afc4000299529a7518f273bfee8d651c72 Reviewed-on: https://cl.tvl.fyi/c/depot/+/12054 Reviewed-by: Profpatsch <mail@profpatsch.de> Tested-by: BuildkiteCI
This commit is contained in:
parent
8aa038a90e
commit
1f65a7b0d0
1 changed files with 4 additions and 2 deletions
|
@ -33,10 +33,12 @@ data Context = Context
|
|||
newtype AppT m a = AppT {unAppT :: ReaderT Context m a}
|
||||
deriving newtype (Functor, Applicative, Monad, MonadIO, MonadUnliftIO, MonadThrow)
|
||||
|
||||
data AppException = AppException Text
|
||||
deriving stock (Show)
|
||||
newtype AppException = AppException Text
|
||||
deriving anyclass (Exception)
|
||||
|
||||
instance Show AppException where
|
||||
showsPrec _ (AppException t) = ("AppException: "++) . (textToString t++)
|
||||
|
||||
-- * Logging & Opentelemetry
|
||||
|
||||
instance (MonadIO m) => MonadLogger (AppT m) where
|
||||
|
|
Loading…
Reference in a new issue