Show full error message
- wilsonhsu0102OP
Hi team,
I was looking for a way to stop daml from truncating the error messages returned by HTTP JSON API, but I was not able to find anything.
How do we return the full message instead of having
...at the end likeFAILED_PRECONDITION: DAML_INTERPRETATION_ERROR(9,20fbbaf4): Interpretation error: Error: Unhandled Daml exception: DA.Exception.AssertionFailed:AssertionFailed@3f4deaf1{ message = "Some long error messa..." } - wilsonhsu0102
Is there currently no way to do that? Is there planned work on this?
- rohitt
Are you able to see the complete error in the logs? It should show the complete error.
- wilsonhsu0102
Even in my
log/canton.logfile it shows partial error.For more context, I am doing the following:
assertMsg ("BAD BAD BAD" <> (show <<type Daml.Finance.Interface.Types.Common.Types.AccountKey>>) <> "BAD BAD BAD") $ Falsebut I only get
"errors"=>["FAILED_PRECONDITION: DAML_INTERPRETATION_ERROR(9,ff44c698): Interpretation error: Error: Unhandled Daml exception: DA.Exception.AssertionFailed:AssertionFailed@3f4deaf1{ message = \"BAD BAD BADAccountKey {[LONG MESSAGE REDACTED]..."