package tezos-protocol-alpha

  1. Overview
  2. Docs
Tezos/Protocol: economic-protocol definition

Install

Dune Dependency

Authors

Maintainers

Sources

tezos-16.1.tar.gz
sha256=43723d096307603703a1a89ed1b2eb202b365f5e7824b96b0cbf813b343a6cf7
sha512=b2a637f2e965000d3d49ad85277ca24d6cb07a1a7cf2bc69d296d8b03ad78c3eaa8e21e94b9162e62c2e11649cd03bc845b2a3dafe623b91065df69d47dc8e4f

doc/tezos-protocol-alpha.raw/Tezos_raw_protocol_alpha/Dal_attestation_repr/Accountability/index.html

Module Dal_attestation_repr.AccountabilitySource

This module is used to record the shard attestations.

For each attestor, a list of shards is associated. For each attested slot (see t) we record that those shards were deemed available.

This information will be used at the end of block finalisation to have the protocol declaring whether the slot is available.

Sourcetype attested_slots = t
Sourcetype t

The data-structure used to record the shards attestations.

DAL/FIXME https://gitlab.com/tezos/tezos/-/issues/3145

Consider using the Bounded module. In particular, change the semantics of is_slot_attested accordingly.

Sourceval init : length:int -> t

init ~length initialises a new accountability data-structure with at most length slots and where for every slot, no shard is available.

Sourceval record_attested_shards : t -> attested_slots -> shard_index list -> t

record_attested_shards t slots shards records that for all slots declared available in slots, the shard indices in shards are deemed available. It is the responsibility of the caller to ensure the shard indices are positive numbers. A negative shard index is ignored.

Sourceval is_slot_attested : t -> threshold:int -> number_of_shards:int -> Dal_slot_index_repr.t -> bool

is_slot_attested t ~threshold ~number_of_shards slot returns true if the number of shards recorded in t for the slot is above the threshold with respect to the total number of shards specified by number_of_shards. Returns false otherwise or if the index is out of the interval 0;length where length is the value provided to the init function.

OCaml

Innovation. Community. Security.