package octez-protocol-alpha-libs

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

The baker relies on this stream to be notified of new valid blocks.

The baker relies on this stream to be notified of new heads.

Returns current and next protocol for a block.

raw_header returns the byte encoded block header of the block associated to the given block specification.

header returns the block header of the block associated to the given block specification.

resulting_context_hash returns the context resulting hash of the given block.

operations returns all operations included in the block.

inject_block_callback is called when an RPC is performed on Tezos_shell_services.Injection_services.S.block, after checking that the block header can be deserialized.

inject_operation is used by the baker (or the client) to inject operations, including attestations.

val pending_operations : unit -> mempool Lwt.t

pending_operations returns the current contents of the mempool. It is used by the baker to fetch operations to potentially include in the block being baked. These operations might include attestations. If there aren't enough attestations, the baker waits on monitor_operations.

val monitor_operations : version:Block_services.version -> validated:bool -> branch_delayed:bool -> branch_refused:bool -> refused:bool -> (Block_services.version * ((Tezos_base.TzPervasives.Operation_hash.t * Tezos_client_alpha.Mockup.M.Protocol.operation) * Tezos_base.TzPervasives.error Tezos_base.TzPervasives.trace option) list) Tezos_rpc.Answer.stream

Return a stream of list of operations. Used by the baker to wait on attestations. Invariant: the stream becomes empty when the node changes head.

Lists block hashes from the chain, up to the last checkpoint, sorted with decreasing fitness. Without arguments it returns the head of the chain. Optional arguments allow to return the list of predecessors of a given block or of a set of blocks.

List the ancestors of the given block which, if referred to as the branch in an operation header, are recent enough for that operation to be included in the current block.

rpc_context_callback is used in the implementations of several RPCs (see local_services.ml). It should correspond to the rpc_context constructed from the context at the requested block.

Return raw protocol data as a block.

Broadcast block manually to nodes dests (given by their number, starting from 0). If dests is not provided, broadcast to all nodes.

Broadcast operation manually to nodes dests (given by their number, starting from 0). If dests is not provided, broadcast to all nodes.

Simulate waiting for the node to be bootstrapped. Because the simulated node is already bootstrapped, returns the current head immediately.

OCaml

Innovation. Community. Security.