tezos-base
Tezos: meta-package and pervasive type definitions for Tezos
1024" x-on:close-sidebar="sidebar=window.innerWidth > 1024 && true">
Legend:
Library
Module
Module type
Parameter
Class
Class type
Library
Module
Module type
Parameter
Class
Class type
Library tezos-base
include Tezos_error_monad.Sig.CORE with type error := unwrapped
val error_encoding : unwrapped Data_encoding.t
val pp : Format.formatter -> unwrapped -> unit
val register_error_kind :
Tezos_error_monad.Sig.error_category ->
id:string ->
title:string ->
description:string ->
?pp:( Format.formatter -> 'err -> unit ) ->
'err Data_encoding.t ->
( unwrapped -> 'err option ) ->
( 'err -> unwrapped ) ->
unit
The error data type is extensible. Each module can register specialized error serializers id
unique name of this error. Ex.: overflow_time_counter title
more readable name. Ex.: Overflow of time counter description
human readable description. Ex.: The time counter overflowed while computing delta increase pp
formatter used to pretty print additional arguments. Ex.: The time counter overflowed while computing delta increase. Previous value %d. Delta: %d encoder
decoder
data encoding for this error. If the error has no value, specify Data_encoding.empty
val classify_error : unwrapped -> Tezos_error_monad.Sig.error_category
Classify an error using the registered kinds
include Tezos_error_monad.Sig.EXT with type error := unwrapped
Catch all error when 'serializing' an error.
val json_of_error : unwrapped -> Data_encoding.json
An error serializer
val error_of_json : Data_encoding.json -> unwrapped
Error documentation
type error_info = {
category : Tezos_error_monad.Sig.error_category; |
id : string; |
title : string; |
description : string; |
schema : Data_encoding.json_schema; |
}
Error information
val pp_info : Format.formatter -> error_info -> unit
val get_registered_errors : unit -> error_info list
Retrieves information of registered errors