package tezos-protocol-015-PtLimaPt
Install
    
    dune-project
 Dependency
Authors
Maintainers
Sources
sha256=43723d096307603703a1a89ed1b2eb202b365f5e7824b96b0cbf813b343a6cf7
    
    
  sha512=b2a637f2e965000d3d49ad85277ca24d6cb07a1a7cf2bc69d296d8b03ad78c3eaa8e21e94b9162e62c2e11649cd03bc845b2a3dafe623b91065df69d47dc8e4f
    
    
  doc/tezos-protocol-015-PtLimaPt.raw/Tezos_raw_protocol_015_PtLimaPt/Delegate_sampler/index.html
Module Tezos_raw_protocol_015_PtLimaPt.Delegate_samplerSource
This module draws random values for a cycle based on the Seed_repr.seed associated that cycle. These random values are:
- delegates associated with slots
- snapshot indexes. The selection of delegates is done by sampling from a particular distribution of the stake among the active delegates.
This module is responsible for maintaining the table Storage.Delegate_sampler_state.
val slot_owner : 
  Raw_context.t ->
  Level_repr.t ->
  Slot_repr.t ->
  (Raw_context.t * Delegate_consensus_key.pk)
    Tezos_protocol_environment_015_PtLimaPt.Error_monad.tzresult
    Tezos_protocol_environment_015_PtLimaPt.Lwt.tParticipation slots potentially associated to accounts. The accounts that didn't place a deposit will be excluded from this list. This function should only be used to compute the deposits to freeze or initialize the protocol while stitching. RPCs can use this function to predict an approximation of long term future slot allocations. It shouldn't be used in the baker.
val baking_rights_owner : 
  Raw_context.t ->
  Level_repr.t ->
  round:Round_repr.round ->
  (Raw_context.t * Slot_repr.t * Delegate_consensus_key.pk)
    Tezos_protocol_environment_015_PtLimaPt.Error_monad.tzresult
    Tezos_protocol_environment_015_PtLimaPt.Lwt.tval compute_snapshot_index : 
  Raw_context.t ->
  Cycle_repr.t ->
  max_snapshot_index:int ->
  int Tezos_protocol_environment_015_PtLimaPt.Error_monad.tzresult
    Tezos_protocol_environment_015_PtLimaPt.Lwt.tcompute_snapshot_index ctxt cycle max_snapshot_index Returns the index of the selected snapshot for the cycle passed as argument, and for the max index of snapshots taken so far, max_snapshot_index (see Stake_storage.max_snapshot_index.
val select_new_distribution_at_cycle_end : 
  Raw_context.t ->
  new_cycle:Cycle_repr.t ->
  Raw_context.t Tezos_protocol_environment_015_PtLimaPt.Error_monad.tzresult
    Tezos_protocol_environment_015_PtLimaPt.Lwt.tval clear_outdated_sampling_data : 
  Raw_context.t ->
  new_cycle:Cycle_repr.t ->
  Raw_context.t Tezos_protocol_environment_015_PtLimaPt.Error_monad.tzresult
    Tezos_protocol_environment_015_PtLimaPt.Lwt.tval select_distribution_for_cycle : 
  Raw_context.t ->
  Cycle_repr.t ->
  Raw_context.t Tezos_protocol_environment_015_PtLimaPt.Error_monad.tzresult
    Tezos_protocol_environment_015_PtLimaPt.Lwt.t