mirror of
https://github.com/digital-asset/daml.git
synced 2024-09-20 09:17:43 +03:00
Add displayException to errMessage for AssistantError wrapping (#18465)
This commit is contained in:
parent
3d2f8650b1
commit
1525ef84b2
@ -34,8 +34,8 @@ wrapErrG wrapSomeException ctx m = m `catches`
|
||||
addErrorContext err =
|
||||
err { errContext = errContext err <|> Just ctx }
|
||||
|
||||
wrapErr :: Text -> IO a -> IO a
|
||||
wrapErr = wrapErrG wrapSomeExceptionWithoutMsg
|
||||
wrapErrNoDisplay :: Text -> IO a -> IO a
|
||||
wrapErrNoDisplay = wrapErrG wrapSomeExceptionWithoutMsg
|
||||
|
||||
wrapSomeExceptionWithoutMsg :: Text -> SomeException -> AssistantError
|
||||
wrapSomeExceptionWithoutMsg ctx err =
|
||||
@ -45,8 +45,8 @@ wrapSomeExceptionWithoutMsg ctx err =
|
||||
, errInternal = Just (pack (show err))
|
||||
}
|
||||
|
||||
wrapErrDisplay :: Text -> IO a -> IO a
|
||||
wrapErrDisplay = wrapErrG wrapSomeExceptionWithMsg
|
||||
wrapErr :: Text -> IO a -> IO a
|
||||
wrapErr = wrapErrG wrapSomeExceptionWithMsg
|
||||
|
||||
wrapSomeExceptionWithMsg :: Text -> SomeException -> AssistantError
|
||||
wrapSomeExceptionWithMsg ctx err =
|
||||
|
Loading…
Reference in New Issue
Block a user