odra icon indicating copy to clipboard operation
odra copied to clipboard

Make errors better

Open kubaplas opened this issue 1 year ago • 0 comments

Currently, we are catching complex errors from execution or vm and returning Odra's simplified version. For example in get_dictionary_value all serialization errors are mapped to Formatting.

Add all possible errors to odra errors, so when deserialize errors out it spews out OdraError(ExecutionError(DeserializationError(LeftOverBytes)))

Moreover, instead of copying errors into Odra, reuse them. Last error from above example should really be casper_types::bytes_repr::Error::LeftoverBytes

kubaplas avatar Apr 25 '24 13:04 kubaplas