diff --git a/src/proto_alpha/bin_sc_rollup_node/arith_pvm.ml b/src/proto_alpha/bin_sc_rollup_node/arith_pvm.ml index 8b527f9389a815f6b412055a081fa6d7b5f0c7d3..2728d785fee1c1a4a2014cb0767f55fc63c45405 100644 --- a/src/proto_alpha/bin_sc_rollup_node/arith_pvm.ml +++ b/src/proto_alpha/bin_sc_rollup_node/arith_pvm.ml @@ -68,7 +68,7 @@ module Arith_proof_format = struct kinded_hash_to_state_hash proof.IStoreProof.Proof.after let proof_encoding = - Tezos_context_helpers.Merkle_proof_encoding.V2.Tree32.tree_proof_encoding + Tezos_context_helpers.Merkle_proof_encoding.V1.Tree32.tree_proof_encoding end module Impl : Pvm.S = struct diff --git a/src/proto_alpha/bin_sc_rollup_node/components.ml b/src/proto_alpha/bin_sc_rollup_node/components.ml index e6cb34157926154f1eb8bba8abf7c7b3dd2b833f..d6066942fd9afb8663b99a1ce1b023c1e4443e9b 100644 --- a/src/proto_alpha/bin_sc_rollup_node/components.ml +++ b/src/proto_alpha/bin_sc_rollup_node/components.ml @@ -2,6 +2,7 @@ (* *) (* Open Source License *) (* Copyright (c) 2022 Nomadic Labs, *) +(* Copyright (c) 2022 Trili Tech, *) (* *) (* Permission is hereby granted, free of charge, to any person obtaining a *) (* copy of this software and associated documentation files (the "Software"),*) @@ -43,3 +44,4 @@ end let pvm_of_kind : Protocol.Alpha_context.Sc_rollup.Kind.t -> (module Pvm.S) = function | Example_arith -> (module Arith_pvm) + | Wasm_2_0_0 -> (module Wasm_2_0_0_pvm) diff --git a/src/proto_alpha/bin_sc_rollup_node/interpreter_event.ml b/src/proto_alpha/bin_sc_rollup_node/interpreter_event.ml index eecc453fd03e8b711b24556aad19cd78c96a8cef..d177dd810f3a434b18e9d3d9530a52c7894720b9 100644 --- a/src/proto_alpha/bin_sc_rollup_node/interpreter_event.ml +++ b/src/proto_alpha/bin_sc_rollup_node/interpreter_event.ml @@ -45,6 +45,7 @@ end let transitioned_pvm state num_messages = let open Lwt_syntax in + (* TODO (#3094): is this code path taken for Wasm_2_0_0_pvm. Do we need to abstract? *) let* hash = Arith_pvm.state_hash state in let* ticks = Arith_pvm.get_tick state in Simple.(emit transitioned_pvm (hash, ticks, num_messages)) diff --git a/src/proto_alpha/bin_sc_rollup_node/wasm_2_0_0_pvm.ml b/src/proto_alpha/bin_sc_rollup_node/wasm_2_0_0_pvm.ml new file mode 100644 index 0000000000000000000000000000000000000000..9bb1a26c3050ae64968321f248ea0d949864319b --- /dev/null +++ b/src/proto_alpha/bin_sc_rollup_node/wasm_2_0_0_pvm.ml @@ -0,0 +1,90 @@ +(*****************************************************************************) +(* *) +(* Open Source License *) +(* Copyright (c) 2022 TriliTech *) +(* *) +(* Permission is hereby granted, free of charge, to any person obtaining a *) +(* copy of this software and associated documentation files (the "Software"),*) +(* to deal in the Software without restriction, including without limitation *) +(* the rights to use, copy, modify, merge, publish, distribute, sublicense, *) +(* and/or sell copies of the Software, and to permit persons to whom the *) +(* Software is furnished to do so, subject to the following conditions: *) +(* *) +(* The above copyright notice and this permission notice shall be included *) +(* in all copies or substantial portions of the Software. *) +(* *) +(* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR*) +(* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, *) +(* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL *) +(* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER*) +(* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING *) +(* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER *) +(* DEALINGS IN THE SOFTWARE. *) +(* *) +(*****************************************************************************) + +open Protocol +open Alpha_context + +(** This module manifests the proof format used by the Wasm PVM as defined by + the Layer 1 implementation for it. + + It is imperative that this is aligned with the protocol's implementation. +*) +module Wasm_2_0_0_proof_format = struct + open Store + + type proof = IStoreProof.Proof.tree IStoreProof.Proof.t + + let produce_proof context tree step = + let open Lwt_syntax in + match IStoreTree.kinded_key tree with + | Some k -> + let* p = IStoreProof.produce_tree_proof (IStore.repo context) k step in + return (Some p) + | None -> return None + + let verify_proof proof step = + (* The rollup node is not supposed to verify proof. We keep + this part in case this changes in the future. *) + let open Lwt_syntax in + let* result = IStoreProof.verify_tree_proof proof step in + match result with + | Ok v -> return (Some v) + | Error _ -> + (* We skip the error analysis here since proof verification is not a + job for the rollup node. *) + return None + + let kinded_hash_to_state_hash : + IStoreProof.Proof.kinded_hash -> Sc_rollup.State_hash.t = function + | `Value hash | `Node hash -> + Sc_rollup.State_hash.hash_bytes [Context_hash.to_bytes hash] + + let proof_before proof = + kinded_hash_to_state_hash proof.IStoreProof.Proof.before + + let proof_after proof = + kinded_hash_to_state_hash proof.IStoreProof.Proof.after + + let proof_encoding = + Tezos_context_helpers.Merkle_proof_encoding.V2.Tree32.tree_proof_encoding +end + +module Impl : Pvm.S = struct + include Sc_rollup.Wasm_2_0_0PVM.Make (struct + open Store + module Tree = IStoreTree + + type tree = IStoreTree.tree + + include Wasm_2_0_0_proof_format + end) + + (* TODO: https://gitlab.com/tezos/tezos/-/issues/3093 + Print a more informative status. + *) + let string_of_status _status = "" +end + +include Impl diff --git a/src/proto_alpha/lib_protocol/TEZOS_PROTOCOL b/src/proto_alpha/lib_protocol/TEZOS_PROTOCOL index f6a0dd2487ba3c2aa6de573ba53152a347a64202..4b6fb2af4e014ff24492678cfde49c4e25c3010c 100644 --- a/src/proto_alpha/lib_protocol/TEZOS_PROTOCOL +++ b/src/proto_alpha/lib_protocol/TEZOS_PROTOCOL @@ -50,6 +50,7 @@ "Sc_rollup_outbox_message_repr", "Sc_rollup_PVM_sem", "Sc_rollup_arith", + "Sc_rollup_wasm", "Sc_rollups", "Skip_list_repr", "Sc_rollup_inbox_repr", diff --git a/src/proto_alpha/lib_protocol/alpha_context.ml b/src/proto_alpha/lib_protocol/alpha_context.ml index e3e86ad2e665d2791648f956b7292a4b26414bf0..2acb7c5fc8bff52d7370f932ce1da297ff0426a0 100644 --- a/src/proto_alpha/lib_protocol/alpha_context.ml +++ b/src/proto_alpha/lib_protocol/alpha_context.ml @@ -58,6 +58,7 @@ module Sc_rollup = struct include Sc_rollup_repr include Sc_rollup_PVM_sem module ArithPVM = Sc_rollup_arith + module Wasm_2_0_0PVM = Sc_rollup_wasm.V2_0_0 module Inbox = struct include Sc_rollup_inbox_repr diff --git a/src/proto_alpha/lib_protocol/alpha_context.mli b/src/proto_alpha/lib_protocol/alpha_context.mli index a50a584081df62f66823dd553396e441a807cc90..bf05cfa85ca42dcb9e8b998796ecee3c11897c09 100644 --- a/src/proto_alpha/lib_protocol/alpha_context.mli +++ b/src/proto_alpha/lib_protocol/alpha_context.mli @@ -2566,7 +2566,7 @@ module Sc_rollup : sig end module Kind : sig - type t = Example_arith + type t = Example_arith | Wasm_2_0_0 val encoding : t Data_encoding.t @@ -2621,6 +2621,45 @@ module Sc_rollup : sig end end + module Wasm_2_0_0PVM : sig + module type P = sig + module Tree : + Context.TREE with type key = string list and type value = bytes + + type tree = Tree.tree + + type proof + + val proof_encoding : proof Data_encoding.t + + val proof_before : proof -> State_hash.t + + val proof_after : proof -> State_hash.t + + val verify_proof : + proof -> (tree -> (tree * 'a) Lwt.t) -> (tree * 'a) option Lwt.t + + val produce_proof : + Tree.t -> + tree -> + (tree -> (tree * 'a) Lwt.t) -> + (proof * 'a) option Lwt.t + end + + module Make (C : P) : sig + include PVM.S with type context = C.Tree.t and type state = C.tree + + val get_tick : state -> Tick.t Lwt.t + + type status = Computing | WaitingForInputMessage + + val get_status : state -> status Lwt.t + + val produce_proof : + context -> input option -> state -> (proof, string) result Lwt.t + end + end + module Number_of_messages : Bounded.Int32.S module Number_of_ticks : Bounded.Int32.S @@ -2788,6 +2827,9 @@ module Sc_rollup : sig | Arith_pvm_with_proof of (module PVM_with_proof with type proof = Sc_rollup_arith.ProtocolImplementation.proof) + | Wasm_2_0_0_pvm_with_proof of + (module PVM_with_proof + with type proof = Sc_rollup_wasm.V2_0_0.ProtocolImplementation.proof) module Proof : sig type t = {pvm_step : wrapped_proof; inbox : Inbox.Proof.t option} diff --git a/src/proto_alpha/lib_protocol/dune b/src/proto_alpha/lib_protocol/dune index a4f03327ebc982ee50fb25b349d869e42ca43cd7..c51418e6a106b1732be7b60a6a985ed0d82baccb 100644 --- a/src/proto_alpha/lib_protocol/dune +++ b/src/proto_alpha/lib_protocol/dune @@ -81,6 +81,7 @@ Sc_rollup_outbox_message_repr Sc_rollup_PVM_sem Sc_rollup_arith + Sc_rollup_wasm Sc_rollups Skip_list_repr Sc_rollup_inbox_repr @@ -300,6 +301,7 @@ sc_rollup_outbox_message_repr.ml sc_rollup_outbox_message_repr.mli sc_rollup_PVM_sem.ml sc_rollup_arith.ml sc_rollup_arith.mli + sc_rollup_wasm.ml sc_rollup_wasm.mli sc_rollups.ml sc_rollups.mli skip_list_repr.ml skip_list_repr.mli sc_rollup_inbox_repr.ml sc_rollup_inbox_repr.mli @@ -506,6 +508,7 @@ sc_rollup_outbox_message_repr.ml sc_rollup_outbox_message_repr.mli sc_rollup_PVM_sem.ml sc_rollup_arith.ml sc_rollup_arith.mli + sc_rollup_wasm.ml sc_rollup_wasm.mli sc_rollups.ml sc_rollups.mli skip_list_repr.ml skip_list_repr.mli sc_rollup_inbox_repr.ml sc_rollup_inbox_repr.mli @@ -732,6 +735,7 @@ sc_rollup_outbox_message_repr.ml sc_rollup_outbox_message_repr.mli sc_rollup_PVM_sem.ml sc_rollup_arith.ml sc_rollup_arith.mli + sc_rollup_wasm.ml sc_rollup_wasm.mli sc_rollups.ml sc_rollups.mli skip_list_repr.ml skip_list_repr.mli sc_rollup_inbox_repr.ml sc_rollup_inbox_repr.mli @@ -954,6 +958,7 @@ sc_rollup_outbox_message_repr.ml sc_rollup_outbox_message_repr.mli sc_rollup_PVM_sem.ml sc_rollup_arith.ml sc_rollup_arith.mli + sc_rollup_wasm.ml sc_rollup_wasm.mli sc_rollups.ml sc_rollups.mli skip_list_repr.ml skip_list_repr.mli sc_rollup_inbox_repr.ml sc_rollup_inbox_repr.mli diff --git a/src/proto_alpha/lib_protocol/sc_rollup_wasm.ml b/src/proto_alpha/lib_protocol/sc_rollup_wasm.ml new file mode 100644 index 0000000000000000000000000000000000000000..06dd1950bbf06ccfdde78ab24dc991f4380ceff0 --- /dev/null +++ b/src/proto_alpha/lib_protocol/sc_rollup_wasm.ml @@ -0,0 +1,449 @@ +(*****************************************************************************) +(* *) +(* Open Source License *) +(* Copyright (c) 2021 Nomadic Labs *) +(* Copyright (c) 2022 Trili Tech, *) +(* *) +(* Permission is hereby granted, free of charge, to any person obtaining a *) +(* copy of this software and associated documentation files (the "Software"),*) +(* to deal in the Software without restriction, including without limitation *) +(* the rights to use, copy, modify, merge, publish, distribute, sublicense, *) +(* and/or sell copies of the Software, and to permit persons to whom the *) +(* Software is furnished to do so, subject to the following conditions: *) +(* *) +(* The above copyright notice and this permission notice shall be included *) +(* in all copies or substantial portions of the Software. *) +(* *) +(* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR*) +(* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, *) +(* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL *) +(* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER*) +(* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING *) +(* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER *) +(* DEALINGS IN THE SOFTWARE. *) +(* *) +(*****************************************************************************) + +module V2_0_0 = struct + open Sc_rollup_repr + module PS = Sc_rollup_PVM_sem + + module type P = sig + module Tree : + Context.TREE with type key = string list and type value = bytes + + type tree = Tree.tree + + type proof + + val proof_encoding : proof Data_encoding.t + + val proof_before : proof -> State_hash.t + + val proof_after : proof -> State_hash.t + + val verify_proof : + proof -> (tree -> (tree * 'a) Lwt.t) -> (tree * 'a) option Lwt.t + + val produce_proof : + Tree.t -> tree -> (tree -> (tree * 'a) Lwt.t) -> (proof * 'a) option Lwt.t + end + + module type S = sig + include Sc_rollup_PVM_sem.S + + val name : string + + val parse_boot_sector : string -> string option + + val pp_boot_sector : Format.formatter -> string -> unit + + (** [get_tick state] gets the total tick counter for the given PVM state. *) + val get_tick : state -> Sc_rollup_tick_repr.t Lwt.t + + (** PVM status *) + type status = Computing | WaitingForInputMessage + + (** [get_status state] gives you the current execution status for the PVM. *) + val get_status : state -> status Lwt.t + end + + module Make (Context : P) : + S with type context = Context.Tree.t and type state = Context.tree = struct + module Tree = Context.Tree + + type context = Context.Tree.t + + type hash = State_hash.t + + (* TODO: https://gitlab.com/tezos/tezos/-/issues/3091 + + The tree proof contains enough information to derive given and requested. + Get rid of the duplication by writing the projection functions and + removing the [given] and [requested] fields. + *) + type proof = { + tree_proof : Context.proof; + given : PS.input option; + requested : PS.input_request; + } + + let proof_input_given p = p.given + + let proof_input_requested p = p.requested + + let proof_encoding = + let open Data_encoding in + conv + (fun {tree_proof; given; requested} -> (tree_proof, given, requested)) + (fun (tree_proof, given, requested) -> {tree_proof; given; requested}) + (obj3 + (req "tree_proof" Context.proof_encoding) + (req "given" (option PS.input_encoding)) + (req "requested" PS.input_request_encoding)) + + let proof_start_state p = Context.proof_before p.tree_proof + + let proof_stop_state p = + match (p.given, p.requested) with + | None, PS.No_input_required -> Some (Context.proof_after p.tree_proof) + | None, _ -> None + | _ -> Some (Context.proof_after p.tree_proof) + + let name = "wasm_2_0_0" + + let parse_boot_sector s = Some s + + let pp_boot_sector fmt s = Format.fprintf fmt "%s" s + + type tree = Tree.tree + + type status = Computing | WaitingForInputMessage + + module State = struct + type state = tree + + module Monad : sig + type 'a t + + val run : 'a t -> state -> (state * 'a option) Lwt.t + + val return : 'a -> 'a t + + module Syntax : sig + val ( let* ) : 'a t -> ('a -> 'b t) -> 'b t + end + + val find_value : Tree.key -> 'a Data_encoding.t -> 'a option t + + val set_value : Tree.key -> 'a Data_encoding.t -> 'a -> unit t + end = struct + type 'a t = state -> (state * 'a option) Lwt.t + + let return x state = Lwt.return (state, Some x) + + let bind m f state = + let open Lwt_syntax in + let* state, res = m state in + match res with + | None -> return (state, None) + | Some res -> f res state + + module Syntax = struct + let ( let* ) = bind + end + + let run m state = m state + + let internal_error_key = ["internal_error"] + + let internal_error msg tree = + let open Lwt_syntax in + let* tree = Tree.add tree internal_error_key (Bytes.of_string msg) in + return (tree, None) + + let decode encoding bytes state = + let open Lwt_syntax in + match Data_encoding.Binary.of_bytes_opt encoding bytes with + | None -> internal_error "Error during decoding" state + | Some v -> return (state, Some v) + + let find_value key encoding state = + let open Lwt_syntax in + let* obytes = Tree.find state key in + match obytes with + | None -> return (state, Some None) + | Some bytes -> + let* state, value = decode encoding bytes state in + return (state, Some value) + + let set_value key encoding value tree = + let open Lwt_syntax in + Data_encoding.Binary.to_bytes_opt encoding value |> function + | None -> internal_error "Internal_Error during encoding" tree + | Some bytes -> + let* tree = Tree.add tree key bytes in + return (tree, Some ()) + end + + open Monad + + module MakeVar (P : sig + type t + + val name : string + + val initial : t + + val encoding : t Data_encoding.t + end) = + struct + let key = [P.name] + + let get = + let open Monad.Syntax in + let* v = find_value key P.encoding in + match v with None -> return P.initial | Some v -> return v + + let set = set_value key P.encoding + end + + module CurrentTick = MakeVar (struct + include Sc_rollup_tick_repr + + let name = "tick" + end) + + module Boot_sector = MakeVar (struct + type t = string + + let name = "boot_sector" + + let initial = "" + + let encoding = Data_encoding.string + + let _pp fmt s = Format.fprintf fmt "%s" s + end) + + module Status = MakeVar (struct + type t = status + + let initial = Computing + + let encoding = + Data_encoding.string_enum + [ + ("Computing", Computing); + ("WaitingForInputMessage", WaitingForInputMessage); + ] + + let name = "status" + + let string_of_status = function + | Computing -> "Computing" + | WaitingForInputMessage -> "WaitingForInputMessage" + + let _pp fmt status = Format.fprintf fmt "%s" (string_of_status status) + end) + + module CurrentLevel = MakeVar (struct + type t = Raw_level_repr.t + + let initial = Raw_level_repr.root + + let encoding = Raw_level_repr.encoding + + let name = "current_level" + + let _pp = Raw_level_repr.pp + end) + + module MessageCounter = MakeVar (struct + type t = Z.t option + + let initial = None + + let encoding = Data_encoding.option Data_encoding.n + + let name = "message_counter" + + let _pp fmt = function + | None -> Format.fprintf fmt "None" + | Some c -> Format.fprintf fmt "Some %a" Z.pp_print c + end) + + module NextMessage = MakeVar (struct + type t = string option + + let initial = None + + let encoding = Data_encoding.(option string) + + let name = "next_message" + + let _pp fmt = function + | None -> Format.fprintf fmt "None" + | Some s -> Format.fprintf fmt "Some %s" s + end) + end + + open State + + type state = State.state + + open Monad + + let initial_state ctxt _boot_sector = + let state = Tree.empty ctxt in + Lwt.return state + + let state_hash state = + let m = + let open Monad.Syntax in + let* status = Status.get in + match status with + | _ -> + Context_hash.to_bytes @@ Tree.hash state |> fun h -> + return @@ State_hash.hash_bytes [h] + in + let open Lwt_syntax in + let* state = Monad.run m state in + match state with + | _, Some hash -> return hash + | _ -> (* Hash computation always succeeds. *) assert false + + let result_of ~default m state = + let open Lwt_syntax in + let* _, v = run m state in + match v with None -> return default | Some v -> return v + + let state_of m state = + let open Lwt_syntax in + let* s, _ = run m state in + return s + + let get_tick = + result_of ~default:Sc_rollup_tick_repr.initial CurrentTick.get + + let is_input_state_monadic = + let open Monad.Syntax in + let* status = Status.get in + match status with + (* TODO: https://gitlab.com/tezos/tezos/-/issues/3092 + + Implement handling of input logic. + *) + | WaitingForInputMessage -> ( + let* level = CurrentLevel.get in + let* counter = MessageCounter.get in + match counter with + | Some n -> return (PS.First_after (level, n)) + | None -> return PS.Initial) + | _ -> return PS.No_input_required + + let is_input_state = + result_of ~default:PS.No_input_required @@ is_input_state_monadic + + let get_status = result_of ~default:Computing @@ Status.get + + let set_input_monadic input = + let open PS in + let {inbox_level; message_counter; payload} = input in + let open Monad.Syntax in + let* boot_sector = Boot_sector.get in + let msg = boot_sector ^ payload in + let* () = CurrentLevel.set inbox_level in + let* () = MessageCounter.set (Some message_counter) in + let* () = NextMessage.set (Some msg) in + return () + + let set_input input = state_of @@ set_input_monadic input + + let reboot = return () + + let eval_step = + (* TODO: https://gitlab.com/tezos/tezos/-/issues/3090 + + Call into tickified parsing/evaluation exposed in lib_webassembly. + *) + reboot + + let ticked m = + let open Monad.Syntax in + let* tick = CurrentTick.get in + let* () = CurrentTick.set (Sc_rollup_tick_repr.next tick) in + m + + let eval state = state_of (ticked eval_step) state + + let step_transition input_given state = + let open Lwt_syntax in + let* request = is_input_state state in + let* state = + match request with + | PS.No_input_required -> eval state + | _ -> ( + match input_given with + | Some input -> set_input input state + | None -> return state) + in + return (state, request) + + let verify_proof proof = + let open Lwt_syntax in + let* result = + Context.verify_proof proof.tree_proof (step_transition proof.given) + in + match result with + | None -> return false + | Some (_, request) -> + return (PS.input_request_equal request proof.requested) + + let produce_proof context input_given state = + let open Lwt_syntax in + let* result = + Context.produce_proof context state (step_transition input_given) + in + match result with + | Some (tree_proof, requested) -> + return (Result.ok {tree_proof; given = input_given; requested}) + | None -> return (Result.error "Context.produce_proof returned None") + end + + module ProtocolImplementation = Make (struct + module Tree = struct + include Context.Tree + + type tree = Context.tree + + type t = Context.t + + type key = string list + + type value = bytes + end + + type tree = Context.tree + + type proof = Context.Proof.tree Context.Proof.t + + let verify_proof p f = + Lwt.map Result.to_option (Context.verify_tree_proof p f) + + let produce_proof _context _state _f = + (* Can't produce proof without full context*) + Lwt.return None + + let kinded_hash_to_state_hash = function + | `Value hash | `Node hash -> + State_hash.hash_bytes [Context_hash.to_bytes hash] + + let proof_before proof = + kinded_hash_to_state_hash proof.Context.Proof.before + + let proof_after proof = kinded_hash_to_state_hash proof.Context.Proof.after + + let proof_encoding = Context.Proof_encoding.V1.Tree32.tree_proof_encoding + end) +end diff --git a/src/proto_alpha/lib_protocol/sc_rollup_wasm.mli b/src/proto_alpha/lib_protocol/sc_rollup_wasm.mli new file mode 100644 index 0000000000000000000000000000000000000000..8d62fe9e1efbd894af75250de98d66e6da5fa189 --- /dev/null +++ b/src/proto_alpha/lib_protocol/sc_rollup_wasm.mli @@ -0,0 +1,87 @@ +(*****************************************************************************) +(* *) +(* Open Source License *) +(* Copyright (c) 2021 Nomadic Labs *) +(* Copyright (c) 2022 Trili Tech, *) +(* *) +(* Permission is hereby granted, free of charge, to any person obtaining a *) +(* copy of this software and associated documentation files (the "Software"),*) +(* to deal in the Software without restriction, including without limitation *) +(* the rights to use, copy, modify, merge, publish, distribute, sublicense, *) +(* and/or sell copies of the Software, and to permit persons to whom the *) +(* Software is furnished to do so, subject to the following conditions: *) +(* *) +(* The above copyright notice and this permission notice shall be included *) +(* in all copies or substantial portions of the Software. *) +(* *) +(* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR*) +(* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, *) +(* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL *) +(* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER*) +(* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING *) +(* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER *) +(* DEALINGS IN THE SOFTWARE. *) +(* *) +(*****************************************************************************) + +module V2_0_0 : sig + (** This module provides Proof-Generating Virtual Machine (PVM) running + WebAssembly (version 2.0.0). *) + + module type S = sig + include Sc_rollup_PVM_sem.S + + (** [name] is "wasm_2_0_0". + + WebAssembly is an "evergreen" specification. We aim to track + the latest major version, 2.0 at the time of writing. We + use the minor version number to track changes to our fork. + *) + val name : string + + (** [parse_boot_sector s] builds a boot sector from its human + writable description. *) + val parse_boot_sector : string -> string option + + (** [pp_boot_sector fmt s] prints a human readable representation of + a boot sector. *) + val pp_boot_sector : Format.formatter -> string -> unit + + (* Required by L2 node: *) + + (** [get_tick state] gets the total tick counter for the given PVM state. *) + val get_tick : state -> Sc_rollup_tick_repr.t Lwt.t + + (** PVM status *) + type status = Computing | WaitingForInputMessage + + (** [get_status state] gives you the current execution status for the PVM. *) + val get_status : state -> status Lwt.t + end + + module ProtocolImplementation : S with type context = Context.t + + module type P = sig + module Tree : + Context.TREE with type key = string list and type value = bytes + + type tree = Tree.tree + + type proof + + val proof_encoding : proof Data_encoding.t + + val proof_before : proof -> Sc_rollup_repr.State_hash.t + + val proof_after : proof -> Sc_rollup_repr.State_hash.t + + val verify_proof : + proof -> (tree -> (tree * 'a) Lwt.t) -> (tree * 'a) option Lwt.t + + val produce_proof : + Tree.t -> tree -> (tree -> (tree * 'a) Lwt.t) -> (proof * 'a) option Lwt.t + end + + module Make (Context : P) : + S with type context = Context.Tree.t and type state = Context.tree +end diff --git a/src/proto_alpha/lib_protocol/sc_rollups.ml b/src/proto_alpha/lib_protocol/sc_rollups.ml index 124ce772d627ed061df1a4546f20b290c20d68fa..b43c26a5be005b58e103010caa314a028640a18b 100644 --- a/src/proto_alpha/lib_protocol/sc_rollups.ml +++ b/src/proto_alpha/lib_protocol/sc_rollups.ml @@ -2,6 +2,7 @@ (* *) (* Open Source License *) (* Copyright (c) 2021 Nomadic Labs *) +(* Copyright (c) 2022 Trili Tech, *) (* *) (* Permission is hereby granted, free of charge, to any person obtaining a *) (* copy of this software and associated documentation files (the "Software"),*) @@ -41,14 +42,13 @@ end module Kind = struct (* - Each time we add a data constructor to [t], we also need: - to extend [Sc_rollups.all] with this new constructor ; - to update [Sc_rollups.of_name] and [encoding] ; - to update [Sc_rollups.wrapped_proof] and [wrapped_proof_encoding]. *) - type t = Example_arith + type t = Example_arith | Wasm_2_0_0 let example_arith_case = Data_encoding.( @@ -56,21 +56,43 @@ module Kind = struct ~title:"Example_arith smart contract rollup kind" (Tag 0) unit - (function Example_arith -> Some ()) + (function Example_arith -> Some () | _ -> None) (fun () -> Example_arith)) - let encoding = Data_encoding.union ~tag_size:`Uint16 [example_arith_case] + let wasm_2_0_0_case = + Data_encoding.( + case + ~title:"Wasm 2.0.0 smart contract rollup kind" + (Tag 1) + unit + (function Wasm_2_0_0 -> Some () | _ -> None) + (fun () -> Wasm_2_0_0)) + + let encoding = + Data_encoding.union ~tag_size:`Uint16 [example_arith_case; wasm_2_0_0_case] - let equal x y = match (x, y) with Example_arith, Example_arith -> true + let equal x y = + match (x, y) with + | Example_arith, Example_arith -> true + | Wasm_2_0_0, Wasm_2_0_0 -> true + | _ -> false - let all = [Example_arith] + let all = [Example_arith; Wasm_2_0_0] - let of_name = function "arith" -> Some Example_arith | _ -> None + let of_name = function + | "arith" -> Some Example_arith + | "wasm_2_0_0" -> Some Wasm_2_0_0 + | _ -> None let example_arith_pvm = (module Sc_rollup_arith.ProtocolImplementation : PVM.S) - let pvm_of = function Example_arith -> example_arith_pvm + let wasm_2_0_0_pvm = + (module Sc_rollup_wasm.V2_0_0.ProtocolImplementation : PVM.S) + + let pvm_of = function + | Example_arith -> example_arith_pvm + | Wasm_2_0_0 -> wasm_2_0_0_pvm let of_pvm (module M : PVM.S) = match of_name M.name with @@ -108,6 +130,9 @@ type wrapped_proof = | Arith_pvm_with_proof of (module PVM_with_proof with type proof = Sc_rollup_arith.ProtocolImplementation.proof) + | Wasm_2_0_0_pvm_with_proof of + (module PVM_with_proof + with type proof = Sc_rollup_wasm.V2_0_0.ProtocolImplementation.proof) let wrapped_proof_module p = match p with @@ -117,6 +142,11 @@ let wrapped_proof_module p = (module struct include P end : PVM_with_proof) + | Wasm_2_0_0_pvm_with_proof p -> + let (module P) = p in + (module struct + include P + end : PVM_with_proof) let wrapped_proof_encoding = let open Data_encoding in @@ -143,6 +173,26 @@ let wrapped_proof_encoding = let proof = proof end in Arith_pvm_with_proof (module P)); + case + ~title:"Wasm 2.0.0 PVM with proof" + (Tag 1) + Sc_rollup_wasm.V2_0_0.ProtocolImplementation.proof_encoding + (function + | Wasm_2_0_0_pvm_with_proof pvm -> + let (module P : PVM_with_proof + with type proof = + Sc_rollup_wasm.V2_0_0.ProtocolImplementation.proof) = + pvm + in + Some P.proof + | _ -> None) + (fun proof -> + let module P = struct + include Sc_rollup_wasm.V2_0_0.ProtocolImplementation + + let proof = proof + end in + Wasm_2_0_0_pvm_with_proof (module P)); ] let wrap_proof pvm_with_proof = @@ -164,3 +214,18 @@ let wrap_proof pvm_with_proof = Data_encoding.Binary.of_bytes_opt Sc_rollup_arith.ProtocolImplementation.proof_encoding bytes)) + | Some Kind.Wasm_2_0_0 -> + Option.map + (fun wasm_proof -> + let module P_wasm2_0_0 = struct + include Sc_rollup_wasm.V2_0_0.ProtocolImplementation + + let proof = wasm_proof + end in + Wasm_2_0_0_pvm_with_proof (module P_wasm2_0_0)) + (Option.bind + (Data_encoding.Binary.to_bytes_opt P.proof_encoding P.proof) + (fun bytes -> + Data_encoding.Binary.of_bytes_opt + Sc_rollup_wasm.V2_0_0.ProtocolImplementation.proof_encoding + bytes)) diff --git a/src/proto_alpha/lib_protocol/sc_rollups.mli b/src/proto_alpha/lib_protocol/sc_rollups.mli index b8221904b0810405d296144cc2e24f175ca14e19..81ec833da0ab9a2c24de9c31fdae6993452e374c 100644 --- a/src/proto_alpha/lib_protocol/sc_rollups.mli +++ b/src/proto_alpha/lib_protocol/sc_rollups.mli @@ -2,6 +2,7 @@ (* *) (* Open Source License *) (* Copyright (c) 2021 Nomadic Labs *) +(* Copyright (c) 2022 Trili Tech, *) (* *) (* Permission is hereby granted, free of charge, to any person obtaining a *) (* copy of this software and associated documentation files (the "Software"),*) @@ -50,7 +51,7 @@ module Kind : sig This list must only be appended for backward compatibility. *) - type t = Example_arith + type t = Example_arith | Wasm_2_0_0 val encoding : t Data_encoding.t @@ -98,6 +99,9 @@ type wrapped_proof = | Arith_pvm_with_proof of (module PVM_with_proof with type proof = Sc_rollup_arith.ProtocolImplementation.proof) + | Wasm_2_0_0_pvm_with_proof of + (module PVM_with_proof + with type proof = Sc_rollup_wasm.V2_0_0.ProtocolImplementation.proof) (** Unwrap a [wrapped_proof] into a first-class module. *) val wrapped_proof_module : wrapped_proof -> (module PVM_with_proof) diff --git a/src/proto_alpha/lib_protocol/test/integration/operations/test_sc_rollup.ml b/src/proto_alpha/lib_protocol/test/integration/operations/test_sc_rollup.ml index d42e3c1e2d5688663f3c0c03e6f732b64c23131c..62eae97382e604d981a8fd317518e33cdac4e1cc 100644 --- a/src/proto_alpha/lib_protocol/test/integration/operations/test_sc_rollup.ml +++ b/src/proto_alpha/lib_protocol/test/integration/operations/test_sc_rollup.ml @@ -2,6 +2,7 @@ (* *) (* Open Source License *) (* Copyright (c) 2022 Nomadic Labs *) +(* Copyright (c) 2022 Trili Tech, *) (* *) (* Permission is hereby granted, free of charge, to any person obtaining a *) (* copy of this software and associated documentation files (the "Software"),*) @@ -99,25 +100,9 @@ let test_disable_feature_flag () = let*! _ = Incremental.add_operation ~expect_apply_failure i op in return_unit -(** [test_sc_rollups_all_well_defined] checks that [Sc_rollup.Kind.all] - contains all the constructors of [Sc_rollup.Kind.t] and that the - [of_name] is consistent with the names declared in the PVM - implementations. *) +(** [test_sc_rollups_all_well_defined] checks that the [kind_of_string] is + consistent with the names declared in the PVM implementations. *) let test_sc_rollups_all_well_defined () = - let all_contains_all_constructors () = - let tickets = ref ["Example_arith"] in - let burn x = tickets := List.filter (( <> ) x) !tickets in - let pick = function - | Sc_rollup.Kind.Example_arith -> burn "Example_arith" - in - List.iter pick Sc_rollup.Kind.all ; - if !tickets <> [] then - failwith - "The following smart-contract rollup kinds should occur in \ - [Sc_rollup.Kind.all]: %s\n" - (String.concat ", " !tickets) - else return_unit - in let all_names_are_valid () = List.iter_es (fun k -> @@ -127,7 +112,6 @@ let test_sc_rollups_all_well_defined () = (err (Printf.sprintf "PVM name `%s' is not a valid kind name" P.name))) Sc_rollup.Kind.all in - let* _ = all_contains_all_constructors () in all_names_are_valid () (** Initializes the context and originates a SCORU. *) diff --git a/tezt/tests/expected/RPC_test.ml/Alpha- (mode client) RPC regression tests- mempool.out b/tezt/tests/expected/RPC_test.ml/Alpha- (mode client) RPC regression tests- mempool.out index a7cc3cb3d923bfa41163900949098971653b7efd..57487190d745f23ad04da3a1bfa97e049a67b394 100644 --- a/tezt/tests/expected/RPC_test.ml/Alpha- (mode client) RPC regression tests- mempool.out +++ b/tezt/tests/expected/RPC_test.ml/Alpha- (mode client) RPC regression tests- mempool.out @@ -3096,6 +3096,9 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "oneOf": [ { "title": "Example_arith smart contract rollup kind" + }, + { + "title": "Wasm 2.0.0 smart contract rollup kind" } ] }, @@ -4235,213 +4238,12 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "tree_proof" ], "additionalProperties": false - } - ] - }, - "inbox": { - "oneOf": [ + }, { - "title": "Some", + "title": "Wasm 2.0.0 PVM with proof", "type": "object", "properties": { - "skips": { - "type": "array", - "items": { - "type": "array", - "items": [ - { - "type": "object", - "properties": { - "rollup": { - "$ref": "#/definitions/alpha.rollup_address" - }, - "message_counter": { - "$ref": "#/definitions/positive_bignum" - }, - "nb_available_messages": { - "$ref": "#/definitions/int64" - }, - "nb_messages_in_commitment_period": { - "$ref": "#/definitions/int64" - }, - "starting_level_of_current_commitment_period": { - "type": "integer", - "minimum": -2147483648, - "maximum": 2147483647 - }, - "level": { - "type": "integer", - "minimum": -2147483648, - "maximum": 2147483647 - }, - "current_messages_hash": { - "$ref": "#/definitions/inbox_hash" - }, - "old_levels_messages": { - "type": "object", - "properties": { - "index": { - "type": "integer", - "minimum": -1073741824, - "maximum": 1073741823 - }, - "content": { - "$ref": "#/definitions/inbox_hash" - }, - "back_pointers": { - "type": "array", - "items": { - "$ref": "#/definitions/inbox_hash" - } - } - }, - "required": [ - "back_pointers", - "content", - "index" - ], - "additionalProperties": false - } - }, - "required": [ - "old_levels_messages", - "current_messages_hash", - "level", - "starting_level_of_current_commitment_period", - "nb_messages_in_commitment_period", - "nb_available_messages", - "message_counter", - "rollup" - ], - "additionalProperties": false - }, - { - "type": "array", - "items": { - "type": "object", - "properties": { - "index": { - "type": "integer", - "minimum": -1073741824, - "maximum": 1073741823 - }, - "content": { - "$ref": "#/definitions/inbox_hash" - }, - "back_pointers": { - "type": "array", - "items": { - "$ref": "#/definitions/inbox_hash" - } - } - }, - "required": [ - "back_pointers", - "content", - "index" - ], - "additionalProperties": false - } - } - ], - "additionalItems": false - } - }, - "level": { - "type": "object", - "properties": { - "rollup": { - "$ref": "#/definitions/alpha.rollup_address" - }, - "message_counter": { - "$ref": "#/definitions/positive_bignum" - }, - "nb_available_messages": { - "$ref": "#/definitions/int64" - }, - "nb_messages_in_commitment_period": { - "$ref": "#/definitions/int64" - }, - "starting_level_of_current_commitment_period": { - "type": "integer", - "minimum": -2147483648, - "maximum": 2147483647 - }, - "level": { - "type": "integer", - "minimum": -2147483648, - "maximum": 2147483647 - }, - "current_messages_hash": { - "$ref": "#/definitions/inbox_hash" - }, - "old_levels_messages": { - "type": "object", - "properties": { - "index": { - "type": "integer", - "minimum": -1073741824, - "maximum": 1073741823 - }, - "content": { - "$ref": "#/definitions/inbox_hash" - }, - "back_pointers": { - "type": "array", - "items": { - "$ref": "#/definitions/inbox_hash" - } - } - }, - "required": [ - "back_pointers", - "content", - "index" - ], - "additionalProperties": false - } - }, - "required": [ - "old_levels_messages", - "current_messages_hash", - "level", - "starting_level_of_current_commitment_period", - "nb_messages_in_commitment_period", - "nb_available_messages", - "message_counter", - "rollup" - ], - "additionalProperties": false - }, - "inc": { - "type": "array", - "items": { - "type": "object", - "properties": { - "index": { - "type": "integer", - "minimum": -1073741824, - "maximum": 1073741823 - }, - "content": { - "$ref": "#/definitions/inbox_hash" - }, - "back_pointers": { - "type": "array", - "items": { - "$ref": "#/definitions/inbox_hash" - } - } - }, - "required": [ - "back_pointers", - "content", - "index" - ], - "additionalProperties": false - } - }, - "message_proof": { + "tree_proof": { "type": "object", "properties": { "version": { @@ -5163,54 +4965,1062 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "version" ], "additionalProperties": false - } - }, - "required": [ - "message_proof", - "inc", - "level", - "skips" - ], - "additionalProperties": false - }, - { - "title": "None", - "type": "null" - } - ] - } - }, - "required": [ - "inbox", - "pvm_step" - ], - "additionalProperties": false - } - ] - } - }, - "required": [ - "step", - "choice" - ], - "additionalProperties": false - }, - "is_opening_move": { - "type": "boolean" - } - }, - "required": [ - "is_opening_move", - "refutation", - "opponent", - "rollup", - "storage_limit", - "gas_limit", - "counter", - "fee", - "source", - "kind" - ], + }, + "given": { + "oneOf": [ + { + "title": "Some", + "type": "object", + "properties": { + "inbox_level": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "message_counter": { + "$ref": "#/definitions/positive_bignum" + }, + "payload": { + "$ref": "#/definitions/unistring" + } + }, + "required": [ + "payload", + "message_counter", + "inbox_level" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "null" + } + ] + }, + "requested": { + "oneOf": [ + { + "title": "No_input_required", + "type": "object", + "properties": { + "no_input_required": {} + }, + "required": [ + "no_input_required" + ], + "additionalProperties": false + }, + { + "title": "Initial", + "type": "object", + "properties": { + "initial": {} + }, + "required": [ + "initial" + ], + "additionalProperties": false + }, + { + "title": "First_after", + "type": "array", + "items": [ + { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + { + "$ref": "#/definitions/positive_bignum" + } + ], + "additionalItems": false + } + ] + } + }, + "required": [ + "requested", + "given", + "tree_proof" + ], + "additionalProperties": false + } + ] + }, + "inbox": { + "oneOf": [ + { + "title": "Some", + "type": "object", + "properties": { + "skips": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "object", + "properties": { + "rollup": { + "$ref": "#/definitions/alpha.rollup_address" + }, + "message_counter": { + "$ref": "#/definitions/positive_bignum" + }, + "nb_available_messages": { + "$ref": "#/definitions/int64" + }, + "nb_messages_in_commitment_period": { + "$ref": "#/definitions/int64" + }, + "starting_level_of_current_commitment_period": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "level": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "current_messages_hash": { + "$ref": "#/definitions/inbox_hash" + }, + "old_levels_messages": { + "type": "object", + "properties": { + "index": { + "type": "integer", + "minimum": -1073741824, + "maximum": 1073741823 + }, + "content": { + "$ref": "#/definitions/inbox_hash" + }, + "back_pointers": { + "type": "array", + "items": { + "$ref": "#/definitions/inbox_hash" + } + } + }, + "required": [ + "back_pointers", + "content", + "index" + ], + "additionalProperties": false + } + }, + "required": [ + "old_levels_messages", + "current_messages_hash", + "level", + "starting_level_of_current_commitment_period", + "nb_messages_in_commitment_period", + "nb_available_messages", + "message_counter", + "rollup" + ], + "additionalProperties": false + }, + { + "type": "array", + "items": { + "type": "object", + "properties": { + "index": { + "type": "integer", + "minimum": -1073741824, + "maximum": 1073741823 + }, + "content": { + "$ref": "#/definitions/inbox_hash" + }, + "back_pointers": { + "type": "array", + "items": { + "$ref": "#/definitions/inbox_hash" + } + } + }, + "required": [ + "back_pointers", + "content", + "index" + ], + "additionalProperties": false + } + } + ], + "additionalItems": false + } + }, + "level": { + "type": "object", + "properties": { + "rollup": { + "$ref": "#/definitions/alpha.rollup_address" + }, + "message_counter": { + "$ref": "#/definitions/positive_bignum" + }, + "nb_available_messages": { + "$ref": "#/definitions/int64" + }, + "nb_messages_in_commitment_period": { + "$ref": "#/definitions/int64" + }, + "starting_level_of_current_commitment_period": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "level": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "current_messages_hash": { + "$ref": "#/definitions/inbox_hash" + }, + "old_levels_messages": { + "type": "object", + "properties": { + "index": { + "type": "integer", + "minimum": -1073741824, + "maximum": 1073741823 + }, + "content": { + "$ref": "#/definitions/inbox_hash" + }, + "back_pointers": { + "type": "array", + "items": { + "$ref": "#/definitions/inbox_hash" + } + } + }, + "required": [ + "back_pointers", + "content", + "index" + ], + "additionalProperties": false + } + }, + "required": [ + "old_levels_messages", + "current_messages_hash", + "level", + "starting_level_of_current_commitment_period", + "nb_messages_in_commitment_period", + "nb_available_messages", + "message_counter", + "rollup" + ], + "additionalProperties": false + }, + "inc": { + "type": "array", + "items": { + "type": "object", + "properties": { + "index": { + "type": "integer", + "minimum": -1073741824, + "maximum": 1073741823 + }, + "content": { + "$ref": "#/definitions/inbox_hash" + }, + "back_pointers": { + "type": "array", + "items": { + "$ref": "#/definitions/inbox_hash" + } + } + }, + "required": [ + "back_pointers", + "content", + "index" + ], + "additionalProperties": false + } + }, + "message_proof": { + "type": "object", + "properties": { + "version": { + "type": "integer", + "minimum": -32768, + "maximum": 32767 + }, + "before": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "node" + ], + "additionalProperties": false + } + ] + }, + "after": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "node" + ], + "additionalProperties": false + } + ] + }, + "state": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Blinded_value", + "type": "object", + "properties": { + "blinded_value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "node" + ], + "additionalProperties": false + }, + { + "title": "Blinded_node", + "type": "object", + "properties": { + "blinded_node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_node" + ], + "additionalProperties": false + }, + { + "title": "Inode", + "type": "object", + "properties": { + "inode": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode" + ], + "additionalProperties": false + }, + { + "title": "Extender", + "type": "object", + "properties": { + "extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "state", + "after", + "before", + "version" + ], + "additionalProperties": false + } + }, + "required": [ + "message_proof", + "inc", + "level", + "skips" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "null" + } + ] + } + }, + "required": [ + "inbox", + "pvm_step" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "step", + "choice" + ], + "additionalProperties": false + }, + "is_opening_move": { + "type": "boolean" + } + }, + "required": [ + "is_opening_move", + "refutation", + "opponent", + "rollup", + "storage_limit", + "gas_limit", + "counter", + "fee", + "source", + "kind" + ], "additionalProperties": false }, { @@ -7335,7 +8145,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "parameters", "layout": { - "name": "X_1777", + "name": "X_2590", "kind": "Ref" }, "data_kind": { @@ -8000,7 +8810,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "commitment", "layout": { - "name": "X_1775", + "name": "X_2588", "kind": "Ref" }, "data_kind": { @@ -8363,7 +9173,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "message", "layout": { - "name": "X_1648", + "name": "X_2461", "kind": "Ref" }, "data_kind": { @@ -8432,7 +9242,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "previous_message_result", "layout": { - "name": "X_1649", + "name": "X_2462", "kind": "Ref" }, "data_kind": { @@ -8462,7 +9272,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "proof", "layout": { - "name": "X_1774", + "name": "X_2587", "kind": "Ref" }, "data_kind": { @@ -8618,7 +9428,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "tickets_info", "layout": { "layout": { - "name": "X_1644", + "name": "X_2457", "kind": "Ref" }, "kind": "Seq" @@ -8859,7 +9669,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "kind", "layout": { - "name": "X_1643", + "name": "X_2456", "kind": "Ref" }, "data_kind": { @@ -8997,7 +9807,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "message", "layout": { "layout": { - "name": "X_1642", + "name": "X_2455", "kind": "Ref" }, "kind": "Seq" @@ -9201,7 +10011,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "commitment", "layout": { - "name": "X_1641", + "name": "X_2454", "kind": "Ref" }, "data_kind": { @@ -10374,7 +11184,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1777" + "title": "X_2590" }, "encoding": { "fields": [ @@ -10717,7 +11527,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1775" + "title": "X_2588" }, "encoding": { "fields": [ @@ -10754,7 +11564,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "predecessor", "layout": { - "name": "X_1776", + "name": "X_2589", "kind": "Ref" }, "data_kind": { @@ -10778,7 +11588,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1776" + "title": "X_2589" }, "encoding": { "tag_size": "Uint8", @@ -10848,7 +11658,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1774" + "title": "X_2587" }, "encoding": { "tag_size": "Uint8", @@ -10904,7 +11714,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1650", + "name": "X_2463", "kind": "Ref" }, "kind": "anon", @@ -10963,7 +11773,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1650", + "name": "X_2463", "kind": "Ref" }, "kind": "anon", @@ -11022,7 +11832,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1650", + "name": "X_2463", "kind": "Ref" }, "kind": "anon", @@ -11081,7 +11891,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1650", + "name": "X_2463", "kind": "Ref" }, "kind": "anon", @@ -11097,7 +11907,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1773" + "title": "X_2586" }, "encoding": { "tag_size": "Uint8", @@ -11133,7 +11943,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1772", + "name": "X_2585", "kind": "Ref" }, "kind": "anon", @@ -11173,7 +11983,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1772", + "name": "X_2585", "kind": "Ref" }, "kind": "anon", @@ -11213,7 +12023,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1772", + "name": "X_2585", "kind": "Ref" }, "kind": "anon", @@ -11253,7 +12063,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1772", + "name": "X_2585", "kind": "Ref" }, "kind": "anon", @@ -11293,7 +12103,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11333,7 +12143,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11373,7 +12183,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11413,7 +12223,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11453,7 +12263,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11493,7 +12303,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11533,7 +12343,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11573,7 +12383,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11613,7 +12423,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1760", + "name": "X_2573", "kind": "Ref" }, "kind": "anon", @@ -11653,7 +12463,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1760", + "name": "X_2573", "kind": "Ref" }, "kind": "anon", @@ -11693,7 +12503,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1760", + "name": "X_2573", "kind": "Ref" }, "kind": "anon", @@ -11733,7 +12543,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1760", + "name": "X_2573", "kind": "Ref" }, "kind": "anon", @@ -11791,7 +12601,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1655", + "name": "X_2468", "kind": "Ref" }, "kind": "Seq", @@ -11826,7 +12636,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1655", + "name": "X_2468", "kind": "Ref" }, "kind": "Seq", @@ -11866,7 +12676,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1655", + "name": "X_2468", "kind": "Ref" }, "kind": "Seq" @@ -12003,7 +12813,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12052,7 +12862,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12101,7 +12911,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12150,7 +12960,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12176,7 +12986,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1772" + "title": "X_2585" }, "encoding": { "fields": [] @@ -12184,7 +12994,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1768" + "title": "X_2581" }, "encoding": { "fields": [ @@ -12203,7 +13013,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1760" + "title": "X_2573" }, "encoding": { "fields": [ @@ -12232,7 +13042,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1756" + "title": "X_2569" }, "encoding": { "tag_size": "Uint8", @@ -12304,7 +13114,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1755" + "title": "X_2568" }, "encoding": { "fields": [ @@ -12327,7 +13137,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1650" + "title": "X_2463" }, "encoding": { "fields": [ @@ -12339,7 +13149,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1773", + "name": "X_2586", "kind": "Ref" }, "kind": "Seq" @@ -12354,13 +13164,13 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1655" + "title": "X_2468" }, "encoding": { "fields": [ { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12370,7 +13180,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1756", + "name": "X_2569", "kind": "Ref" }, "kind": "anon", @@ -12384,7 +13194,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1649" + "title": "X_2462" }, "encoding": { "fields": [ @@ -12415,7 +13225,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1648" + "title": "X_2461" }, "encoding": { "tag_size": "Uint8", @@ -12474,7 +13284,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "deposit", "layout": { - "name": "X_1646", + "name": "X_2459", "kind": "Ref" }, "data_kind": { @@ -12490,7 +13300,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1646" + "title": "X_2459" }, "encoding": { "fields": [ @@ -12531,7 +13341,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "amount", "layout": { - "name": "X_1647", + "name": "X_2460", "kind": "Ref" }, "data_kind": { @@ -12544,7 +13354,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1647" + "title": "X_2460" }, "encoding": { "tag_size": "Uint8", @@ -12673,7 +13483,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1644" + "title": "X_2457" }, "encoding": { "fields": [ @@ -12722,7 +13532,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "amount", "layout": { - "name": "X_1647", + "name": "X_2460", "kind": "Ref" }, "data_kind": { @@ -12747,7 +13557,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1643" + "title": "X_2456" }, "encoding": { "tag_size": "Uint16", @@ -12783,13 +13593,41 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' } ], "name": "Example_arith smart contract rollup kind" + }, + { + "tag": 1, + "fields": [ + { + "name": "Tag", + "layout": { + "size": "Uint16", + "kind": "Int" + }, + "data_kind": { + "size": 2, + "kind": "Float" + }, + "kind": "named" + }, + { + "layout": { + "kind": "Zero_width" + }, + "kind": "anon", + "data_kind": { + "size": 0, + "kind": "Float" + } + } + ], + "name": "Wasm 2.0.0 smart contract rollup kind" } ] } }, { "description": { - "title": "X_1642" + "title": "X_2455" }, "encoding": { "fields": [ @@ -12812,7 +13650,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1641" + "title": "X_2454" }, "encoding": { "fields": [ @@ -12897,7 +13735,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "step", "layout": { - "name": "X_1640", + "name": "X_2453", "kind": "Ref" }, "data_kind": { @@ -12910,7 +13748,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1640" + "title": "X_2453" }, "encoding": { "tag_size": "Uint8", @@ -12941,7 +13779,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1638", + "name": "X_2451", "kind": "Ref" }, "kind": "Seq" @@ -12972,7 +13810,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "pvm_step", "layout": { - "name": "X_817", + "name": "X_1630", "kind": "Ref" }, "data_kind": { @@ -12983,7 +13821,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "inbox", "layout": { - "name": "X_1637", + "name": "X_2450", "kind": "Ref" }, "data_kind": { @@ -12999,13 +13837,13 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1638" + "title": "X_2451" }, "encoding": { "fields": [ { "layout": { - "name": "X_1639", + "name": "X_2452", "kind": "Ref" }, "kind": "anon", @@ -13028,7 +13866,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1639" + "title": "X_2452" }, "encoding": { "tag_size": "Uint8", @@ -13098,7 +13936,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1637" + "title": "X_2450" }, "encoding": { "tag_size": "Uint8", @@ -13158,7 +13996,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "skips", "layout": { "layout": { - "name": "X_818", + "name": "X_1631", "kind": "Ref" }, "kind": "Seq" @@ -13171,7 +14009,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "level", "layout": { - "name": "X_819", + "name": "X_1632", "kind": "Ref" }, "data_kind": { @@ -13188,7 +14026,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "inc", "layout": { "layout": { - "name": "X_825", + "name": "X_1638", "kind": "Ref" }, "kind": "Seq" @@ -13217,7 +14055,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1636" + "title": "X_2449" }, "encoding": { "tag_size": "Uint8", @@ -13434,7 +14272,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1632" + "title": "X_2445" }, "encoding": { "tag_size": "Uint8", @@ -13498,7 +14336,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "dense_proof", "layout": { "layout": { - "name": "X_1631", + "name": "X_2444", "kind": "Ref" }, "kind": "Seq", @@ -13520,7 +14358,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1631" + "title": "X_2444" }, "encoding": { "tag_size": "Uint8", @@ -13675,7 +14513,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_828" + "title": "X_1641" }, "encoding": { "tag_size": "Uint8", @@ -13747,7 +14585,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_825" + "title": "X_1638" }, "encoding": { "fields": [ @@ -13798,13 +14636,13 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_818" + "title": "X_1631" }, "encoding": { "fields": [ { "layout": { - "name": "X_819", + "name": "X_1632", "kind": "Ref" }, "kind": "anon", @@ -13814,7 +14652,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_821", + "name": "X_1634", "kind": "Ref" }, "kind": "anon", @@ -13827,7 +14665,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_821" + "title": "X_1634" }, "encoding": { "fields": [ @@ -13839,7 +14677,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_825", + "name": "X_1638", "kind": "Ref" }, "kind": "Seq" @@ -13854,7 +14692,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_819" + "title": "X_1632" }, "encoding": { "fields": [ @@ -13947,7 +14785,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "old_levels_messages", "layout": { - "name": "X_825", + "name": "X_1638", "kind": "Ref" }, "data_kind": { @@ -13960,7 +14798,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_817" + "title": "X_1630" }, "encoding": { "tag_size": "Uint8", @@ -13997,7 +14835,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "given", "layout": { - "name": "X_815", + "name": "X_1628", "kind": "Ref" }, "data_kind": { @@ -14008,7 +14846,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "requested", "layout": { - "name": "X_816", + "name": "X_1629", "kind": "Ref" }, "data_kind": { @@ -14018,13 +14856,64 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' } ], "name": "Arithmetic PVM with proof" + }, + { + "tag": 1, + "fields": [ + { + "name": "Tag", + "layout": { + "size": "Uint8", + "kind": "Int" + }, + "data_kind": { + "size": 1, + "kind": "Float" + }, + "kind": "named" + }, + { + "name": "tree_proof", + "layout": { + "name": "X_4", + "kind": "Ref" + }, + "data_kind": { + "kind": "Dynamic" + }, + "kind": "named" + }, + { + "name": "given", + "layout": { + "name": "X_1628", + "kind": "Ref" + }, + "data_kind": { + "kind": "Dynamic" + }, + "kind": "named" + }, + { + "name": "requested", + "layout": { + "name": "X_1629", + "kind": "Ref" + }, + "data_kind": { + "kind": "Dynamic" + }, + "kind": "named" + } + ], + "name": "Wasm 2.0.0 PVM with proof" } ] } }, { "description": { - "title": "X_816" + "title": "X_1629" }, "encoding": { "tag_size": "Uint8", @@ -14112,7 +15001,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_815" + "title": "X_1628" }, "encoding": { "tag_size": "Uint8", @@ -14228,7 +15117,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "before", "layout": { - "name": "X_828", + "name": "X_1641", "kind": "Ref" }, "data_kind": { @@ -14240,7 +15129,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "after", "layout": { - "name": "X_828", + "name": "X_1641", "kind": "Ref" }, "data_kind": { @@ -14252,7 +15141,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "state", "layout": { - "name": "X_1636", + "name": "X_2449", "kind": "Ref" }, "data_kind": { @@ -14284,7 +15173,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "proofs", "layout": { - "name": "X_1632", + "name": "X_2445", "kind": "Ref" }, "data_kind": { @@ -14314,7 +15203,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1631", + "name": "X_2444", "kind": "Ref" }, "kind": "anon", @@ -14346,7 +15235,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "segment", "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "data_kind": { @@ -14357,7 +15246,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "proof", "layout": { - "name": "X_1631", + "name": "X_2444", "kind": "Ref" }, "data_kind": { @@ -14376,7 +15265,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "fields": [ { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -14386,7 +15275,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1636", + "name": "X_2449", "kind": "Ref" }, "kind": "anon", @@ -17544,6 +18433,9 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "oneOf": [ { "title": "Example_arith smart contract rollup kind" + }, + { + "title": "Wasm 2.0.0 smart contract rollup kind" } ] }, @@ -17858,27 +18750,834 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "title": "Some", "$ref": "#/definitions/state_hash" }, - { - "title": "None", - "type": "null" - } - ] - }, - { - "$ref": "#/definitions/positive_bignum" - } - ], - "additionalItems": false - } - }, - { - "title": "Proof", - "type": "object", - "properties": { - "pvm_step": { - "oneOf": [ + { + "title": "None", + "type": "null" + } + ] + }, + { + "$ref": "#/definitions/positive_bignum" + } + ], + "additionalItems": false + } + }, + { + "title": "Proof", + "type": "object", + "properties": { + "pvm_step": { + "oneOf": [ + { + "title": "Arithmetic PVM with proof", + "type": "object", + "properties": { + "tree_proof": { + "type": "object", + "properties": { + "version": { + "type": "integer", + "minimum": -32768, + "maximum": 32767 + }, + "before": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "node" + ], + "additionalProperties": false + } + ] + }, + "after": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "node" + ], + "additionalProperties": false + } + ] + }, + "state": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Blinded_value", + "type": "object", + "properties": { + "blinded_value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "node" + ], + "additionalProperties": false + }, + { + "title": "Blinded_node", + "type": "object", + "properties": { + "blinded_node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_node" + ], + "additionalProperties": false + }, + { + "title": "Inode", + "type": "object", + "properties": { + "inode": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode" + ], + "additionalProperties": false + }, + { + "title": "Extender", + "type": "object", + "properties": { + "extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "state", + "after", + "before", + "version" + ], + "additionalProperties": false + }, + "given": { + "oneOf": [ + { + "title": "Some", + "type": "object", + "properties": { + "inbox_level": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "message_counter": { + "$ref": "#/definitions/positive_bignum" + }, + "payload": { + "$ref": "#/definitions/unistring" + } + }, + "required": [ + "payload", + "message_counter", + "inbox_level" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "null" + } + ] + }, + "requested": { + "oneOf": [ + { + "title": "No_input_required", + "type": "object", + "properties": { + "no_input_required": {} + }, + "required": [ + "no_input_required" + ], + "additionalProperties": false + }, + { + "title": "Initial", + "type": "object", + "properties": { + "initial": {} + }, + "required": [ + "initial" + ], + "additionalProperties": false + }, + { + "title": "First_after", + "type": "array", + "items": [ + { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + { + "$ref": "#/definitions/positive_bignum" + } + ], + "additionalItems": false + } + ] + } + }, + "required": [ + "requested", + "given", + "tree_proof" + ], + "additionalProperties": false + }, { - "title": "Arithmetic PVM with proof", + "title": "Wasm 2.0.0 PVM with proof", "type": "object", "properties": { "tree_proof": { diff --git a/tezt/tests/expected/RPC_test.ml/Alpha- (mode proxy) RPC regression tests- mempool.out b/tezt/tests/expected/RPC_test.ml/Alpha- (mode proxy) RPC regression tests- mempool.out index f053ea818a28d24709d449533a79f0888dde7c84..c4e83ef3183a30ea72ede22a554c74dc03100126 100644 --- a/tezt/tests/expected/RPC_test.ml/Alpha- (mode proxy) RPC regression tests- mempool.out +++ b/tezt/tests/expected/RPC_test.ml/Alpha- (mode proxy) RPC regression tests- mempool.out @@ -3117,6 +3117,9 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "oneOf": [ { "title": "Example_arith smart contract rollup kind" + }, + { + "title": "Wasm 2.0.0 smart contract rollup kind" } ] }, @@ -4256,213 +4259,12 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "tree_proof" ], "additionalProperties": false - } - ] - }, - "inbox": { - "oneOf": [ + }, { - "title": "Some", + "title": "Wasm 2.0.0 PVM with proof", "type": "object", "properties": { - "skips": { - "type": "array", - "items": { - "type": "array", - "items": [ - { - "type": "object", - "properties": { - "rollup": { - "$ref": "#/definitions/alpha.rollup_address" - }, - "message_counter": { - "$ref": "#/definitions/positive_bignum" - }, - "nb_available_messages": { - "$ref": "#/definitions/int64" - }, - "nb_messages_in_commitment_period": { - "$ref": "#/definitions/int64" - }, - "starting_level_of_current_commitment_period": { - "type": "integer", - "minimum": -2147483648, - "maximum": 2147483647 - }, - "level": { - "type": "integer", - "minimum": -2147483648, - "maximum": 2147483647 - }, - "current_messages_hash": { - "$ref": "#/definitions/inbox_hash" - }, - "old_levels_messages": { - "type": "object", - "properties": { - "index": { - "type": "integer", - "minimum": -1073741824, - "maximum": 1073741823 - }, - "content": { - "$ref": "#/definitions/inbox_hash" - }, - "back_pointers": { - "type": "array", - "items": { - "$ref": "#/definitions/inbox_hash" - } - } - }, - "required": [ - "back_pointers", - "content", - "index" - ], - "additionalProperties": false - } - }, - "required": [ - "old_levels_messages", - "current_messages_hash", - "level", - "starting_level_of_current_commitment_period", - "nb_messages_in_commitment_period", - "nb_available_messages", - "message_counter", - "rollup" - ], - "additionalProperties": false - }, - { - "type": "array", - "items": { - "type": "object", - "properties": { - "index": { - "type": "integer", - "minimum": -1073741824, - "maximum": 1073741823 - }, - "content": { - "$ref": "#/definitions/inbox_hash" - }, - "back_pointers": { - "type": "array", - "items": { - "$ref": "#/definitions/inbox_hash" - } - } - }, - "required": [ - "back_pointers", - "content", - "index" - ], - "additionalProperties": false - } - } - ], - "additionalItems": false - } - }, - "level": { - "type": "object", - "properties": { - "rollup": { - "$ref": "#/definitions/alpha.rollup_address" - }, - "message_counter": { - "$ref": "#/definitions/positive_bignum" - }, - "nb_available_messages": { - "$ref": "#/definitions/int64" - }, - "nb_messages_in_commitment_period": { - "$ref": "#/definitions/int64" - }, - "starting_level_of_current_commitment_period": { - "type": "integer", - "minimum": -2147483648, - "maximum": 2147483647 - }, - "level": { - "type": "integer", - "minimum": -2147483648, - "maximum": 2147483647 - }, - "current_messages_hash": { - "$ref": "#/definitions/inbox_hash" - }, - "old_levels_messages": { - "type": "object", - "properties": { - "index": { - "type": "integer", - "minimum": -1073741824, - "maximum": 1073741823 - }, - "content": { - "$ref": "#/definitions/inbox_hash" - }, - "back_pointers": { - "type": "array", - "items": { - "$ref": "#/definitions/inbox_hash" - } - } - }, - "required": [ - "back_pointers", - "content", - "index" - ], - "additionalProperties": false - } - }, - "required": [ - "old_levels_messages", - "current_messages_hash", - "level", - "starting_level_of_current_commitment_period", - "nb_messages_in_commitment_period", - "nb_available_messages", - "message_counter", - "rollup" - ], - "additionalProperties": false - }, - "inc": { - "type": "array", - "items": { - "type": "object", - "properties": { - "index": { - "type": "integer", - "minimum": -1073741824, - "maximum": 1073741823 - }, - "content": { - "$ref": "#/definitions/inbox_hash" - }, - "back_pointers": { - "type": "array", - "items": { - "$ref": "#/definitions/inbox_hash" - } - } - }, - "required": [ - "back_pointers", - "content", - "index" - ], - "additionalProperties": false - } - }, - "message_proof": { + "tree_proof": { "type": "object", "properties": { "version": { @@ -5184,54 +4986,1062 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "version" ], "additionalProperties": false - } - }, - "required": [ - "message_proof", - "inc", - "level", - "skips" - ], - "additionalProperties": false - }, - { - "title": "None", - "type": "null" - } - ] - } - }, - "required": [ - "inbox", - "pvm_step" - ], - "additionalProperties": false - } - ] - } - }, - "required": [ - "step", - "choice" - ], - "additionalProperties": false - }, - "is_opening_move": { - "type": "boolean" - } - }, - "required": [ - "is_opening_move", - "refutation", - "opponent", - "rollup", - "storage_limit", - "gas_limit", - "counter", - "fee", - "source", - "kind" - ], + }, + "given": { + "oneOf": [ + { + "title": "Some", + "type": "object", + "properties": { + "inbox_level": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "message_counter": { + "$ref": "#/definitions/positive_bignum" + }, + "payload": { + "$ref": "#/definitions/unistring" + } + }, + "required": [ + "payload", + "message_counter", + "inbox_level" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "null" + } + ] + }, + "requested": { + "oneOf": [ + { + "title": "No_input_required", + "type": "object", + "properties": { + "no_input_required": {} + }, + "required": [ + "no_input_required" + ], + "additionalProperties": false + }, + { + "title": "Initial", + "type": "object", + "properties": { + "initial": {} + }, + "required": [ + "initial" + ], + "additionalProperties": false + }, + { + "title": "First_after", + "type": "array", + "items": [ + { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + { + "$ref": "#/definitions/positive_bignum" + } + ], + "additionalItems": false + } + ] + } + }, + "required": [ + "requested", + "given", + "tree_proof" + ], + "additionalProperties": false + } + ] + }, + "inbox": { + "oneOf": [ + { + "title": "Some", + "type": "object", + "properties": { + "skips": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "object", + "properties": { + "rollup": { + "$ref": "#/definitions/alpha.rollup_address" + }, + "message_counter": { + "$ref": "#/definitions/positive_bignum" + }, + "nb_available_messages": { + "$ref": "#/definitions/int64" + }, + "nb_messages_in_commitment_period": { + "$ref": "#/definitions/int64" + }, + "starting_level_of_current_commitment_period": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "level": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "current_messages_hash": { + "$ref": "#/definitions/inbox_hash" + }, + "old_levels_messages": { + "type": "object", + "properties": { + "index": { + "type": "integer", + "minimum": -1073741824, + "maximum": 1073741823 + }, + "content": { + "$ref": "#/definitions/inbox_hash" + }, + "back_pointers": { + "type": "array", + "items": { + "$ref": "#/definitions/inbox_hash" + } + } + }, + "required": [ + "back_pointers", + "content", + "index" + ], + "additionalProperties": false + } + }, + "required": [ + "old_levels_messages", + "current_messages_hash", + "level", + "starting_level_of_current_commitment_period", + "nb_messages_in_commitment_period", + "nb_available_messages", + "message_counter", + "rollup" + ], + "additionalProperties": false + }, + { + "type": "array", + "items": { + "type": "object", + "properties": { + "index": { + "type": "integer", + "minimum": -1073741824, + "maximum": 1073741823 + }, + "content": { + "$ref": "#/definitions/inbox_hash" + }, + "back_pointers": { + "type": "array", + "items": { + "$ref": "#/definitions/inbox_hash" + } + } + }, + "required": [ + "back_pointers", + "content", + "index" + ], + "additionalProperties": false + } + } + ], + "additionalItems": false + } + }, + "level": { + "type": "object", + "properties": { + "rollup": { + "$ref": "#/definitions/alpha.rollup_address" + }, + "message_counter": { + "$ref": "#/definitions/positive_bignum" + }, + "nb_available_messages": { + "$ref": "#/definitions/int64" + }, + "nb_messages_in_commitment_period": { + "$ref": "#/definitions/int64" + }, + "starting_level_of_current_commitment_period": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "level": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "current_messages_hash": { + "$ref": "#/definitions/inbox_hash" + }, + "old_levels_messages": { + "type": "object", + "properties": { + "index": { + "type": "integer", + "minimum": -1073741824, + "maximum": 1073741823 + }, + "content": { + "$ref": "#/definitions/inbox_hash" + }, + "back_pointers": { + "type": "array", + "items": { + "$ref": "#/definitions/inbox_hash" + } + } + }, + "required": [ + "back_pointers", + "content", + "index" + ], + "additionalProperties": false + } + }, + "required": [ + "old_levels_messages", + "current_messages_hash", + "level", + "starting_level_of_current_commitment_period", + "nb_messages_in_commitment_period", + "nb_available_messages", + "message_counter", + "rollup" + ], + "additionalProperties": false + }, + "inc": { + "type": "array", + "items": { + "type": "object", + "properties": { + "index": { + "type": "integer", + "minimum": -1073741824, + "maximum": 1073741823 + }, + "content": { + "$ref": "#/definitions/inbox_hash" + }, + "back_pointers": { + "type": "array", + "items": { + "$ref": "#/definitions/inbox_hash" + } + } + }, + "required": [ + "back_pointers", + "content", + "index" + ], + "additionalProperties": false + } + }, + "message_proof": { + "type": "object", + "properties": { + "version": { + "type": "integer", + "minimum": -32768, + "maximum": 32767 + }, + "before": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "node" + ], + "additionalProperties": false + } + ] + }, + "after": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "node" + ], + "additionalProperties": false + } + ] + }, + "state": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Blinded_value", + "type": "object", + "properties": { + "blinded_value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "node" + ], + "additionalProperties": false + }, + { + "title": "Blinded_node", + "type": "object", + "properties": { + "blinded_node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_node" + ], + "additionalProperties": false + }, + { + "title": "Inode", + "type": "object", + "properties": { + "inode": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode" + ], + "additionalProperties": false + }, + { + "title": "Extender", + "type": "object", + "properties": { + "extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "state", + "after", + "before", + "version" + ], + "additionalProperties": false + } + }, + "required": [ + "message_proof", + "inc", + "level", + "skips" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "null" + } + ] + } + }, + "required": [ + "inbox", + "pvm_step" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "step", + "choice" + ], + "additionalProperties": false + }, + "is_opening_move": { + "type": "boolean" + } + }, + "required": [ + "is_opening_move", + "refutation", + "opponent", + "rollup", + "storage_limit", + "gas_limit", + "counter", + "fee", + "source", + "kind" + ], "additionalProperties": false }, { @@ -7356,7 +8166,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "parameters", "layout": { - "name": "X_1777", + "name": "X_2590", "kind": "Ref" }, "data_kind": { @@ -8021,7 +8831,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "commitment", "layout": { - "name": "X_1775", + "name": "X_2588", "kind": "Ref" }, "data_kind": { @@ -8384,7 +9194,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "message", "layout": { - "name": "X_1648", + "name": "X_2461", "kind": "Ref" }, "data_kind": { @@ -8453,7 +9263,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "previous_message_result", "layout": { - "name": "X_1649", + "name": "X_2462", "kind": "Ref" }, "data_kind": { @@ -8483,7 +9293,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "proof", "layout": { - "name": "X_1774", + "name": "X_2587", "kind": "Ref" }, "data_kind": { @@ -8639,7 +9449,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "tickets_info", "layout": { "layout": { - "name": "X_1644", + "name": "X_2457", "kind": "Ref" }, "kind": "Seq" @@ -8880,7 +9690,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "kind", "layout": { - "name": "X_1643", + "name": "X_2456", "kind": "Ref" }, "data_kind": { @@ -9018,7 +9828,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "message", "layout": { "layout": { - "name": "X_1642", + "name": "X_2455", "kind": "Ref" }, "kind": "Seq" @@ -9222,7 +10032,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "commitment", "layout": { - "name": "X_1641", + "name": "X_2454", "kind": "Ref" }, "data_kind": { @@ -10395,7 +11205,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1777" + "title": "X_2590" }, "encoding": { "fields": [ @@ -10738,7 +11548,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1775" + "title": "X_2588" }, "encoding": { "fields": [ @@ -10775,7 +11585,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "predecessor", "layout": { - "name": "X_1776", + "name": "X_2589", "kind": "Ref" }, "data_kind": { @@ -10799,7 +11609,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1776" + "title": "X_2589" }, "encoding": { "tag_size": "Uint8", @@ -10869,7 +11679,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1774" + "title": "X_2587" }, "encoding": { "tag_size": "Uint8", @@ -10925,7 +11735,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1650", + "name": "X_2463", "kind": "Ref" }, "kind": "anon", @@ -10984,7 +11794,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1650", + "name": "X_2463", "kind": "Ref" }, "kind": "anon", @@ -11043,7 +11853,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1650", + "name": "X_2463", "kind": "Ref" }, "kind": "anon", @@ -11102,7 +11912,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1650", + "name": "X_2463", "kind": "Ref" }, "kind": "anon", @@ -11118,7 +11928,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1773" + "title": "X_2586" }, "encoding": { "tag_size": "Uint8", @@ -11154,7 +11964,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1772", + "name": "X_2585", "kind": "Ref" }, "kind": "anon", @@ -11194,7 +12004,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1772", + "name": "X_2585", "kind": "Ref" }, "kind": "anon", @@ -11234,7 +12044,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1772", + "name": "X_2585", "kind": "Ref" }, "kind": "anon", @@ -11274,7 +12084,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1772", + "name": "X_2585", "kind": "Ref" }, "kind": "anon", @@ -11314,7 +12124,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11354,7 +12164,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11394,7 +12204,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11434,7 +12244,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11474,7 +12284,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11514,7 +12324,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11554,7 +12364,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11594,7 +12404,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1768", + "name": "X_2581", "kind": "Ref" }, "kind": "anon", @@ -11634,7 +12444,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1760", + "name": "X_2573", "kind": "Ref" }, "kind": "anon", @@ -11674,7 +12484,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1760", + "name": "X_2573", "kind": "Ref" }, "kind": "anon", @@ -11714,7 +12524,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1760", + "name": "X_2573", "kind": "Ref" }, "kind": "anon", @@ -11754,7 +12564,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1760", + "name": "X_2573", "kind": "Ref" }, "kind": "anon", @@ -11812,7 +12622,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1655", + "name": "X_2468", "kind": "Ref" }, "kind": "Seq", @@ -11847,7 +12657,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1655", + "name": "X_2468", "kind": "Ref" }, "kind": "Seq", @@ -11887,7 +12697,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1655", + "name": "X_2468", "kind": "Ref" }, "kind": "Seq" @@ -12024,7 +12834,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12073,7 +12883,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12122,7 +12932,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12171,7 +12981,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12197,7 +13007,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1772" + "title": "X_2585" }, "encoding": { "fields": [] @@ -12205,7 +13015,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1768" + "title": "X_2581" }, "encoding": { "fields": [ @@ -12224,7 +13034,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1760" + "title": "X_2573" }, "encoding": { "fields": [ @@ -12253,7 +13063,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1756" + "title": "X_2569" }, "encoding": { "tag_size": "Uint8", @@ -12325,7 +13135,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1755" + "title": "X_2568" }, "encoding": { "fields": [ @@ -12348,7 +13158,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1650" + "title": "X_2463" }, "encoding": { "fields": [ @@ -12360,7 +13170,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1773", + "name": "X_2586", "kind": "Ref" }, "kind": "Seq" @@ -12375,13 +13185,13 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1655" + "title": "X_2468" }, "encoding": { "fields": [ { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -12391,7 +13201,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1756", + "name": "X_2569", "kind": "Ref" }, "kind": "anon", @@ -12405,7 +13215,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1649" + "title": "X_2462" }, "encoding": { "fields": [ @@ -12436,7 +13246,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1648" + "title": "X_2461" }, "encoding": { "tag_size": "Uint8", @@ -12495,7 +13305,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "deposit", "layout": { - "name": "X_1646", + "name": "X_2459", "kind": "Ref" }, "data_kind": { @@ -12511,7 +13321,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1646" + "title": "X_2459" }, "encoding": { "fields": [ @@ -12552,7 +13362,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "amount", "layout": { - "name": "X_1647", + "name": "X_2460", "kind": "Ref" }, "data_kind": { @@ -12565,7 +13375,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1647" + "title": "X_2460" }, "encoding": { "tag_size": "Uint8", @@ -12694,7 +13504,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1644" + "title": "X_2457" }, "encoding": { "fields": [ @@ -12743,7 +13553,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "amount", "layout": { - "name": "X_1647", + "name": "X_2460", "kind": "Ref" }, "data_kind": { @@ -12768,7 +13578,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1643" + "title": "X_2456" }, "encoding": { "tag_size": "Uint16", @@ -12804,13 +13614,41 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' } ], "name": "Example_arith smart contract rollup kind" + }, + { + "tag": 1, + "fields": [ + { + "name": "Tag", + "layout": { + "size": "Uint16", + "kind": "Int" + }, + "data_kind": { + "size": 2, + "kind": "Float" + }, + "kind": "named" + }, + { + "layout": { + "kind": "Zero_width" + }, + "kind": "anon", + "data_kind": { + "size": 0, + "kind": "Float" + } + } + ], + "name": "Wasm 2.0.0 smart contract rollup kind" } ] } }, { "description": { - "title": "X_1642" + "title": "X_2455" }, "encoding": { "fields": [ @@ -12833,7 +13671,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1641" + "title": "X_2454" }, "encoding": { "fields": [ @@ -12918,7 +13756,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "step", "layout": { - "name": "X_1640", + "name": "X_2453", "kind": "Ref" }, "data_kind": { @@ -12931,7 +13769,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1640" + "title": "X_2453" }, "encoding": { "tag_size": "Uint8", @@ -12962,7 +13800,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_1638", + "name": "X_2451", "kind": "Ref" }, "kind": "Seq" @@ -12993,7 +13831,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "pvm_step", "layout": { - "name": "X_817", + "name": "X_1630", "kind": "Ref" }, "data_kind": { @@ -13004,7 +13842,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "inbox", "layout": { - "name": "X_1637", + "name": "X_2450", "kind": "Ref" }, "data_kind": { @@ -13020,13 +13858,13 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1638" + "title": "X_2451" }, "encoding": { "fields": [ { "layout": { - "name": "X_1639", + "name": "X_2452", "kind": "Ref" }, "kind": "anon", @@ -13049,7 +13887,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1639" + "title": "X_2452" }, "encoding": { "tag_size": "Uint8", @@ -13119,7 +13957,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1637" + "title": "X_2450" }, "encoding": { "tag_size": "Uint8", @@ -13179,7 +14017,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "skips", "layout": { "layout": { - "name": "X_818", + "name": "X_1631", "kind": "Ref" }, "kind": "Seq" @@ -13192,7 +14030,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "level", "layout": { - "name": "X_819", + "name": "X_1632", "kind": "Ref" }, "data_kind": { @@ -13209,7 +14047,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "inc", "layout": { "layout": { - "name": "X_825", + "name": "X_1638", "kind": "Ref" }, "kind": "Seq" @@ -13238,7 +14076,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1636" + "title": "X_2449" }, "encoding": { "tag_size": "Uint8", @@ -13455,7 +14293,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1632" + "title": "X_2445" }, "encoding": { "tag_size": "Uint8", @@ -13519,7 +14357,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "name": "dense_proof", "layout": { "layout": { - "name": "X_1631", + "name": "X_2444", "kind": "Ref" }, "kind": "Seq", @@ -13541,7 +14379,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_1631" + "title": "X_2444" }, "encoding": { "tag_size": "Uint8", @@ -13696,7 +14534,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_828" + "title": "X_1641" }, "encoding": { "tag_size": "Uint8", @@ -13768,7 +14606,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_825" + "title": "X_1638" }, "encoding": { "fields": [ @@ -13819,13 +14657,13 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_818" + "title": "X_1631" }, "encoding": { "fields": [ { "layout": { - "name": "X_819", + "name": "X_1632", "kind": "Ref" }, "kind": "anon", @@ -13835,7 +14673,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_821", + "name": "X_1634", "kind": "Ref" }, "kind": "anon", @@ -13848,7 +14686,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_821" + "title": "X_1634" }, "encoding": { "fields": [ @@ -13860,7 +14698,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "layout": { "layout": { - "name": "X_825", + "name": "X_1638", "kind": "Ref" }, "kind": "Seq" @@ -13875,7 +14713,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_819" + "title": "X_1632" }, "encoding": { "fields": [ @@ -13968,7 +14806,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "old_levels_messages", "layout": { - "name": "X_825", + "name": "X_1638", "kind": "Ref" }, "data_kind": { @@ -13981,7 +14819,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_817" + "title": "X_1630" }, "encoding": { "tag_size": "Uint8", @@ -14018,7 +14856,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "given", "layout": { - "name": "X_815", + "name": "X_1628", "kind": "Ref" }, "data_kind": { @@ -14029,7 +14867,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "requested", "layout": { - "name": "X_816", + "name": "X_1629", "kind": "Ref" }, "data_kind": { @@ -14039,13 +14877,64 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' } ], "name": "Arithmetic PVM with proof" + }, + { + "tag": 1, + "fields": [ + { + "name": "Tag", + "layout": { + "size": "Uint8", + "kind": "Int" + }, + "data_kind": { + "size": 1, + "kind": "Float" + }, + "kind": "named" + }, + { + "name": "tree_proof", + "layout": { + "name": "X_4", + "kind": "Ref" + }, + "data_kind": { + "kind": "Dynamic" + }, + "kind": "named" + }, + { + "name": "given", + "layout": { + "name": "X_1628", + "kind": "Ref" + }, + "data_kind": { + "kind": "Dynamic" + }, + "kind": "named" + }, + { + "name": "requested", + "layout": { + "name": "X_1629", + "kind": "Ref" + }, + "data_kind": { + "kind": "Dynamic" + }, + "kind": "named" + } + ], + "name": "Wasm 2.0.0 PVM with proof" } ] } }, { "description": { - "title": "X_816" + "title": "X_1629" }, "encoding": { "tag_size": "Uint8", @@ -14133,7 +15022,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "description": { - "title": "X_815" + "title": "X_1628" }, "encoding": { "tag_size": "Uint8", @@ -14249,7 +15138,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "before", "layout": { - "name": "X_828", + "name": "X_1641", "kind": "Ref" }, "data_kind": { @@ -14261,7 +15150,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "after", "layout": { - "name": "X_828", + "name": "X_1641", "kind": "Ref" }, "data_kind": { @@ -14273,7 +15162,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "state", "layout": { - "name": "X_1636", + "name": "X_2449", "kind": "Ref" }, "data_kind": { @@ -14305,7 +15194,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "proofs", "layout": { - "name": "X_1632", + "name": "X_2445", "kind": "Ref" }, "data_kind": { @@ -14335,7 +15224,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1631", + "name": "X_2444", "kind": "Ref" }, "kind": "anon", @@ -14367,7 +15256,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "segment", "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "data_kind": { @@ -14378,7 +15267,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' { "name": "proof", "layout": { - "name": "X_1631", + "name": "X_2444", "kind": "Ref" }, "data_kind": { @@ -14397,7 +15286,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "fields": [ { "layout": { - "name": "X_1755", + "name": "X_2568", "kind": "Ref" }, "kind": "anon", @@ -14407,7 +15296,7 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' }, { "layout": { - "name": "X_1636", + "name": "X_2449", "kind": "Ref" }, "kind": "anon", @@ -17565,6 +18454,9 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "oneOf": [ { "title": "Example_arith smart contract rollup kind" + }, + { + "title": "Wasm 2.0.0 smart contract rollup kind" } ] }, @@ -17879,27 +18771,834 @@ curl -s 'http://localhost:[PORT]/describe/chains/main/mempool?recurse=yes' "title": "Some", "$ref": "#/definitions/state_hash" }, - { - "title": "None", - "type": "null" - } - ] - }, - { - "$ref": "#/definitions/positive_bignum" - } - ], - "additionalItems": false - } - }, - { - "title": "Proof", - "type": "object", - "properties": { - "pvm_step": { - "oneOf": [ + { + "title": "None", + "type": "null" + } + ] + }, + { + "$ref": "#/definitions/positive_bignum" + } + ], + "additionalItems": false + } + }, + { + "title": "Proof", + "type": "object", + "properties": { + "pvm_step": { + "oneOf": [ + { + "title": "Arithmetic PVM with proof", + "type": "object", + "properties": { + "tree_proof": { + "type": "object", + "properties": { + "version": { + "type": "integer", + "minimum": -32768, + "maximum": 32767 + }, + "before": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "node" + ], + "additionalProperties": false + } + ] + }, + "after": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "node" + ], + "additionalProperties": false + } + ] + }, + "state": { + "oneOf": [ + { + "title": "Value", + "type": "object", + "properties": { + "value": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + } + }, + "required": [ + "value" + ], + "additionalProperties": false + }, + { + "title": "Blinded_value", + "type": "object", + "properties": { + "blinded_value": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_value" + ], + "additionalProperties": false + }, + { + "title": "Node", + "type": "object", + "properties": { + "node": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "node" + ], + "additionalProperties": false + }, + { + "title": "Blinded_node", + "type": "object", + "properties": { + "blinded_node": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_node" + ], + "additionalProperties": false + }, + { + "title": "Inode", + "type": "object", + "properties": { + "inode": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode" + ], + "additionalProperties": false + }, + { + "title": "Extender", + "type": "object", + "properties": { + "extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "oneOf": [ + { + "title": "Blinded_inode", + "type": "object", + "properties": { + "blinded_inode": { + "$ref": "#/definitions/Context_hash" + } + }, + "required": [ + "blinded_inode" + ], + "additionalProperties": false + }, + { + "title": "Inode_values", + "type": "object", + "properties": { + "inode_values": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + { + "$ref": "#/definitions/tree_encoding" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "inode_values" + ], + "additionalProperties": false + }, + { + "title": "Inode_tree", + "type": "object", + "properties": { + "inode_tree": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "proofs": { + "oneOf": [ + { + "title": "sparse_proof", + "type": "object", + "properties": { + "sparse_proof": { + "type": "array", + "items": { + "type": "array", + "items": [ + { + "type": "integer", + "minimum": 0, + "maximum": 255 + }, + { + "$ref": "#/definitions/inode_tree" + } + ], + "additionalItems": false + } + } + }, + "required": [ + "sparse_proof" + ], + "additionalProperties": false + }, + { + "title": "dense_proof", + "type": "object", + "properties": { + "dense_proof": { + "type": "array", + "items": { + "$ref": "#/definitions/inode_tree" + } + } + }, + "required": [ + "dense_proof" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proofs", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_tree" + ], + "additionalProperties": false + }, + { + "title": "Inode_extender", + "type": "object", + "properties": { + "inode_extender": { + "type": "object", + "properties": { + "length": { + "$ref": "#/definitions/int64" + }, + "segment": { + "type": "string", + "pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$" + }, + "proof": { + "$ref": "#/definitions/inode_tree" + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "inode_extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "proof", + "segment", + "length" + ], + "additionalProperties": false + } + }, + "required": [ + "extender" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "object", + "properties": { + "none": { + "type": "null" + } + }, + "required": [ + "none" + ], + "additionalProperties": false + } + ] + } + }, + "required": [ + "state", + "after", + "before", + "version" + ], + "additionalProperties": false + }, + "given": { + "oneOf": [ + { + "title": "Some", + "type": "object", + "properties": { + "inbox_level": { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + "message_counter": { + "$ref": "#/definitions/positive_bignum" + }, + "payload": { + "$ref": "#/definitions/unistring" + } + }, + "required": [ + "payload", + "message_counter", + "inbox_level" + ], + "additionalProperties": false + }, + { + "title": "None", + "type": "null" + } + ] + }, + "requested": { + "oneOf": [ + { + "title": "No_input_required", + "type": "object", + "properties": { + "no_input_required": {} + }, + "required": [ + "no_input_required" + ], + "additionalProperties": false + }, + { + "title": "Initial", + "type": "object", + "properties": { + "initial": {} + }, + "required": [ + "initial" + ], + "additionalProperties": false + }, + { + "title": "First_after", + "type": "array", + "items": [ + { + "type": "integer", + "minimum": -2147483648, + "maximum": 2147483647 + }, + { + "$ref": "#/definitions/positive_bignum" + } + ], + "additionalItems": false + } + ] + } + }, + "required": [ + "requested", + "given", + "tree_proof" + ], + "additionalProperties": false + }, { - "title": "Arithmetic PVM with proof", + "title": "Wasm 2.0.0 PVM with proof", "type": "object", "properties": { "tree_proof": {