package octez-protocol-017-PtNairob-libs
Install
    
    dune-project
 Dependency
Authors
Maintainers
Sources
sha256=55ea1fb8bb3273a7fc270ca8f650d45c56449665619482aad9bc12f3ea736b7e
    
    
  sha512=fec850fc2d17d7490bbabd5147d62aad13b3aaed8774270f8a38ab419670ed03e0fd30cf8642a97984eca5c2446726fe590ad99c015f7ec50919dc7652f25053
    
    
  doc/octez-protocol-017-PtNairob-libs.test-helpers/Tezos_017_PtNairob_test_helpers/Sc_rollup_helpers/index.html
Module Tezos_017_PtNairob_test_helpers.Sc_rollup_helpersSource
val originated_rollup : 
  Tezos_raw_protocol_017_PtNairob__Alpha_context.packed_operation ->
  Tezos_raw_protocol_017_PtNairob__Alpha_context.Contract.tmodule Arith_pvm : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.PVM.S
    with type context = In_memory_context.Tree.t
     and type state = In_memory_context.tree
     and type proof =
           Tezos_context_memory.Context.Proof.tree
             Tezos_context_memory.Context.Proof.tmodule Wrong_arith_pvm : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.PVM.S
    with type context = Wrong_in_memory_context.Tree.t
     and type state = Wrong_in_memory_context.tree
     and type proof =
           Tezos_context_memory.Context.Proof.tree
             Tezos_context_memory.Context.Proof.tmodule Wasm_pvm : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.PVM.S
    with type context = In_memory_context.Tree.t
     and type state = In_memory_context.tree
     and type proof =
           Tezos_context_memory.Context.Proof.tree
             Tezos_context_memory.Context.Proof.tval compute_origination_proof : 
  boot_sector:string ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Kind.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Proof.serialized
    Lwt.tval wrong_arith_origination_proof : 
  alter_binary_bit:bool ->
  boot_sector:string ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Proof.serialized
    Lwt.twrong_arith_origination_proof ~alter_binary_bit ~boot_sector returns a serialized proof computed with a Arith PVM using 32-ary trees.
If alter_binary_bit is set to true, the resulting proof lies about the arity of its trees.
val wrap_origination_proof : 
  kind:Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Kind.t ->
  boot_sector:string ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Proof.serialized
    option ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Proof.serialized
    Tezos_base.TzPervasives.tzresult
    Lwt.tval genesis_commitment : 
  boot_sector:string ->
  origination_level:Tezos_raw_protocol_017_PtNairob__Alpha_context.Raw_level.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Kind.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Commitment.t
    Lwt.tval genesis_commitment_raw : 
  boot_sector:string ->
  origination_level:
    Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollups.Kind.t ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_commitment_repr.t Lwt.tInbox message helpers.
Above Alpha_context.
val message_serialize : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox_message.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox_message.serializedval make_external_inbox_message : 
  string ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox_message.serializedval make_internal_inbox_message : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox_message.internal_inbox_message ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox_message.serializedval make_input : 
  ?inbox_level:
    Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  ?message_counter:Tezos_protocol_environment_017_PtNairob.Z.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox_message.serialized ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.inputval make_external_input : 
  ?inbox_level:
    Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  ?message_counter:Tezos_protocol_environment_017_PtNairob.Z.t ->
  string ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.inputval make_sol : 
  inbox_level:
    Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.inputval make_eol : 
  inbox_level:
    Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  message_counter:Tezos_protocol_environment_017_PtNairob.Z.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.inputval make_info_per_level : 
  inbox_level:
    Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  predecessor_timestamp:Tezos_protocol_environment_017_PtNairob.Time.t ->
  predecessor:Tezos_protocol_environment_017_PtNairob.Block_hash.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.inputval make_protocol_migration : 
  inbox_level:
    Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.inputtype message = {- input : Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.input;
- message : [ `SOL | `Info_per_level of Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Timestamp.t * Tezos_base.TzPervasives.Block_hash.t | `Message of string | `EOL ];
}Message is the combination of a message and its associated input.
message is used to:
- Construct the protocol inbox, when messageis`Message. The protocol adds`SOLand`EOLitself.
- Construct the players' inboxes.
input is used to evaluate the players' inboxes.
type payloads_per_level = {- messages : string list;(*- List of external messages. *)
- payloads : Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox_message.serialized list;(*- List of external serialized messages. *)
- predecessor_timestamp : Tezos_base.TzPervasives.Time.Protocol.t;(*- predecessor timestamp of the *)- Info_per_level.
- predecessor : Tezos_base.TzPervasives.Block_hash.t;(*- Predecessor of the *)- Info_per_level.
- level : Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.t;
- inputs : Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.input list;(*- List of all inputs for the level, to be read by a PVM. *)
}Put as much information as possible in this record so it can be used in different setups: 1. Creating an inbox on the protocol-side, requires messages only. 2. Re-construct an inbox, requires payloads, timestamp, predecessor. 3. Evaluate inputs in a PVM, requires inputs
level is useful for (1) (2) (3).
val pp_input : 
  Format.formatter ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.input ->
  unitval strs_to_inputs : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  string list ->
  message list * Tezos_protocol_environment_017_PtNairob.Z.tCreates inputs based on string messages.
val make_inputs : 
  first_block:bool ->
  Tezos_protocol_environment_017_PtNairob.Time.t ->
  Tezos_protocol_environment_017_PtNairob.Block_hash.t ->
  string list ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.input listTransform the list of all inputs the PVM should read.
val predecessor_timestamp_and_hash_from_level : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  Tezos_base.TzPervasives.Time.Protocol.t
  * Tezos_base.TzPervasives.Block_hash.tval wrap_messages : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  ?pred_info:
    (Tezos_base.TzPervasives.Time.Protocol.t
     * Tezos_base.TzPervasives.Block_hash.t) ->
  string list ->
  payloads_per_levelWrap messages, predecessor_timestamp and predecessor of a level into a payloads_per_level .
val make_empty_level : 
  ?pred_info:
    (Tezos_base.TzPervasives.Time.Protocol.t
     * Tezos_base.TzPervasives.Block_hash.t) ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  payloads_per_levelAn empty inbox level is a SOL,IPL and EOL.
val gen_messages : 
  ?pred_info:
    (Tezos_base.TzPervasives.Time.Protocol.t
     * Tezos_base.TzPervasives.Block_hash.t) ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  string QCheck2.Gen.t ->
  payloads_per_level QCheck2.Gen.tval gen_payloads_for_levels : 
  start_level:int ->
  max_level:int ->
  string QCheck2.Gen.t ->
  payloads_per_level list QCheck2.Gen.tBelow Alpha_context.
val message_serialize_repr : 
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_inbox_message_repr.t ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_inbox_message_repr.serializedval make_external_inbox_message_repr : 
  string ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_inbox_message_repr.serializedval make_internal_inbox_message_repr : 
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_inbox_message_repr.internal_inbox_message ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_inbox_message_repr.serializedval make_input_repr : 
  ?inbox_level:Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level ->
  ?message_counter:Tezos_protocol_environment_017_PtNairob.Z.t ->
  Tezos_raw_protocol_017_PtNairob.Sc_rollup_inbox_message_repr.serialized ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_PVM_sig.inputval make_external_input_repr : 
  ?inbox_level:Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level ->
  ?message_counter:Tezos_protocol_environment_017_PtNairob.Z.t ->
  string ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_PVM_sig.inputval make_sol_repr : 
  inbox_level:Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_PVM_sig.inputval make_eol_repr : 
  inbox_level:Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level ->
  message_counter:Tezos_protocol_environment_017_PtNairob.Z.t ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_PVM_sig.inputtype message_repr = {- input_repr : Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_PVM_sig.input;
- message_repr : [ `SOL | `Message of string | `EOL ];
}Message is the combination of a message and its associated input.
message is used to:
- Construct the protocol inbox, when messageis`Message. The protocol adds`SOLand`EOLitself.
- Construct the players' inboxes.
input is used to evaluate the players' inboxes.
val pp_input_repr : 
  Format.formatter ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_PVM_sig.input ->
  unitval make_empty_level_repr : 
  Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level ->
  Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level
  * message_repr listAn empty inbox level is a SOL,IPL and EOL.
val strs_to_input_reprs_repr : 
  Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level ->
  string list ->
  message_repr list * Tezos_protocol_environment_017_PtNairob.Z.tCreates input_reprs based on string message_reprs.
val wrap_message_reprs_repr : 
  Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level ->
  string list ->
  message_repr listTransform message_reprs into input_reprs and wrap them between SOL and EOL.
val gen_message_reprs_for_levels_repr : 
  start_level:int ->
  max_level:int ->
  string QCheck2.Gen.t ->
  (Tezos_protocol_017_PtNairob.Protocol.Raw_level_repr.raw_level
   * message_repr list)
    list
    QCheck2.Gen.ttype payloads_histories =
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox_merkelized_payload_hashes.History.t
    Payloads_histories.tval get_history : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox.History.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox.History.key ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox.History.value
    option
    Lwt.tval inbox_message_of_input : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.input ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.inbox_message
    optionval first_after : 
  payloads_per_level list ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.t ->
  Z.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.inbox_message
    optionval dumb_init : 
  Tezos_raw_protocol_017_PtNairob__Alpha_context.Raw_level.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox.tval dumb_init_repr : 
  Tezos_raw_protocol_017_PtNairob.Raw_level_repr.t ->
  Tezos_protocol_017_PtNairob.Protocol.Sc_rollup_inbox_repr.tval origination_op : 
  ?force_reveal:bool ->
  ?counter:Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Manager_counter.t ->
  ?fee:Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Tez.t ->
  ?gas_limit:Op.gas_limit ->
  ?storage_limit:Z.t ->
  ?origination_proof:
    Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Proof.serialized ->
  ?boot_sector:string ->
  ?parameters_ty:string ->
  Context.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Contract.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Kind.t ->
  (Tezos_protocol_017_PtNairob.Protocol.Alpha_context.packed_operation
   * Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.t)
    Tezos_base.TzPervasives.tzresult
    Lwt.tval latest_level_proof : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox.t ->
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox.Internal_for_tests.level_proofval latest_level_proof_hash : 
  Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox.t ->
  Tezos_raw_protocol_017_PtNairob__Alpha_context.Sc_rollup.Inbox_merkelized_payload_hashes.Hash.tval construct_node_and_protocol_inbox : 
  ?inbox_creation_level:
    Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Raw_level.raw_level ->
  ?genesis_predecessor_timestamp:Tezos_base.TzPervasives.Time.Protocol.t ->
  ?genesis_predecessor:Tezos_base.TzPervasives.Block_hash.t ->
  payloads_per_level list ->
  (Node_inbox.t
   * Tezos_protocol_017_PtNairob.Protocol.Alpha_context.Sc_rollup.Inbox.t,
    Tezos_base.TzPervasives.tztrace)
    result