From e77fc7e0da0ac9923c22fc6792e9b3e65d936b9b Mon Sep 17 00:00:00 2001 From: Dibassi Brahima Date: Wed, 2 Apr 2025 16:48:03 +0200 Subject: [PATCH 1/3] EVM/Tezlink/Node: Add support for Tezos bootstrap accounts in kernel configuration --- .../bin_node/lib_dev/encodings/tezos_types.ml | 10 +- .../lib_dev/encodings/tezos_types.mli | 6 +- etherlink/bin_node/lib_dev/kernel_config.ml | 70 ++++++++--- etherlink/bin_node/lib_dev/kernel_config.mli | 12 +- etherlink/bin_node/main.ml | 111 ++++++++++++------ 5 files changed, 150 insertions(+), 59 deletions(-) diff --git a/etherlink/bin_node/lib_dev/encodings/tezos_types.ml b/etherlink/bin_node/lib_dev/encodings/tezos_types.ml index 5bb632427f0f..de3749b5b0c7 100644 --- a/etherlink/bin_node/lib_dev/encodings/tezos_types.ml +++ b/etherlink/bin_node/lib_dev/encodings/tezos_types.ml @@ -56,4 +56,12 @@ let address_to_hex_exn address = let (`Hex key) = Hex.of_bytes raw_key in key -module Tez = Tezos_protocol_021_PsQuebec.Protocol.Alpha_context.Tez +module Tez = struct + include Tezos_protocol_021_PsQuebec.Protocol.Alpha_context.Tez + + let of_string_exn str = + match of_string str with + | None -> + raise (Invalid_argument (Printf.sprintf "Invalid tez value: %s" str)) + | Some s -> s +end diff --git a/etherlink/bin_node/lib_dev/encodings/tezos_types.mli b/etherlink/bin_node/lib_dev/encodings/tezos_types.mli index d3409b11f465..72698b77646e 100644 --- a/etherlink/bin_node/lib_dev/encodings/tezos_types.mli +++ b/etherlink/bin_node/lib_dev/encodings/tezos_types.mli @@ -26,4 +26,8 @@ val address_of_b58exn : string -> address val address_to_hex_exn : address -> string -module Tez = Tezos_protocol_021_PsQuebec.Protocol.Alpha_context.Tez +module Tez : sig + include module type of Tezos_protocol_021_PsQuebec.Protocol.Alpha_context.Tez + + val of_string_exn : string -> t +end diff --git a/etherlink/bin_node/lib_dev/kernel_config.ml b/etherlink/bin_node/lib_dev/kernel_config.ml index 25e16c2e1783..97904ad22867 100644 --- a/etherlink/bin_node/lib_dev/kernel_config.ml +++ b/etherlink/bin_node/lib_dev/kernel_config.ml @@ -82,7 +82,8 @@ let clean_path path = [] (List.rev path) -let make_l2 ~boostrap_balance ?bootstrap_accounts ?minimum_base_fee_per_gas +let make_l2 ~eth_bootstrap_balance ~tez_bootstrap_balance + ?eth_bootstrap_accounts ?tez_bootstrap_accounts ?minimum_base_fee_per_gas ?da_fee_per_byte ?sequencer_pool_address ?maximum_gas_per_transaction ?set_account_code ?world_state_path ~l2_chain_id ~l2_chain_family ~output () = @@ -91,18 +92,38 @@ let make_l2 ~boostrap_balance ?bootstrap_accounts ?minimum_base_fee_per_gas | None -> ["evm"; "world_state"; l2_chain_id] | Some (_, value) -> clean_path (String.split_on_char '/' value) in - let bootstrap_accounts = - match bootstrap_accounts with + let eth_bootstrap_accounts = + match eth_bootstrap_accounts with | None -> [] - | Some bootstrap_accounts -> + | Some eth_bootstrap_accounts -> let open Ethereum_types in - let balance = padded_32_le_int_bytes boostrap_balance in + let balance = padded_32_le_int_bytes eth_bootstrap_balance in List.map (fun (Address (Hex address)) -> make_instr ~path_prefix:(world_state_prefix @ ["eth_accounts"; address]) (Some ("balance", balance))) - bootstrap_accounts + eth_bootstrap_accounts + |> List.flatten + in + let tez_bootstrap_accounts = + match tez_bootstrap_accounts with + | None -> [] + | Some tez_bootstrap_accounts -> + let open Tezos_types in + List.map + (fun address -> + make_instr + ~path_prefix: + [ + "tezlink"; + "context"; + "contracts"; + "index"; + address_to_hex_exn address; + ] + (Some ("balance", Tez.to_string tez_bootstrap_balance))) + tez_bootstrap_accounts |> List.flatten in let set_account_code = @@ -146,11 +167,12 @@ let make_l2 ~boostrap_balance ?bootstrap_accounts ?minimum_base_fee_per_gas Hex.to_bytes_exn (`Hex addr) |> String.of_bytes) ~path_prefix:world_state_prefix sequencer_pool_address - @ bootstrap_accounts @ set_account_code + @ eth_bootstrap_accounts @ tez_bootstrap_accounts @ set_account_code in Installer_config.to_file (config_instrs @ world_state_instrs) ~output -let make ~mainnet_compat ~boostrap_balance ?l2_chain_ids ?bootstrap_accounts +let make ~mainnet_compat ~eth_bootstrap_balance ~tez_bootstrap_balance + ?l2_chain_ids ?eth_bootstrap_accounts ?tez_bootstrap_accounts ?kernel_root_hash ?chain_id ?sequencer ?delayed_bridge ?ticketer ?admin ?sequencer_governance ?kernel_governance ?kernel_security_governance ?minimum_base_fee_per_gas ?da_fee_per_byte ?delayed_inbox_timeout @@ -160,18 +182,38 @@ let make ~mainnet_compat ~boostrap_balance ?l2_chain_ids ?bootstrap_accounts ?enable_fast_withdrawal ?enable_fast_fa_withdrawal ?enable_multichain ?set_account_code ?max_delayed_inbox_blueprint_length ?evm_version ~output () = - let bootstrap_accounts = + let eth_bootstrap_accounts = let open Ethereum_types in - match bootstrap_accounts with + match eth_bootstrap_accounts with | None -> [] - | Some bootstrap_accounts -> - let balance = padded_32_le_int_bytes boostrap_balance in + | Some eth_bootstrap_accounts -> + let balance = padded_32_le_int_bytes eth_bootstrap_balance in List.map (fun (Address (Hex address)) -> make_instr ~path_prefix:["evm"; "world_state"; "eth_accounts"; address] (Some ("balance", balance))) - bootstrap_accounts + eth_bootstrap_accounts + |> List.flatten + in + let tez_bootstrap_accounts = + match tez_bootstrap_accounts with + | None -> [] + | Some tez_bootstrap_accounts -> + let open Tezos_types in + List.map + (fun address -> + make_instr + ~path_prefix: + [ + "tezlink"; + "context"; + "contracts"; + "index"; + address_to_hex_exn address; + ] + (Some ("balance", Tez.to_string tez_bootstrap_balance))) + tez_bootstrap_accounts |> List.flatten in let set_account_code = @@ -252,7 +294,7 @@ let make ~mainnet_compat ~boostrap_balance ?l2_chain_ids ?bootstrap_accounts @ make_instr ~convert:le_int64_bytes maximum_allowed_ticks @ make_instr ~convert:le_int64_bytes maximum_gas_per_transaction @ make_instr ~convert:le_int64_bytes max_blueprint_lookahead_in_seconds - @ bootstrap_accounts @ set_account_code + @ eth_bootstrap_accounts @ tez_bootstrap_accounts @ set_account_code @ make_instr remove_whitelist @ make_instr ~path_prefix:["evm"; "feature_flags"] enable_fa_bridge @ make_instr ~path_prefix:["evm"; "feature_flags"] enable_dal diff --git a/etherlink/bin_node/lib_dev/kernel_config.mli b/etherlink/bin_node/lib_dev/kernel_config.mli index 95bec428cf8c..bfcec2b56983 100644 --- a/etherlink/bin_node/lib_dev/kernel_config.mli +++ b/etherlink/bin_node/lib_dev/kernel_config.mli @@ -13,9 +13,11 @@ type evm_version = Shanghai | Cancun [bootstrap_accounts] are provisioned with [bootstrap_balance]. *) val make : mainnet_compat:bool -> - boostrap_balance:Ethereum_types.NonceMap.key -> + eth_bootstrap_balance:Ethereum_types.NonceMap.key -> + tez_bootstrap_balance:Tezos_types.Tez.t -> ?l2_chain_ids:L2_types.chain_id list -> - ?bootstrap_accounts:Ethereum_types.address list -> + ?eth_bootstrap_accounts:Ethereum_types.address list -> + ?tez_bootstrap_accounts:Tezos_types.address list -> ?kernel_root_hash:string * string -> ?chain_id:string * string -> ?sequencer:string * string -> @@ -51,8 +53,10 @@ val make : generates a configuration file located at [output] for the chain [l2_chain_id], where [bootstrap_accounts] are provisioned with [bootstrap_balance]. *) val make_l2 : - boostrap_balance:Z.t -> - ?bootstrap_accounts:Ethereum_types.address list -> + eth_bootstrap_balance:Ethereum_types.NonceMap.key -> + tez_bootstrap_balance:Tezos_types.Tez.t -> + ?eth_bootstrap_accounts:Ethereum_types.address list -> + ?tez_bootstrap_accounts:Tezos_types.address list -> ?minimum_base_fee_per_gas:string * string -> ?da_fee_per_byte:string * string -> ?sequencer_pool_address:string * string -> diff --git a/etherlink/bin_node/main.ml b/etherlink/bin_node/main.ml index 6a3650504530..a7eae3e51768 100644 --- a/etherlink/bin_node/main.ml +++ b/etherlink/bin_node/main.ml @@ -150,7 +150,7 @@ module Params = struct [\"1970-01-01T00:00:00Z\"]) or in number of seconds since \ the {!Time.Protocol.epoch}.")) - let l2_address = + let eth_address = Tezos_clic.parameter (fun _ address -> let open Lwt_result_syntax in let hex = Evm_node_lib_dev.Misc.normalize_addr address in @@ -162,6 +162,11 @@ module Params = struct in return (Evm_node_lib_dev_encoding.Ethereum_types.Address (Hex hex))) + let tez_address = + Tezos_clic.parameter (fun _ address -> + Lwt.return + (Evm_node_lib_dev_encoding.Tezos_types.address_of_b58check address)) + let l2_level = Tezos_clic.parameter (fun () s -> Lwt.return_ok @@ -1403,7 +1408,7 @@ let make_sequencer_upgrade_command = @@ Tezos_clic.param ~name:"pool_address" ~desc:"Pool address of the sequencer" - Params.l2_address + Params.eth_address @@ prefixes ["at"; "activation"; "timestamp"] @@ param ~name:"activation_timestamp" @@ -1878,10 +1883,37 @@ let config_key_flag ~name = if enable then return_some (name, "") else return_none) @@ Tezos_clic.switch ~long ~doc () -let bootstrap_account_arg = - let long = "bootstrap-account" in - let doc = Format.sprintf "Add a bootstrap account in the installer config." in - Tezos_clic.multiple_arg ~long ~doc ~placeholder:"0x..." Params.l2_address +let eth_bootstrap_account_arg = + let long = "eth-bootstrap-account" in + let doc = + Format.sprintf "Add an etherlink bootstrap account in the installer config." + in + Tezos_clic.multiple_arg ~long ~doc ~placeholder:"0x..." Params.eth_address + +let tez_bootstrap_account_arg = + let long = "tez-bootstrap-account" in + let doc = + Format.sprintf "Add an tezlink bootstrap account in the installer config." + in + Tezos_clic.multiple_arg ~long ~doc ~placeholder:"tz1..." Params.tez_address + +let eth_bootstrap_balance_arg = + Tezos_clic.default_arg + ~long:"eth-bootstrap-balance" + ~doc:"Balance of the etherlink bootstrap accounts" + ~default:"9999000000000000000000" + ~placeholder:"9999000000000000000000" + @@ Tezos_clic.parameter (fun _ s -> Lwt_result.return @@ Z.of_string s) + +let tez_bootstrap_balance_arg = + Tezos_clic.default_arg + ~long:"tez-bootstrap-balance" + ~doc:"Balance of the tezlink bootstrap accounts" + ~default:"3800000" + ~placeholder:"3800000" + @@ Tezos_clic.parameter (fun _ s -> + Lwt_result.return + @@ Evm_node_lib_dev_encoding.Tezos_types.Tez.of_string_exn s) let set_account_code = let long = "set-code" in @@ -1916,20 +1948,17 @@ let make_l2_kernel_config_command = ~desc: "Produce a file containing the part of the kernel configuration \ instructions related to a particular L2 chain." - (args10 + (args12 (config_key_arg ~name:"minimum_base_fee_per_gas" ~placeholder:"111...") (config_key_arg ~name:"da_fee_per_byte" ~placeholder:"111...") (config_key_arg ~name:"sequencer_pool_address" ~placeholder:"0x...") (config_key_arg ~name:"maximum_gas_per_transaction" ~placeholder:"30000...") - (Tezos_clic.default_arg - ~long:"bootstrap-balance" - ~doc:"Balance of the bootstrap accounts." - ~default:"9999000000000000000000" - ~placeholder:"9999000000000000000000" - @@ Tezos_clic.parameter (fun _ s -> return @@ Z.of_string s)) - bootstrap_account_arg + eth_bootstrap_balance_arg + eth_bootstrap_account_arg + tez_bootstrap_balance_arg + tez_bootstrap_account_arg set_account_code (config_key_arg ~name:"world_state_path" @@ -1956,8 +1985,10 @@ let make_l2_kernel_config_command = da_fee_per_byte, sequencer_pool_address, maximum_gas_per_transaction, - boostrap_balance, - bootstrap_accounts, + eth_bootstrap_balance, + eth_bootstrap_accounts, + tez_bootstrap_balance, + tez_bootstrap_accounts, set_account_code, world_state_path, l2_chain_id, @@ -1973,12 +2004,14 @@ let make_l2_kernel_config_command = | Some l2_chain_id -> return (Chain_id.to_string l2_chain_id) in Evm_node_lib_dev.Kernel_config.make_l2 + ~eth_bootstrap_balance + ~tez_bootstrap_balance + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?minimum_base_fee_per_gas ?da_fee_per_byte ?sequencer_pool_address ?maximum_gas_per_transaction - ~boostrap_balance - ?bootstrap_accounts ?set_account_code ?world_state_path ~l2_chain_id @@ -1997,7 +2030,6 @@ let l2_chain_ids_arg = let make_kernel_config_command = let open Tezos_clic in - let open Lwt_result_syntax in command ~group:Groups.kernel ~desc:"Create a configuration for the kernel installer." @@ -2032,18 +2064,14 @@ let make_kernel_config_command = ~name:"max_blueprint_lookahead_in_seconds" ~placeholder:"500") (config_key_flag ~name:"remove_whitelist") - (Tezos_clic.default_arg - ~long:"bootstrap-balance" - ~doc:"Balance of the bootstrap accounts" - ~default:"9999000000000000000000" - ~placeholder:"9999000000000000000000" - @@ Tezos_clic.parameter (fun _ s -> return @@ Z.of_string s)) - bootstrap_account_arg - set_account_code + eth_bootstrap_balance_arg + eth_bootstrap_account_arg + tez_bootstrap_balance_arg + tez_bootstrap_account_arg (config_key_flag ~name:"enable_fa_bridge") - (config_key_flag ~name:"enable_dal") (config_key_arg ~name:"dal_slots" ~placeholder:"0,1,4,6,...")) - (args6 + (args8 + (config_key_flag ~name:"enable_dal") (config_key_flag ~name:"enable_multichain") l2_chain_ids_arg (config_key_arg @@ -2051,7 +2079,8 @@ let make_kernel_config_command = ~placeholder:"1000") (config_key_flag ~name:"enable_fast_withdrawal") (config_key_flag ~name:"enable_fast_fa_withdrawal") - evm_version_arg)) + evm_version_arg + set_account_code)) (prefixes ["make"; "kernel"; "installer"; "config"] @@ param ~name:"kernel config file" @@ -2077,22 +2106,26 @@ let make_kernel_config_command = maximum_gas_per_transaction, max_blueprint_lookahead_in_seconds, remove_whitelist, - boostrap_balance, - bootstrap_accounts, - set_account_code, + eth_bootstrap_balance, + eth_bootstrap_accounts, + tez_bootstrap_balance, + tez_bootstrap_accounts, enable_fa_bridge, - enable_dal, dal_slots ), - ( enable_multichain, + ( enable_dal, + enable_multichain, l2_chain_ids, max_delayed_inbox_blueprint_length, enable_fast_withdrawal, enable_fast_fa_withdrawal, - evm_version ) ) + evm_version, + set_account_code ) ) output () -> Evm_node_lib_dev.Kernel_config.make ~mainnet_compat + ~eth_bootstrap_balance + ~tez_bootstrap_balance ?l2_chain_ids ?kernel_root_hash ?chain_id @@ -2113,8 +2146,8 @@ let make_kernel_config_command = ?maximum_gas_per_transaction ?max_blueprint_lookahead_in_seconds ?remove_whitelist - ~boostrap_balance - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?enable_fa_bridge ?enable_dal ?dal_slots @@ -2209,7 +2242,7 @@ let fund_arg = "The address of an account to provide with funds in the sandbox (can be \ repeated to fund multiple accounts)." in - Tezos_clic.multiple_arg ~long ~doc ~placeholder:"0x..." Params.l2_address + Tezos_clic.multiple_arg ~long ~doc ~placeholder:"0x..." Params.eth_address let sandbox_config_args = Tezos_clic.args13 -- GitLab From 3595540ccb109710761b2b340b1da35f325697d0 Mon Sep 17 00:00:00 2001 From: Dibassi Brahima Date: Mon, 7 Apr 2025 09:18:02 +0200 Subject: [PATCH 2/3] Tezlink/Tezt : Refactor bootstrap account parameters to support both Ethereum and Tezos accounts --- etherlink/tezt/lib/evm_node.ml | 86 ++++++++++++++++++++------- etherlink/tezt/lib/evm_node.mli | 19 ++++-- etherlink/tezt/lib/setup.ml | 64 +++++++++++++------- etherlink/tezt/lib/setup.mli | 12 ++-- etherlink/tezt/lib/test_helpers.ml | 8 ++- etherlink/tezt/lib/test_helpers.mli | 3 +- etherlink/tezt/tests/eth_call.ml | 10 ++-- etherlink/tezt/tests/evm_rollup.ml | 80 +++++++++++++++---------- etherlink/tezt/tests/evm_sequencer.ml | 60 ++++++++++--------- tezt/tests/cloud/dal.ml | 8 +-- 10 files changed, 225 insertions(+), 125 deletions(-) diff --git a/etherlink/tezt/lib/evm_node.ml b/etherlink/tezt/lib/evm_node.ml index 9b38088696df..9b54b9fb2d06 100644 --- a/etherlink/tezt/lib/evm_node.ml +++ b/etherlink/tezt/lib/evm_node.ml @@ -34,24 +34,28 @@ type l2_setup = { l2_chain_id : int; l2_chain_family : string; world_state_path : string option; - bootstrap_accounts : string list option; + eth_bootstrap_accounts : string list option; + tez_bootstrap_accounts : Account.key list option; sequencer_pool_address : string option; minimum_base_fee_per_gas : Wei.t option; da_fee_per_byte : Wei.t option; maximum_gas_per_transaction : int64 option; } -let default_bootstrap_accounts = +let eth_default_bootstrap_accounts = List.map (fun account -> account.Eth_account.address) (Array.to_list Eth_account.bootstrap_accounts) +let tez_default_bootstrap_accounts = Array.to_list Account.Bootstrap.keys + let default_l2_setup ~l2_chain_id = { l2_chain_id; l2_chain_family = "EVM"; world_state_path = Some "/evm/world_state"; - bootstrap_accounts = Some default_bootstrap_accounts; + eth_bootstrap_accounts = Some eth_default_bootstrap_accounts; + tez_bootstrap_accounts = Some tez_default_bootstrap_accounts; sequencer_pool_address = None; minimum_base_fee_per_gas = None; da_fee_per_byte = None; @@ -1744,8 +1748,9 @@ let ten_years_in_seconds = 3600 * 24 * 365 * 10 |> Int64.of_int let make_kernel_installer_config ?(l2_chain_ids = []) ?max_delayed_inbox_blueprint_length ?(mainnet_compat = false) - ?(remove_whitelist = false) ?kernel_root_hash ?chain_id ?bootstrap_balance - ?bootstrap_accounts ?sequencer ?delayed_bridge ?ticketer ?administrator + ?(remove_whitelist = false) ?kernel_root_hash ?chain_id + ?eth_bootstrap_balance ?tez_bootstrap_balance ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?sequencer ?delayed_bridge ?ticketer ?administrator ?sequencer_governance ?kernel_governance ?kernel_security_governance ?minimum_base_fee_per_gas ?(da_fee_per_byte = Wei.zero) ?delayed_inbox_timeout ?delayed_inbox_min_levels ?sequencer_pool_address @@ -1830,25 +1835,45 @@ let make_kernel_installer_config ?(l2_chain_ids = []) "dal-slots" (fun l -> String.concat "," (List.map string_of_int l)) dal_slots - @ Cli_arg.optional_arg "bootstrap-balance" Wei.to_string bootstrap_balance + @ Cli_arg.optional_arg + "eth-bootstrap-balance" + Wei.to_string + eth_bootstrap_balance + @ Cli_arg.optional_arg + "tez-bootstrap-balance" + Tez.to_string + tez_bootstrap_balance @ Cli_arg.optional_arg "evm-version" Evm_version.to_string evm_version + @ (match tez_bootstrap_accounts with + | None -> [] + | Some tez_bootstrap_accounts -> + List.flatten + @@ List.map + (fun tez_bootstrap_account -> + [ + "--tez-bootstrap-account"; + tez_bootstrap_account.Account.public_key_hash; + ]) + tez_bootstrap_accounts) @ - match bootstrap_accounts with + match eth_bootstrap_accounts with | None -> [] - | Some bootstrap_accounts -> + | Some eth_bootstrap_accounts -> List.flatten @@ List.map - (fun bootstrap_account -> - ["--bootstrap-account"; bootstrap_account]) - bootstrap_accounts + (fun eth_bootstrap_account -> + ["--eth-bootstrap-account"; eth_bootstrap_account]) + eth_bootstrap_accounts in let process = Process.spawn (Uses.path Constant.octez_evm_node) cmd in Runnable.{value = process; run = Process.check} -let make_l2_kernel_installer_config ?chain_id ?chain_family ?bootstrap_balance - ?bootstrap_accounts ?minimum_base_fee_per_gas ?(da_fee_per_byte = Wei.zero) - ?sequencer_pool_address ?maximum_gas_per_transaction - ?(set_account_code = []) ?world_state_path ~output () = +let make_l2_kernel_installer_config ?chain_id ?chain_family + ?eth_bootstrap_balance ?tez_bootstrap_balance ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?minimum_base_fee_per_gas + ?(da_fee_per_byte = Wei.zero) ?sequencer_pool_address + ?maximum_gas_per_transaction ?(set_account_code = []) ?world_state_path + ~output () = let set_account_code = List.flatten @@ List.map @@ -1875,17 +1900,36 @@ let make_l2_kernel_installer_config ?chain_id ?chain_family ?bootstrap_balance "maximum-gas-per-transaction" Int64.to_string maximum_gas_per_transaction - @ Cli_arg.optional_arg "bootstrap-balance" Wei.to_string bootstrap_balance + @ Cli_arg.optional_arg + "eth-bootstrap-balance" + Wei.to_string + eth_bootstrap_balance + @ Cli_arg.optional_arg + "tez-bootstrap-balance" + Tez.to_string + tez_bootstrap_balance + @ (match tez_bootstrap_accounts with + | None -> [] + | Some tez_bootstrap_accounts -> + List.flatten + @@ List.map + (fun tez_bootstrap_account -> + [ + "--tez-bootstrap-account"; + tez_bootstrap_account.Account.public_key_hash; + ]) + tez_bootstrap_accounts) @ - match bootstrap_accounts with + match eth_bootstrap_accounts with | None -> [] - | Some bootstrap_accounts -> + | Some eth_bootstrap_accounts -> List.flatten @@ List.map - (fun bootstrap_account -> - ["--bootstrap-account"; bootstrap_account]) - bootstrap_accounts + (fun eth_bootstrap_account -> + ["--eth-bootstrap-account"; eth_bootstrap_account]) + eth_bootstrap_accounts in + let process = Process.spawn (Uses.path Constant.octez_evm_node) cmd in Runnable.{value = process; run = Process.check} diff --git a/etherlink/tezt/lib/evm_node.mli b/etherlink/tezt/lib/evm_node.mli index dc8dbd23f102..afa50925ea58 100644 --- a/etherlink/tezt/lib/evm_node.mli +++ b/etherlink/tezt/lib/evm_node.mli @@ -33,14 +33,17 @@ type l2_setup = { l2_chain_id : int; l2_chain_family : string; world_state_path : string option; - bootstrap_accounts : string list option; + eth_bootstrap_accounts : string list option; + tez_bootstrap_accounts : Account.key list option; sequencer_pool_address : string option; minimum_base_fee_per_gas : Wei.t option; da_fee_per_byte : Wei.t option; maximum_gas_per_transaction : int64 option; } -val default_bootstrap_accounts : string list +val eth_default_bootstrap_accounts : string list + +val tez_default_bootstrap_accounts : Account.key list val default_l2_setup : l2_chain_id:int -> l2_setup @@ -636,8 +639,10 @@ val wait_termination : t -> unit Lwt.t val make_l2_kernel_installer_config : ?chain_id:int -> ?chain_family:string -> - ?bootstrap_balance:Wei.t -> - ?bootstrap_accounts:string list -> + ?eth_bootstrap_balance:Wei.t -> + ?tez_bootstrap_balance:Tez.t -> + ?eth_bootstrap_accounts:string list -> + ?tez_bootstrap_accounts:Account.key list -> ?minimum_base_fee_per_gas:Wei.t -> ?da_fee_per_byte:Wei.t -> ?sequencer_pool_address:string -> @@ -657,8 +662,10 @@ val make_kernel_installer_config : ?remove_whitelist:bool -> ?kernel_root_hash:string -> ?chain_id:int -> - ?bootstrap_balance:Wei.t -> - ?bootstrap_accounts:string list -> + ?eth_bootstrap_balance:Wei.t -> + ?tez_bootstrap_balance:Tez.t -> + ?eth_bootstrap_accounts:string list -> + ?tez_bootstrap_accounts:Account.key list -> ?sequencer:string -> ?delayed_bridge:string -> ?ticketer:string -> diff --git a/etherlink/tezt/lib/setup.ml b/etherlink/tezt/lib/setup.ml index 6a4720794cc6..24729346271d 100644 --- a/etherlink/tezt/lib/setup.ml +++ b/etherlink/tezt/lib/setup.ml @@ -242,7 +242,8 @@ let run_new_observer_node ?(finalized_view = false) ?(patch_config = Fun.id) let setup_kernel_singlechain ~l1_contracts ?max_delayed_inbox_blueprint_length ~mainnet_compat ?delayed_inbox_timeout ?delayed_inbox_min_levels - ?(bootstrap_accounts = Evm_node.default_bootstrap_accounts) + ?(eth_bootstrap_accounts = Evm_node.eth_default_bootstrap_accounts) + ?(tez_bootstrap_accounts = Evm_node.tez_default_bootstrap_accounts) ?sequencer_pool_address ?da_fee_per_byte ?minimum_base_fee_per_gas ?maximum_allowed_ticks ?maximum_gas_per_transaction ?max_blueprint_lookahead_in_seconds ?enable_fa_bridge @@ -271,7 +272,8 @@ let setup_kernel_singlechain ~l1_contracts ?max_delayed_inbox_blueprint_length ?dal_slots ~enable_multichain:false ?max_blueprint_lookahead_in_seconds - ~bootstrap_accounts + ~eth_bootstrap_accounts + ~tez_bootstrap_accounts ~output:output_config ?evm_version ?enable_fa_bridge @@ -294,7 +296,8 @@ let generate_l2_kernel_config (l2_setup : Evm_node.l2_setup) = ?sequencer_pool_address:l2_setup.sequencer_pool_address ?minimum_base_fee_per_gas:l2_setup.minimum_base_fee_per_gas ?da_fee_per_byte:l2_setup.da_fee_per_byte - ?bootstrap_accounts:l2_setup.bootstrap_accounts + ?eth_bootstrap_accounts:l2_setup.eth_bootstrap_accounts + ?tez_bootstrap_accounts:l2_setup.tez_bootstrap_accounts ?world_state_path:l2_setup.world_state_path ~output:l2_config () @@ -316,7 +319,8 @@ let setup_kernel_multichain ~(l2_setups : Evm_node.l2_setup list) ~l1_contracts da_fee_per_byte, sequencer_pool_address, maximum_gas_per_transaction, - bootstrap_accounts ) = + eth_bootstrap_accounts, + tez_bootstrap_accounts ) = match l2_setups with | [ { @@ -324,17 +328,25 @@ let setup_kernel_multichain ~(l2_setups : Evm_node.l2_setup list) ~l1_contracts da_fee_per_byte; sequencer_pool_address; maximum_gas_per_transaction; - bootstrap_accounts; world_state_path; + eth_bootstrap_accounts; + tez_bootstrap_accounts; _; }; ] -> + let eth_bootstrap_accounts = + (* If `world_state_path` is `/evm/world_state`, it means the bootstrap accounts have already been written to that path. + To avoid duplicating this information in the configuration file — which would unnecessarily bloat the rollup origination + operation and cause an error — we skip including them here. *) + if world_state_path = Some "/evm/world_state" then None + else eth_bootstrap_accounts + in ( minimum_base_fee_per_gas, da_fee_per_byte, sequencer_pool_address, maximum_gas_per_transaction, - if world_state_path = Some "/evm/world_state" then None - else bootstrap_accounts ) + eth_bootstrap_accounts, + tez_bootstrap_accounts ) | _ -> assert false in (* In the kernel, the multichain notion was not introduced yet. *) @@ -368,7 +380,8 @@ let setup_kernel_multichain ~(l2_setups : Evm_node.l2_setup list) ~l1_contracts ?dal_slots ~enable_multichain:true ?max_blueprint_lookahead_in_seconds - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ~output:rollup_config ?enable_fa_bridge ?evm_version @@ -408,7 +421,8 @@ let setup_kernel ~enable_multichain ~l2_chains ~l1_contracts ?enable_fast_fa_withdrawal ?dal_slots ?max_blueprint_lookahead_in_seconds - ?bootstrap_accounts:chain_config.Evm_node.bootstrap_accounts + ?eth_bootstrap_accounts:chain_config.Evm_node.eth_bootstrap_accounts + ?tez_bootstrap_accounts:chain_config.Evm_node.tez_bootstrap_accounts ?enable_fa_bridge ?evm_version ~preimages_dir @@ -671,8 +685,9 @@ let setup_sequencer ?max_delayed_inbox_blueprint_length ?next_wasm_runtime ?max_blueprints_ahead ?max_blueprints_catchup ?catchup_cooldown ?delayed_inbox_timeout ?delayed_inbox_min_levels ?max_number_of_chunks ?commitment_period ?challenge_window - ?(bootstrap_accounts = Evm_node.default_bootstrap_accounts) ?sequencer - ?sequencer_pool_address ?kernel ?da_fee ?minimum_base_fee_per_gas + ?(eth_bootstrap_accounts = Evm_node.eth_default_bootstrap_accounts) + ?(tez_bootstrap_accounts = Evm_node.tez_default_bootstrap_accounts) + ?sequencer ?sequencer_pool_address ?kernel ?da_fee ?minimum_base_fee_per_gas ?preimages_dir ?maximum_allowed_ticks ?maximum_gas_per_transaction ?max_blueprint_lookahead_in_seconds ?enable_fa_bridge ?enable_fast_withdrawal ?enable_fast_fa_withdrawal ?threshold_encryption @@ -688,7 +703,8 @@ let setup_sequencer ?max_delayed_inbox_blueprint_length ?next_wasm_runtime { (Evm_node.default_l2_setup ~l2_chain_id:1) with sequencer_pool_address; - bootstrap_accounts = Some bootstrap_accounts; + eth_bootstrap_accounts = Some eth_bootstrap_accounts; + tez_bootstrap_accounts = Some tez_bootstrap_accounts; da_fee_per_byte = da_fee; minimum_base_fee_per_gas; maximum_gas_per_transaction; @@ -745,8 +761,9 @@ let register_multichain_test ~__FILE__ ?max_delayed_inbox_blueprint_length ?time_between_blocks ?max_blueprints_lag ?max_blueprints_ahead ?max_blueprints_catchup ?catchup_cooldown ?delayed_inbox_timeout ?delayed_inbox_min_levels ?max_number_of_chunks - ?(bootstrap_accounts = Evm_node.default_bootstrap_accounts) ?sequencer - ?sequencer_pool_address ~kernel ?da_fee ?minimum_base_fee_per_gas + ?(eth_bootstrap_accounts = Evm_node.eth_default_bootstrap_accounts) + ?(tez_bootstrap_accounts = Evm_node.tez_default_bootstrap_accounts) + ?sequencer ?sequencer_pool_address ~kernel ?da_fee ?minimum_base_fee_per_gas ?preimages_dir ?maximum_allowed_ticks ?maximum_gas_per_transaction ?max_blueprint_lookahead_in_seconds ?enable_fa_bridge ?enable_fast_withdrawal ?enable_fast_fa_withdrawal ?commitment_period @@ -780,7 +797,8 @@ let register_multichain_test ~__FILE__ ?max_delayed_inbox_blueprint_length sequencer_pool_address; minimum_base_fee_per_gas; maximum_gas_per_transaction; - bootstrap_accounts = Some bootstrap_accounts; + eth_bootstrap_accounts = Some eth_bootstrap_accounts; + tez_bootstrap_accounts = Some tez_bootstrap_accounts; }; ] | Some l2_chains -> l2_chains @@ -866,8 +884,9 @@ let register_test ~__FILE__ ?max_delayed_inbox_blueprint_length ?time_between_blocks ?max_blueprints_lag ?max_blueprints_ahead ?max_blueprints_catchup ?catchup_cooldown ?delayed_inbox_timeout ?delayed_inbox_min_levels ?max_number_of_chunks - ?(bootstrap_accounts = Evm_node.default_bootstrap_accounts) ?sequencer - ?sequencer_pool_address ~kernel ?da_fee ?minimum_base_fee_per_gas + ?(eth_bootstrap_accounts = Evm_node.eth_default_bootstrap_accounts) + ?(tez_bootstrap_accounts = Evm_node.tez_default_bootstrap_accounts) + ?sequencer ?sequencer_pool_address ~kernel ?da_fee ?minimum_base_fee_per_gas ?preimages_dir ?maximum_allowed_ticks ?maximum_gas_per_transaction ?max_blueprint_lookahead_in_seconds ?enable_fa_bridge ?enable_fast_withdrawal ?enable_fast_fa_withdrawal ?commitment_period @@ -892,7 +911,8 @@ let register_test ~__FILE__ ?max_delayed_inbox_blueprint_length ?delayed_inbox_timeout ?delayed_inbox_min_levels ?max_number_of_chunks - ~bootstrap_accounts + ~eth_bootstrap_accounts + ~tez_bootstrap_accounts ?sequencer ?sequencer_pool_address ~kernel @@ -931,8 +951,9 @@ let register_test_for_kernels ~__FILE__ ?max_delayed_inbox_blueprint_length ?time_between_blocks ?max_blueprints_lag ?max_blueprints_ahead ?max_blueprints_catchup ?catchup_cooldown ?delayed_inbox_timeout ?delayed_inbox_min_levels ?max_number_of_chunks - ?(bootstrap_accounts = Evm_node.default_bootstrap_accounts) ?sequencer - ?sequencer_pool_address ?(kernels = Kernel.all) ?da_fee + ?(eth_bootstrap_accounts = Evm_node.eth_default_bootstrap_accounts) + ?(tez_bootstrap_accounts = Evm_node.tez_default_bootstrap_accounts) + ?sequencer ?sequencer_pool_address ?(kernels = Kernel.all) ?da_fee ?minimum_base_fee_per_gas ?preimages_dir ?maximum_allowed_ticks ?maximum_gas_per_transaction ?max_blueprint_lookahead_in_seconds ?enable_fa_bridge ?rollup_history_mode ?commitment_period ?challenge_window @@ -958,7 +979,8 @@ let register_test_for_kernels ~__FILE__ ?max_delayed_inbox_blueprint_length ?delayed_inbox_timeout ?delayed_inbox_min_levels ?max_number_of_chunks - ~bootstrap_accounts + ~eth_bootstrap_accounts + ~tez_bootstrap_accounts ?sequencer ?sequencer_pool_address ~kernel diff --git a/etherlink/tezt/lib/setup.mli b/etherlink/tezt/lib/setup.mli index 60c6073ab54d..03101b81aae5 100644 --- a/etherlink/tezt/lib/setup.mli +++ b/etherlink/tezt/lib/setup.mli @@ -91,7 +91,8 @@ val register_test : ?delayed_inbox_timeout:int -> ?delayed_inbox_min_levels:int -> ?max_number_of_chunks:int -> - ?bootstrap_accounts:string list -> + ?eth_bootstrap_accounts:string list -> + ?tez_bootstrap_accounts:Account.key list -> ?sequencer:Account.key -> ?sequencer_pool_address:string -> kernel:Kernel.t -> @@ -140,7 +141,8 @@ val register_multichain_test : ?delayed_inbox_timeout:int -> ?delayed_inbox_min_levels:int -> ?max_number_of_chunks:int -> - ?bootstrap_accounts:string list -> + ?eth_bootstrap_accounts:string list -> + ?tez_bootstrap_accounts:Account.key list -> ?sequencer:Account.key -> ?sequencer_pool_address:string -> kernel:Kernel.t -> @@ -192,7 +194,8 @@ val register_test_for_kernels : ?delayed_inbox_timeout:int -> ?delayed_inbox_min_levels:int -> ?max_number_of_chunks:int -> - ?bootstrap_accounts:string list -> + ?eth_bootstrap_accounts:string list -> + ?tez_bootstrap_accounts:Account.key list -> ?sequencer:Account.key -> ?sequencer_pool_address:string -> ?kernels:Kernel.t list -> @@ -243,7 +246,8 @@ val setup_sequencer : ?max_number_of_chunks:int -> ?commitment_period:int -> ?challenge_window:int -> - ?bootstrap_accounts:string list -> + ?eth_bootstrap_accounts:string list -> + ?tez_bootstrap_accounts:Account.key list -> ?sequencer:Account.key -> ?sequencer_pool_address:string -> ?kernel:Uses.t -> diff --git a/etherlink/tezt/lib/test_helpers.ml b/etherlink/tezt/lib/test_helpers.ml index f123bcb227e2..65602710099b 100644 --- a/etherlink/tezt/lib/test_helpers.ml +++ b/etherlink/tezt/lib/test_helpers.ml @@ -425,10 +425,11 @@ let init_sequencer_sandbox ?maximum_gas_per_transaction ?genesis_timestamp ?tx_pool_tx_per_addr_limit ?set_account_code ?da_fee_per_byte ?minimum_base_fee_per_gas ?history_mode ?patch_config ?(kernel = Constant.WASM.evm_kernel) ?evm_version - ?(bootstrap_accounts = + ?(eth_bootstrap_accounts = List.map (fun account -> account.Eth_account.address) - (Array.to_list Eth_account.bootstrap_accounts)) () = + (Array.to_list Eth_account.bootstrap_accounts)) + ?(tez_bootstrap_accounts = Array.to_list Account.Bootstrap.keys) () = let wallet_dir = Temp.dir "wallet" in let output_config = Temp.file "config.yaml" in let preimages_dir = Temp.dir "wasm_2_0_0" in @@ -440,7 +441,8 @@ let init_sequencer_sandbox ?maximum_gas_per_transaction ?genesis_timestamp ?da_fee_per_byte ?minimum_base_fee_per_gas ~output:output_config - ~bootstrap_accounts + ~eth_bootstrap_accounts + ~tez_bootstrap_accounts ?evm_version () in diff --git a/etherlink/tezt/lib/test_helpers.mli b/etherlink/tezt/lib/test_helpers.mli index 7f75cd7561ab..091075fba59c 100644 --- a/etherlink/tezt/lib/test_helpers.mli +++ b/etherlink/tezt/lib/test_helpers.mli @@ -247,7 +247,8 @@ val init_sequencer_sandbox : ?patch_config:(JSON.t -> JSON.t) -> ?kernel:Uses.t -> ?evm_version:Evm_version.t -> - ?bootstrap_accounts:string list -> + ?eth_bootstrap_accounts:string list -> + ?tez_bootstrap_accounts:Account.key list -> unit -> Evm_node.t Lwt.t diff --git a/etherlink/tezt/tests/eth_call.ml b/etherlink/tezt/tests/eth_call.ml index a3d0b50107e7..d0bc1e9783e0 100644 --- a/etherlink/tezt/tests/eth_call.ml +++ b/etherlink/tezt/tests/eth_call.ml @@ -20,14 +20,16 @@ open Setup open Test_helpers -let register ?genesis_timestamp ?bootstrap_accounts ?(kernels = Kernel.all) - ?preimages_dir ?maximum_allowed_ticks ?enable_fa_bridge ?rollup_history_mode - ?additional_uses ~title ~tags body protocols = +let register ?genesis_timestamp ?eth_bootstrap_accounts ?tez_bootstrap_accounts + ?(kernels = Kernel.all) ?preimages_dir ?maximum_allowed_ticks + ?enable_fa_bridge ?rollup_history_mode ?additional_uses ~title ~tags body + protocols = register_test_for_kernels ~__FILE__ ~time_between_blocks:Nothing ?genesis_timestamp - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ~kernels ?preimages_dir ?maximum_allowed_ticks diff --git a/etherlink/tezt/tests/evm_rollup.ml b/etherlink/tezt/tests/evm_rollup.ml index 9824d3bb7156..bb2a6c51eafc 100644 --- a/etherlink/tezt/tests/evm_rollup.ml +++ b/etherlink/tezt/tests/evm_rollup.ml @@ -298,10 +298,11 @@ let setup_evm_kernel ?additional_config ?(setup_kernel_root_hash = true) ?(kernel = Kernel.Latest) ?evm_version ?(originator_key = Constant.bootstrap1.public_key_hash) ?(rollup_operator_key = Constant.bootstrap1.public_key_hash) ?chain_id - ?(bootstrap_accounts = + ?(eth_bootstrap_accounts = List.map (fun account -> account.Eth_account.address) (Array.to_list Eth_account.bootstrap_accounts)) + ?(tez_bootstrap_accounts = Array.to_list Account.Bootstrap.keys) ?(with_administrator = true) ?da_fee_per_byte ?minimum_base_fee_per_gas ~admin ?sequencer_admin ?commitment_period ?challenge_window ?timestamp ?tx_pool_timeout_limit ?tx_pool_addr_limit ?tx_pool_tx_per_addr_limit @@ -368,7 +369,8 @@ let setup_evm_kernel ?additional_config ?(setup_kernel_root_hash = true) ~mainnet_compat:false ~remove_whitelist:Option.(is_some whitelist) ?kernel_root_hash - ~bootstrap_accounts + ~eth_bootstrap_accounts + ~tez_bootstrap_accounts ?da_fee_per_byte ?minimum_base_fee_per_gas ?ticketer @@ -528,11 +530,12 @@ let setup_evm_kernel ?additional_config ?(setup_kernel_root_hash = true) let register_test ~title ~tags ?(kernels = Kernel.all) ?additional_config ?admin ?(additional_uses = []) ?commitment_period ?challenge_window - ?bootstrap_accounts ?whitelist ?da_fee_per_byte ?minimum_base_fee_per_gas - ?rollup_operator_key ?maximum_allowed_ticks ?restricted_rpcs ~setup_mode - ~enable_dal ?(dal_slots = if enable_dal then Some [4] else None) - ~enable_multichain ?websockets ?enable_fast_withdrawal ?evm_version - ?enable_tx_queue f protocols = + ?eth_bootstrap_accounts ?tez_bootstrap_accounts ?whitelist ?da_fee_per_byte + ?minimum_base_fee_per_gas ?rollup_operator_key ?maximum_allowed_ticks + ?restricted_rpcs ~setup_mode ~enable_dal + ?(dal_slots = if enable_dal then Some [4] else None) ~enable_multichain + ?websockets ?enable_fast_withdrawal ?evm_version ?enable_tx_queue f + protocols = let extra_tag = match setup_mode with | Setup_proxy -> "proxy" @@ -575,7 +578,8 @@ let register_test ~title ~tags ?(kernels = Kernel.all) ?additional_config ?admin ?whitelist ?commitment_period ?challenge_window - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?da_fee_per_byte ?minimum_base_fee_per_gas ?rollup_operator_key @@ -597,10 +601,10 @@ let register_test ~title ~tags ?(kernels = Kernel.all) ?additional_config ?admin kernels let register_proxy ~title ~tags ?kernels ?additional_uses ?additional_config - ?admin ?commitment_period ?challenge_window ?bootstrap_accounts - ?da_fee_per_byte ?minimum_base_fee_per_gas ?whitelist ?rollup_operator_key - ?maximum_allowed_ticks ?restricted_rpcs ?websockets ?enable_fast_withdrawal - ?evm_version f protocols = + ?admin ?commitment_period ?challenge_window ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?da_fee_per_byte ?minimum_base_fee_per_gas + ?whitelist ?rollup_operator_key ?maximum_allowed_ticks ?restricted_rpcs + ?websockets ?enable_fast_withdrawal ?evm_version f protocols = let register ~enable_dal ~enable_multichain : unit = register_test ~title @@ -611,7 +615,8 @@ let register_proxy ~title ~tags ?kernels ?additional_uses ?additional_config ?admin ?commitment_period ?challenge_window - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?da_fee_per_byte ?minimum_base_fee_per_gas ?whitelist @@ -634,8 +639,8 @@ let register_proxy ~title ~tags ?kernels ?additional_uses ?additional_config let register_sequencer ?(return_sequencer = false) ~title ~tags ?kernels ?additional_uses ?additional_config ?admin ?commitment_period - ?challenge_window ?bootstrap_accounts ?da_fee_per_byte - ?minimum_base_fee_per_gas ?time_between_blocks ?whitelist + ?challenge_window ?eth_bootstrap_accounts ?tez_bootstrap_accounts + ?da_fee_per_byte ?minimum_base_fee_per_gas ?time_between_blocks ?whitelist ?rollup_operator_key ?maximum_allowed_ticks ?restricted_rpcs ?max_blueprints_ahead ?websockets ?evm_version ?genesis_timestamp ?enable_tx_queue f protocols = @@ -649,7 +654,8 @@ let register_sequencer ?(return_sequencer = false) ~title ~tags ?kernels ?admin ?commitment_period ?challenge_window - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?da_fee_per_byte ?minimum_base_fee_per_gas ?whitelist @@ -679,10 +685,11 @@ let register_sequencer ?(return_sequencer = false) ~title ~tags ?kernels register ~enable_dal:true ~enable_multichain:true let register_both ~title ~tags ?kernels ?additional_uses ?additional_config - ?admin ?commitment_period ?challenge_window ?bootstrap_accounts - ?da_fee_per_byte ?minimum_base_fee_per_gas ?time_between_blocks ?whitelist - ?rollup_operator_key ?maximum_allowed_ticks ?restricted_rpcs - ?max_blueprints_ahead ?websockets ?evm_version f protocols : unit = + ?admin ?commitment_period ?challenge_window ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?da_fee_per_byte ?minimum_base_fee_per_gas + ?time_between_blocks ?whitelist ?rollup_operator_key ?maximum_allowed_ticks + ?restricted_rpcs ?max_blueprints_ahead ?websockets ?evm_version f protocols + : unit = register_proxy ~title ~tags @@ -692,7 +699,8 @@ let register_both ~title ~tags ?kernels ?additional_uses ?additional_config ?admin ?commitment_period ?challenge_window - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?da_fee_per_byte ?minimum_base_fee_per_gas ?whitelist @@ -712,7 +720,8 @@ let register_both ~title ~tags ?kernels ?additional_uses ?additional_config ?admin ?commitment_period ?challenge_window - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?da_fee_per_byte ?minimum_base_fee_per_gas ?time_between_blocks @@ -976,7 +985,7 @@ let test_rpc_getBlockReceipts_aux ?websocket {evm_node; produce_block; _} = let test_rpc_getBlockReceipts = register_both ~time_between_blocks:Nothing - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~tags:["evm"; "rpc"; "get_block_receipts"] ~title:"RPC method eth_getBlockReceipts" ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx @@ -2091,7 +2100,7 @@ let test_simulate = let test_full_blocks = register_proxy - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~tags:["evm"; "full_blocks"] ~title: "Check `eth_getBlockByNumber` with full blocks returns the correct \ @@ -2221,7 +2230,7 @@ let test_inject_100_transactions = register_proxy ~tags:["evm"; "bigger_blocks"] ~title:"Check blocks can contain more than 64 transactions" - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx @@ fun ~protocol:_ ~evm_setup:{evm_node; produce_block; _} -> (* Retrieves all the messages and prepare them for the current rollup. *) @@ -3265,7 +3274,7 @@ let test_rpc_getTransactionByBlockHashAndIndex = ~tags:["evm"; "rpc"; "get_transaction_by"; "block_hash_and_index"] ~title:"RPC method eth_getTransactionByBlockHashAndIndex" ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address @@ fun ~protocol:_ -> test_rpc_getTransactionByBlockArgAndIndex ~by:`Hash let test_rpc_getTransactionByBlockNumberAndIndex = @@ -3273,7 +3282,7 @@ let test_rpc_getTransactionByBlockNumberAndIndex = ~tags:["evm"; "rpc"; "get_transaction_by"; "block_number_and_index"] ~title:"RPC method eth_getTransactionByBlockNumberAndIndex" ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address @@ fun ~protocol:_ -> test_rpc_getTransactionByBlockArgAndIndex ~by:`Number type storage_migration_results = { @@ -3291,12 +3300,12 @@ type storage_migration_results = { on master. - everytime a new path/rpc/object is stored in the kernel, a new sanity check MUST be generated. *) -let gen_kernel_migration_test ~from ~to_ ?bootstrap_accounts ?chain_id +let gen_kernel_migration_test ~from ~to_ ?eth_bootstrap_accounts ?chain_id ?(admin = Constant.bootstrap5) ~scenario_prior ~scenario_after protocol = let* evm_setup = setup_evm_kernel ?chain_id - ?bootstrap_accounts + ?eth_bootstrap_accounts ~da_fee_per_byte:Wei.zero ~minimum_base_fee_per_gas:(Wei.of_string "21000") ~kernel:from @@ -3528,7 +3537,7 @@ let test_cannot_prepayed_leads_to_no_inclusion = ~tags:["evm"; "prepay"; "inclusion"] ~title: "Not being able to prepay a transaction leads to it not being included." - ~bootstrap_accounts:[] + ~eth_bootstrap_accounts:[] ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx (* No bootstrap accounts, so no one has funds. *) @@ fun ~protocol:_ ~evm_setup:{evm_node; _} -> @@ -3828,7 +3837,7 @@ let test_transaction_storage_before_and_after_migration = gen_kernel_migration_test ~from:Ghostnet ~to_:Latest - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~scenario_prior ~scenario_after protocol @@ -3923,7 +3932,7 @@ let test_rpc_getBlockTransactionCountBy = ~title: "RPC methods eth_getBlockTransactionCountByHash and \ eth_getBlockTransactionCountByNumber" - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx @@ fun ~protocol:_ ~evm_setup -> let {produce_block; evm_node; _} = evm_setup in @@ -4519,6 +4528,11 @@ let test_block_hash_regression = genesis timestamp can be found in tezt/lib_tezos/client.ml *) let* {evm_node; _} = setup_evm_kernel + ~eth_bootstrap_accounts: + (List.map + (fun account -> account.Eth_account.address) + (Array.to_list Eth_account.bootstrap_accounts) + @ Eth_account.lots_of_address) ~setup_mode: (Setup_sequencer { @@ -5661,7 +5675,7 @@ let test_reveal_storage = ~admin:None ~additional_config ~force_install_kernel:false - ~bootstrap_accounts:[] + ~eth_bootstrap_accounts:[] protocol in diff --git a/etherlink/tezt/tests/evm_sequencer.ml b/etherlink/tezt/tests/evm_sequencer.ml index f428cbb08f3f..cb2707f4ee64 100644 --- a/etherlink/tezt/tests/evm_sequencer.ml +++ b/etherlink/tezt/tests/evm_sequencer.ml @@ -244,12 +244,13 @@ let register_all ?max_delayed_inbox_blueprint_length ?sequencer_rpc_port ?sequencer_private_rpc_port ?genesis_timestamp ?time_between_blocks ?max_blueprints_lag ?max_blueprints_ahead ?max_blueprints_catchup ?catchup_cooldown ?delayed_inbox_timeout ?delayed_inbox_min_levels - ?max_number_of_chunks ?bootstrap_accounts ?sequencer ?sequencer_pool_address - ?(kernels = Kernel.all) ?da_fee ?minimum_base_fee_per_gas ?preimages_dir - ?maximum_allowed_ticks ?maximum_gas_per_transaction - ?max_blueprint_lookahead_in_seconds ?enable_fa_bridge ?rollup_history_mode - ?commitment_period ?challenge_window ?additional_uses ?rpc_server - ?websockets ?enable_fast_withdrawal ?enable_fast_fa_withdrawal ?history_mode + ?max_number_of_chunks ?eth_bootstrap_accounts ?tez_bootstrap_accounts + ?sequencer ?sequencer_pool_address ?(kernels = Kernel.all) ?da_fee + ?minimum_base_fee_per_gas ?preimages_dir ?maximum_allowed_ticks + ?maximum_gas_per_transaction ?max_blueprint_lookahead_in_seconds + ?enable_fa_bridge ?rollup_history_mode ?commitment_period ?challenge_window + ?additional_uses ?rpc_server ?websockets ?enable_fast_withdrawal + ?enable_fast_fa_withdrawal ?history_mode ?(use_threshold_encryption = default_threshold_encryption_registration) ?(use_dal = default_dal_registration) ?(use_multichain = default_multichain_registration) ?enable_tx_queue @@ -306,7 +307,8 @@ let register_all ?max_delayed_inbox_blueprint_length ?sequencer_rpc_port ?delayed_inbox_timeout ?delayed_inbox_min_levels ?max_number_of_chunks - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?sequencer ?sequencer_pool_address ~kernels @@ -344,12 +346,13 @@ let register_multichain_all ?max_delayed_inbox_blueprint_length ?sequencer_rpc_port ?sequencer_private_rpc_port ?genesis_timestamp ?time_between_blocks ?max_blueprints_lag ?max_blueprints_ahead ?max_blueprints_catchup ?catchup_cooldown ?delayed_inbox_timeout - ?delayed_inbox_min_levels ?max_number_of_chunks ?bootstrap_accounts - ?sequencer ?sequencer_pool_address ?da_fee ?minimum_base_fee_per_gas - ?preimages_dir ?maximum_allowed_ticks ?maximum_gas_per_transaction - ?max_blueprint_lookahead_in_seconds ?enable_fa_bridge ?rollup_history_mode - ?commitment_period ?challenge_window ?additional_uses ?rpc_server - ?websockets ?enable_fast_withdrawal ?history_mode + ?delayed_inbox_min_levels ?max_number_of_chunks ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?sequencer ?sequencer_pool_address ?da_fee + ?minimum_base_fee_per_gas ?preimages_dir ?maximum_allowed_ticks + ?maximum_gas_per_transaction ?max_blueprint_lookahead_in_seconds + ?enable_fa_bridge ?rollup_history_mode ?commitment_period ?challenge_window + ?additional_uses ?rpc_server ?websockets ?enable_fast_withdrawal + ?history_mode ?(use_threshold_encryption = default_threshold_encryption_registration) ?(use_dal = default_dal_registration) ~l2_setups ~title ~tags body protocols = @@ -389,7 +392,8 @@ let register_multichain_all ?max_delayed_inbox_blueprint_length ?delayed_inbox_timeout ?delayed_inbox_min_levels ?max_number_of_chunks - ?bootstrap_accounts + ?eth_bootstrap_accounts + ?tez_bootstrap_accounts ?sequencer ?sequencer_pool_address ?da_fee @@ -683,7 +687,7 @@ let test_make_l2_kernel_installer_config chain_family = ~chain_id:chain_id_1 ~chain_family ~world_state_path - ~bootstrap_accounts:[address] + ~eth_bootstrap_accounts:[address] ~output:l2_config_1 () in @@ -691,7 +695,7 @@ let test_make_l2_kernel_installer_config chain_family = Evm_node.make_l2_kernel_installer_config ~chain_id:chain_id_2 ~chain_family - ~bootstrap_accounts:[address] + ~eth_bootstrap_accounts:[address] ~output:l2_config_2 () in @@ -5943,7 +5947,7 @@ let test_external_transaction_to_delayed_inbox_fails = register_all ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx ~time_between_blocks:Nothing - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~tags:["evm"; "sequencer"; "delayed_inbox"; "external"] ~title:"Sending an external transaction to the delayed inbox fails" @@ fun {client; sequencer; proxy; sc_rollup_node; _} _protocol -> @@ -5971,7 +5975,7 @@ let test_proxy_node_can_forward_to_evm_endpoint = register_all ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx ~time_between_blocks:Nothing - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~tags:["proxy"; "evm_node_endpoint"] ~title:"Proxy node can forward transactions to another EVM node" @@ fun {sequencer; proxy; sc_rollup_node; client; _} _protocol -> @@ -6910,7 +6914,7 @@ let test_blueprint_is_limited_in_size = ~time_between_blocks:Nothing ~max_number_of_chunks:2 ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~tags:["evm"; "sequencer"; "blueprint"; "limit"] ~title: "Checks the sequencer doesn't produce blueprint bigger than the given \ @@ -6986,7 +6990,7 @@ let test_blueprint_is_limited_in_size = let test_blueprint_limit_with_delayed_inbox = register_all - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~sequencer:Constant.bootstrap1 ~time_between_blocks:Nothing ~max_number_of_chunks:2 @@ -10201,7 +10205,7 @@ let test_rpc_mode_while_block_are_produced = let test_batch_limit_size_rpc = register_all - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx ~title:"Test batch size limit" ~tags:["rpc"; "batch_limit"] @@ -10342,7 +10346,7 @@ let test_describe_endpoint = let test_relay_restricted_rpcs = register_all - ~bootstrap_accounts:Eth_account.lots_of_address + ~eth_bootstrap_accounts:Eth_account.lots_of_address ~minimum_base_fee_per_gas:base_fee_for_hardcoded_tx ~time_between_blocks:Nothing ~kernels:[Latest] @@ -10668,7 +10672,7 @@ let test_websocket_rpcs = ~tags:["evm"; "rpc"; "websocket"] ~title:"RPC methods over websocket" ~time_between_blocks:Nothing - ~bootstrap_accounts: + ~eth_bootstrap_accounts: ((Array.to_list Eth_account.bootstrap_accounts |> List.map (fun a -> a.Eth_account.address)) @ Eth_account.lots_of_address) @@ -10742,7 +10746,7 @@ let test_websocket_subscription_rpcs_cant_be_called_via_http_requests = ~title: "Check that subscriptions rpcs can't be called via regular http requests" ~time_between_blocks:Nothing - ~bootstrap_accounts: + ~eth_bootstrap_accounts: ((Array.to_list Eth_account.bootstrap_accounts |> List.map (fun a -> a.Eth_account.address)) @ Eth_account.lots_of_address) @@ -10801,7 +10805,7 @@ let test_websocket_newHeads_event = ~tags:["evm"; "rpc"; "websocket"; "new_heads"] ~title:"Check that websocket event `newHeads` is behaving correctly" ~time_between_blocks:Nothing - ~bootstrap_accounts: + ~eth_bootstrap_accounts: ((Array.to_list Eth_account.bootstrap_accounts |> List.map (fun a -> a.Eth_account.address)) @ Eth_account.lots_of_address) @@ -10837,7 +10841,7 @@ let test_websocket_cleanup = ~tags:["evm"; "rpc"; "websocket"; "cleanup"] ~title:"Check that websocket subscriptions are cleaned up on close" ~time_between_blocks:Nothing - ~bootstrap_accounts: + ~eth_bootstrap_accounts: ((Array.to_list Eth_account.bootstrap_accounts |> List.map (fun a -> a.Eth_account.address)) @ Eth_account.lots_of_address) @@ -11114,7 +11118,7 @@ let test_websocket_newPendingTransactions_event = "Check that websocket event `newPendingTransactions` is behaving \ correctly" ~time_between_blocks:Nothing - ~bootstrap_accounts: + ~eth_bootstrap_accounts: ((Array.to_list Eth_account.bootstrap_accounts |> List.map (fun a -> a.Eth_account.address)) @ Eth_account.lots_of_address) @@ -11164,7 +11168,7 @@ let test_websocket_logs_event = ~tags:["evm"; "rpc"; "websocket"; "logs"] ~title:"Check that websocket event `logs` is behaving correctly" ~time_between_blocks:Nothing - ~bootstrap_accounts: + ~eth_bootstrap_accounts: ((Array.to_list Eth_account.bootstrap_accounts |> List.map (fun a -> a.Eth_account.address)) @ Eth_account.lots_of_address) diff --git a/tezt/tests/cloud/dal.ml b/tezt/tests/cloud/dal.ml index 04dd0c9bdf27..2b41d7ba31c0 100644 --- a/tezt/tests/cloud/dal.ml +++ b/tezt/tests/cloud/dal.ml @@ -2709,7 +2709,7 @@ let init_etherlink_operator_setup cloud configuration etherlink_configuration (* A configuration is generated locally by the orchestrator. The resulting kernel will be pushed to Etherlink. *) let output_config = Temp.file "config.yaml" in - let bootstrap_accounts = + let eth_bootstrap_accounts = Tezt_etherlink.Eth_account.bootstrap_accounts |> Array.to_list |> List.map (fun account -> account.Tezt_etherlink.Eth_account.address) in @@ -2718,7 +2718,7 @@ let init_etherlink_operator_setup cloud configuration etherlink_configuration let () = toplog "Init Etherlink: configuring the kernel" in Tezt_etherlink.Evm_node.make_kernel_installer_config ?sequencer - ~bootstrap_accounts + ~eth_bootstrap_accounts ~output:output_config ~enable_dal:(Option.is_some dal_slots) ?chain_id:etherlink_configuration.chain_id @@ -2879,7 +2879,7 @@ let init_etherlink_producer_setup operator name ~bootstrap ~rpc_external cloud (* A configuration is generated locally by the orchestrator. The resulting kernel will be pushed to Etherlink. *) let output_config = Temp.file "config.yaml" in - let bootstrap_accounts = + let eth_bootstrap_accounts = Tezt_etherlink.Eth_account.bootstrap_accounts |> Array.to_list |> List.map (fun account -> account.Tezt_etherlink.Eth_account.address) in @@ -2889,7 +2889,7 @@ let init_etherlink_producer_setup operator name ~bootstrap ~rpc_external cloud in Tezt_etherlink.Evm_node.make_kernel_installer_config ?sequencer - ~bootstrap_accounts + ~eth_bootstrap_accounts ~output:output_config () in -- GitLab From a0617dc62c2064073f1091ca2af74be86439f7a7 Mon Sep 17 00:00:00 2001 From: Dibassi Brahima Date: Mon, 7 Apr 2025 16:37:33 +0200 Subject: [PATCH 3/3] Tezlink/Tezt : Add test for Tezlink bootstrap accounts --- etherlink/tezt/tests/evm_sequencer.ml | 29 ++++++++++- ...pha- Regression test for L2 block hash.out | 2 +- .../evm_sequencer.ml/EVM Node- man.out | 49 ++++++++++++------- 3 files changed, 59 insertions(+), 21 deletions(-) diff --git a/etherlink/tezt/tests/evm_sequencer.ml b/etherlink/tezt/tests/evm_sequencer.ml index cb2707f4ee64..3e0a1a5e1aa3 100644 --- a/etherlink/tezt/tests/evm_sequencer.ml +++ b/etherlink/tezt/tests/evm_sequencer.ml @@ -8896,6 +8896,32 @@ let test_multichain_feature_flag = "Multichain feature flag in the durable storage is %L, expected %R" ; unit +let test_tezlink_bootstrap_accounts = + register_tezlink_test + ~tags:["bootstrap_accounts"] + ~title:"Check the tezlink bootstrap accounts are set in storage" + @@ fun {sequencer; _} _protocol -> + let* () = + Lwt_list.iter_p + (fun account -> + let addr = + Evm_node_lib_dev_encoding.Tezos_types.address_of_b58exn + account.Account.public_key_hash + in + let path = + sf + "/tezlink/context/contracts/index/%s/balance" + (Evm_node_lib_dev_encoding.Tezos_types.address_to_hex_exn addr) + in + let*@ balance = Rpc.state_value sequencer path in + Check.(Option.is_some balance = true) + Check.bool + ~error_msg:(sf "Expected to have a value at %s" path) ; + unit) + Evm_node.tez_default_bootstrap_accounts + in + unit + let test_fast_withdrawal_feature_flag = register_all ~tags:["fast_withdrawal"; "feature_flag"] @@ -13212,4 +13238,5 @@ let () = test_tezlink_protocols [Alpha] ; test_tezlink_version [Alpha] ; test_tezlink_constants [Alpha] ; - test_tezlink_produceBlock [Alpha] + test_tezlink_produceBlock [Alpha] ; + test_tezlink_bootstrap_accounts [Alpha] diff --git a/etherlink/tezt/tests/expected/evm_rollup.ml/Alpha- Regression test for L2 block hash.out b/etherlink/tezt/tests/expected/evm_rollup.ml/Alpha- Regression test for L2 block hash.out index 6c75227bd680..6d6ef6b7063b 100644 --- a/etherlink/tezt/tests/expected/evm_rollup.ml/Alpha- Regression test for L2 block hash.out +++ b/etherlink/tezt/tests/expected/evm_rollup.ml/Alpha- Regression test for L2 block hash.out @@ -1 +1 @@ -Block hash: 0xfa15574de615ad703c0a506f1410b17870939c1033cec01a1c7d353f41891475 +Block hash: 0xd002e6a0c03deccf48350c02543a0447af5c5ef17214093e289296b6491b64dc diff --git a/etherlink/tezt/tests/expected/evm_sequencer.ml/EVM Node- man.out b/etherlink/tezt/tests/expected/evm_sequencer.ml/EVM Node- man.out index a683dea3197c..85856c80a4ab 100644 --- a/etherlink/tezt/tests/expected/evm_sequencer.ml/EVM Node- man.out +++ b/etherlink/tezt/tests/expected/evm_sequencer.ml/EVM Node- man.out @@ -702,13 +702,13 @@ Kernel commands: [--sequencer-pool-address <0x...>] [--maximum-allowed-ticks <11000...>] [--maximum-gas-per-transaction <30000...>] [--max-blueprint-lookahead-in-seconds <500>] [--remove-whitelist] - [--bootstrap-balance <9999000000000000000000>] - [--bootstrap-account <0x...>] [--set-code <0x...,0x....>] - [--enable-fa-bridge] [--enable-dal] [--dal-slots <0,1,4,6,...>] - [--enable-multichain] [--l2-chain-id <1>] - [--max-delayed-inbox-blueprint-length <1000>] + [--eth-bootstrap-balance <9999000000000000000000>] + [--eth-bootstrap-account <0x...>] [--tez-bootstrap-balance <3800000>] + [--tez-bootstrap-account ] [--enable-fa-bridge] + [--dal-slots <0,1,4,6,...>] [--enable-dal] [--enable-multichain] + [--l2-chain-id <1>] [--max-delayed-inbox-blueprint-length <1000>] [--enable-fast-withdrawal] [--enable-fast-fa-withdrawal] - [--evm-version ] + [--evm-version ] [--set-code <0x...,0x....>] Create a configuration for the kernel installer. : File path where the config will be written to. --mainnet-compat: Generate a configuration compatible with the first @@ -744,16 +744,19 @@ Kernel commands: --max-blueprint-lookahead-in-seconds <500>: Value for max_blueprint_lookahead_in_seconds in the installer config. --remove-whitelist: Enable flag remove_whitelist in the installer config. - --bootstrap-balance <9999000000000000000000>: Balance of the bootstrap - accounts + --eth-bootstrap-balance <9999000000000000000000>: Balance of the + etherlink bootstrap accounts Defaults to `9999000000000000000000`. - --bootstrap-account <0x...>: Add a bootstrap account in the installer - config. - --set-code <0x...,0x....>: Add code to an account in the installer - config. + --eth-bootstrap-account <0x...>: Add an etherlink bootstrap account in + the installer config. + --tez-bootstrap-balance <3800000>: Balance of the tezlink bootstrap + accounts + Defaults to `3800000`. + --tez-bootstrap-account : Add an tezlink bootstrap account in the + installer config. --enable-fa-bridge: Enable flag enable_fa_bridge in the installer config. - --enable-dal: Enable flag enable_dal in the installer config. --dal-slots <0,1,4,6,...>: Value for dal_slots in the installer config. + --enable-dal: Enable flag enable_dal in the installer config. --enable-multichain: Enable flag enable_multichain in the installer config. --l2-chain-id <1>: Specify one of the chain ids in the kernel, can be @@ -766,13 +769,16 @@ Kernel commands: installer config. --evm-version : Value for evm_version in the installer config. + --set-code <0x...,0x....>: Add code to an account in the installer + config. make l2 kernel installer config [--minimum-base-fee-per-gas <111...>] [--da-fee-per-byte <111...>] [--sequencer-pool-address <0x...>] [--maximum-gas-per-transaction <30000...>] - [--bootstrap-balance <9999000000000000000000>] - [--bootstrap-account <0x...>] [--set-code <0x...,0x....>] + [--eth-bootstrap-balance <9999000000000000000000>] + [--eth-bootstrap-account <0x...>] [--tez-bootstrap-balance <3800000>] + [--tez-bootstrap-account ] [--set-code <0x...,0x....>] [--world-state-path >] [--l2-chain-id <1>] [--l2-chain-family ] Produce a file containing the part of the kernel configuration @@ -786,11 +792,16 @@ Kernel commands: installer config. --maximum-gas-per-transaction <30000...>: Value for maximum_gas_per_transaction in the installer config. - --bootstrap-balance <9999000000000000000000>: Balance of the bootstrap - accounts. + --eth-bootstrap-balance <9999000000000000000000>: Balance of the + etherlink bootstrap accounts Defaults to `9999000000000000000000`. - --bootstrap-account <0x...>: Add a bootstrap account in the installer - config. + --eth-bootstrap-account <0x...>: Add an etherlink bootstrap account in + the installer config. + --tez-bootstrap-balance <3800000>: Balance of the tezlink bootstrap + accounts + Defaults to `3800000`. + --tez-bootstrap-account : Add an tezlink bootstrap account in the + installer config. --set-code <0x...,0x....>: Add code to an account in the installer config. --world-state-path >: Value for -- GitLab