Skip to content

Traced_storage: fix error management

Antonio Locascio requested to merge alocascio@lts-errors into oru@main

Marked as draft until the status of !61 (closed) is cleared up. Depends on !69 (merged).

Meta-issue: tezos/tezos#1647

This MR implements the changes discussed with @galfour for error management on lib_traced_storage. There’s no big representation change: we still mostly use exceptions, but now in a more consistent manner. I’ve added some initial documentation about these exceptions to the modules’ interfaces, but this should also be well documented elsewhere. A slight change is that Bad_stream is now internal to the consume module, so that it isn’t exposed in the common interface. We also distinguish the None case in get_opt from the cases that should raise Invalid_key.

Edited by Antonio Locascio

Merge request reports