From 1a9edd53e3e18c21591baca389597a7c9f1134f3 Mon Sep 17 00:00:00 2001 From: Jack Li Date: Mon, 19 Aug 2024 17:11:36 +0800 Subject: [PATCH] app: fixed a bunch off issues --- .artela/config/app.toml | 333 ++++++++++++ .artela/config/client.toml | 21 + .artela/config/config.toml | 482 +++++++++++++++++ .artela/config/genesis.json | 494 ++++++++++++++++++ ...27c07ea565d792ab0b62ac8ca36f05dc54d57.json | 1 + .artela/config/node_key.json | 1 + .artela/config/priv_validator_key.json | 11 + .artela/data/priv_validator_state.json | 5 + ...c7b3d5c7ff22edc352b0b44bb4246fbd01.address | 1 + ...01fd35ab45617f64de0a504899360d63fb.address | 1 + ...98aaaba7ab3e35024d9fbedfee164521be.address | 1 + ...3e617a7039708820902e2746c4766c2ced.address | 1 + .artela/keyring-test/mykey.info | 1 + .artela/keyring-test/mykey2.info | 1 + .artela/keyring-test/mykey3.info | 1 + .artela/keyring-test/mykey4.info | 1 + Dockerfile | 36 ++ app/ante/evm/context_checker.go | 6 +- app/ante/evm/sig_checker.go | 6 + app/app.go | 20 +- cmd/{artelad => artrolld}/cmd/commands.go | 0 cmd/{artelad => artrolld}/cmd/config.go | 0 cmd/{artelad => artrolld}/cmd/genaccounts.go | 0 cmd/{artelad => artrolld}/cmd/gencontract.go | 0 cmd/{artelad => artrolld}/cmd/keyinfo.go | 0 cmd/{artelad => artrolld}/cmd/root.go | 0 cmd/{artelad => artrolld}/main.go | 2 +- compose.yaml | 28 + ethereum/rpc/tx.go | 6 + ethereum/rpc/types/utils.go | 2 +- ethereum/types/coin.go | 8 +- ethereum/utils/utils.go | 2 +- init.sh | 3 +- kurtosis.yml | 4 + main.star | 62 +++ readme.md | 4 +- x/evm/keeper/config.go | 2 +- x/evm/keeper/evm.go | 4 +- x/evm/keeper/msg_server.go | 4 +- x/evm/keeper/proposer.go | 6 +- x/evm/keeper/query.go | 2 +- x/evm/module/module.go | 18 +- x/evm/types/tx_wrapper.go | 18 +- 43 files changed, 1554 insertions(+), 45 deletions(-) create mode 100644 .artela/config/app.toml create mode 100644 .artela/config/client.toml create mode 100644 .artela/config/config.toml create mode 100644 .artela/config/genesis.json create mode 100644 .artela/config/gentx/gentx-f4227c07ea565d792ab0b62ac8ca36f05dc54d57.json create mode 100644 .artela/config/node_key.json create mode 100644 .artela/config/priv_validator_key.json create mode 100644 .artela/data/priv_validator_state.json create mode 100644 .artela/keyring-test/15248bc7b3d5c7ff22edc352b0b44bb4246fbd01.address create mode 100644 .artela/keyring-test/572f6601fd35ab45617f64de0a504899360d63fb.address create mode 100644 .artela/keyring-test/682a8598aaaba7ab3e35024d9fbedfee164521be.address create mode 100644 .artela/keyring-test/ea93f43e617a7039708820902e2746c4766c2ced.address create mode 100644 .artela/keyring-test/mykey.info create mode 100644 .artela/keyring-test/mykey2.info create mode 100644 .artela/keyring-test/mykey3.info create mode 100644 .artela/keyring-test/mykey4.info create mode 100644 Dockerfile rename cmd/{artelad => artrolld}/cmd/commands.go (100%) rename cmd/{artelad => artrolld}/cmd/config.go (100%) rename cmd/{artelad => artrolld}/cmd/genaccounts.go (100%) rename cmd/{artelad => artrolld}/cmd/gencontract.go (100%) rename cmd/{artelad => artrolld}/cmd/keyinfo.go (100%) rename cmd/{artelad => artrolld}/cmd/root.go (100%) rename cmd/{artelad => artrolld}/main.go (83%) create mode 100644 compose.yaml create mode 100644 kurtosis.yml create mode 100644 main.star diff --git a/.artela/config/app.toml b/.artela/config/app.toml new file mode 100644 index 0000000..a04d5cc --- /dev/null +++ b/.artela/config/app.toml @@ -0,0 +1,333 @@ +# This is a TOML config file. +# For more information, see https://github.com/toml-lang/toml + +############################################################################### +### Base Configuration ### +############################################################################### + +# The minimum gas prices a validator is willing to accept for processing a +# transaction. A transaction's fees must meet the minimum of any denomination +# specified in this config (e.g. 0.25token1,0.0001token2). +minimum-gas-prices = "0aart" + +# The maximum gas a query coming over rest/grpc may consume. +# If this is set to zero, the query can consume an unbounded amount of gas. +query-gas-limit = "0" + +# default: the last 362880 states are kept, pruning at 10 block intervals +# nothing: all historic states will be saved, nothing will be deleted (i.e. archiving node) +# everything: 2 latest states will be kept; pruning at 10 block intervals. +# custom: allow pruning options to be manually specified through 'pruning-keep-recent', and 'pruning-interval' +pruning = "custom" + +# These are applied if and only if the pruning strategy is custom. +pruning-keep-recent = "2" +pruning-interval = "10" + +# HaltHeight contains a non-zero block height at which a node will gracefully +# halt and shutdown that can be used to assist upgrades and testing. +# +# Note: Commitment of state will be attempted on the corresponding block. +halt-height = 0 + +# HaltTime contains a non-zero minimum block time (in Unix seconds) at which +# a node will gracefully halt and shutdown that can be used to assist upgrades +# and testing. +# +# Note: Commitment of state will be attempted on the corresponding block. +halt-time = 0 + +# MinRetainBlocks defines the minimum block height offset from the current +# block being committed, such that all blocks past this offset are pruned +# from CometBFT. It is used as part of the process of determining the +# ResponseCommit.RetainHeight value during ABCI Commit. A value of 0 indicates +# that no blocks should be pruned. +# +# This configuration value is only responsible for pruning CometBFT blocks. +# It has no bearing on application state pruning which is determined by the +# "pruning-*" configurations. +# +# Note: CometBFT block pruning is dependant on this parameter in conjunction +# with the unbonding (safety threshold) period, state pruning and state sync +# snapshot parameters to determine the correct minimum value of +# ResponseCommit.RetainHeight. +min-retain-blocks = 0 + +# InterBlockCache enables inter-block caching. +inter-block-cache = true + +# IndexEvents defines the set of events in the form {eventType}.{attributeKey}, +# which informs CometBFT what to index. If empty, all events will be indexed. +# +# Example: +# ["message.sender", "message.recipient"] +index-events = [] + +# IavlCacheSize set the size of the iavl tree cache (in number of nodes). +iavl-cache-size = 781250 + +# IAVLDisableFastNode enables or disables the fast node feature of IAVL. +# Default is false. +iavl-disable-fastnode = false + +# AppDBBackend defines the database backend type to use for the application and snapshots DBs. +# An empty string indicates that a fallback will be used. +# The fallback is the db_backend value set in CometBFT's config.toml. +app-db-backend = "" + +############################################################################### +### Telemetry Configuration ### +############################################################################### + +[telemetry] + +# Prefixed with keys to separate services. +service-name = "" + +# Enabled enables the application telemetry functionality. When enabled, +# an in-memory sink is also enabled by default. Operators may also enabled +# other sinks such as Prometheus. +enabled = true + +# Enable prefixing gauge values with hostname. +enable-hostname = false + +# Enable adding hostname to labels. +enable-hostname-label = false + +# Enable adding service to labels. +enable-service-label = false + +# PrometheusRetentionTime, when positive, enables a Prometheus metrics sink. +prometheus-retention-time = 1000000000000 + +# GlobalLabels defines a global set of name/value label tuples applied to all +# metrics emitted using the wrapper functions defined in telemetry package. +# +# Example: +# [["chain_id", "cosmoshub-1"]] +global-labels = [ +] + +# MetricsSink defines the type of metrics sink to use. +metrics-sink = "" + +# StatsdAddr defines the address of a statsd server to send metrics to. +# Only utilized if MetricsSink is set to "statsd" or "dogstatsd". +statsd-addr = "" + +# DatadogHostname defines the hostname to use when emitting metrics to +# Datadog. Only utilized if MetricsSink is set to "dogstatsd". +datadog-hostname = "" + +############################################################################### +### API Configuration ### +############################################################################### + +[api] + +# Enable defines if the API server should be enabled. +enable = true + +# Swagger defines if swagger documentation should automatically be registered. +swagger = false + +# Address defines the API server to listen on. +address = "tcp://localhost:1317" + +# MaxOpenConnections defines the number of maximum open connections. +max-open-connections = 1000 + +# RPCReadTimeout defines the CometBFT RPC read timeout (in seconds). +rpc-read-timeout = 10 + +# RPCWriteTimeout defines the CometBFT RPC write timeout (in seconds). +rpc-write-timeout = 0 + +# RPCMaxBodyBytes defines the CometBFT maximum request body (in bytes). +rpc-max-body-bytes = 1000000 + +# EnableUnsafeCORS defines if CORS should be enabled (unsafe - use it at your own risk). +enabled-unsafe-cors = false + +############################################################################### +### gRPC Configuration ### +############################################################################### + +[grpc] + +# Enable defines if the gRPC server should be enabled. +enable = true + +# Address defines the gRPC server address to bind to. +address = "localhost:9090" + +# MaxRecvMsgSize defines the max message size in bytes the server can receive. +# The default value is 10MB. +max-recv-msg-size = "10485760" + +# MaxSendMsgSize defines the max message size in bytes the server can send. +# The default value is math.MaxInt32. +max-send-msg-size = "2147483647" + +############################################################################### +### gRPC Web Configuration ### +############################################################################### + +[grpc-web] + +# GRPCWebEnable defines if the gRPC-web should be enabled. +# NOTE: gRPC must also be enabled, otherwise, this configuration is a no-op. +# NOTE: gRPC-Web uses the same address as the API server. +enable = true + +############################################################################### +### State Sync Configuration ### +############################################################################### + +# State sync snapshots allow other nodes to rapidly join the network without replaying historical +# blocks, instead downloading and applying a snapshot of the application state at a given height. +[state-sync] + +# snapshot-interval specifies the block interval at which local state sync snapshots are +# taken (0 to disable). +snapshot-interval = 2000 + +# snapshot-keep-recent specifies the number of recent snapshots to keep and serve (0 to keep all). +snapshot-keep-recent = 2 + +############################################################################### +### State Streaming ### +############################################################################### + +# Streaming allows nodes to stream state to external systems. +[streaming] + +# streaming.abci specifies the configuration for the ABCI Listener streaming service. +[streaming.abci] + +# List of kv store keys to stream out via gRPC. +# The store key names MUST match the module's StoreKey name. +# +# Example: +# ["acc", "bank", "gov", "staking", "mint"[,...]] +# ["*"] to expose all keys. +keys = [] + +# The plugin name used for streaming via gRPC. +# Streaming is only enabled if this is set. +# Supported plugins: abci +plugin = "" + +# stop-node-on-err specifies whether to stop the node on message delivery error. +stop-node-on-err = true + +############################################################################### +### Mempool ### +############################################################################### + +[mempool] +# Setting max-txs to 0 will allow for a unbounded amount of transactions in the mempool. +# Setting max_txs to negative 1 (-1) will disable transactions from being inserted into the mempool (no-op mempool). +# Setting max_txs to a positive number (> 0) will limit the number of transactions in the mempool, by the specified amount. +# +# Note, this configuration only applies to SDK built-in app-side mempool +# implementations. +max-txs = -1 + +############################################################################### +### EVM Configuration ### +############################################################################### + +[evm] + +# Tracer defines the 'vm.Tracer' type that the EVM will use when the node is run in +# debug mode. To enable tracing use the '--evm.tracer' flag when starting your node. +# Valid types are: json|struct|access_list|markdown +tracer = "" + +# MaxTxGasWanted defines the gas wanted for each eth txs returned in ante handler in check txs mode. +max-txs-gas-wanted = 0 + +############################################################################### +### JSON RPC Configuration ### +############################################################################### + +[json-rpc] + +# Enable defines if the gRPC server should be enabled. +enable = true + +# Address defines the EVM RPC HTTP server address to bind to. +address = "0.0.0.0:8545" + +# Address defines the EVM WebSocket server address to bind to. +ws-address = "127.0.0.1:8546" + +# API defines a list of JSON-RPC namespaces that should be enabled +# Example: "eth,txpool,personal,net,debug,web3" +api = "eth,net,web3" + +# GasCap sets a cap on gas that can be used in eth_call/estimateGas (0=infinite). Default: 25,000,000. +gas-cap = 25000000 + +# EVMTimeout is the global timeout for eth_call. Default: 5s. +evm-timeout = "5s" + +# TxFeeCap is the global txs-fee cap for send txs. Default: 1eth. +txfee-cap = 1 + +# FilterCap sets the global cap for total number of filters that can be created +filter-cap = 200 + +# FeeHistoryCap sets the global cap for total number of blocks that can be fetched +feehistory-cap = 100 + +# LogsCap defines the max number of results can be returned from single 'eth_getLogs' query. +logs-cap = 10000 + +# BlockRangeCap defines the max block range allowed for 'eth_getLogs' query. +block-range-cap = 10000 + +# HTTPTimeout is the read/write timeout of http json-rpc server. +http-timeout = "30s" + +# HTTPIdleTimeout is the idle timeout of http json-rpc server. +http-idle-timeout = "2m0s" + +# AllowUnprotectedTxs restricts unprotected (non EIP155 signed) transactions to be submitted via +# the node's RPC when the global parameter is disabled. +allow-unprotected-txs = true + +# MaxOpenConnections sets the maximum number of simultaneous connections +# for the server listener. +max-open-connections = 0 + +# EnableIndexer enables the custom txs indexer for the EVM (ethereum transactions). +enable-indexer = false + +# MetricsAddress defines the EVM Metrics server address to bind to. Pass --metrics in CLI to enable +# Prometheus metrics path: /debug/metrics/prometheus +metrics-address = "127.0.0.1:6065" + +# Upgrade height for fix of revert gas refund logic when txs reverted. +fix-revert-gas-refund-height = 0 + +############################################################################### +### TLS Configuration ### +############################################################################### + +[tls] + +# Certificate path defines the cert.pem file path for the TLS configuration. +certificate-path = "" + +# Key path defines the key.pem file path for the TLS configuration. +key-path = "" + +############################################################################### +### Aspect Configuration ### +############################################################################### +[aspect] +apply-pool-size = 0 +query-pool-size = 0 diff --git a/.artela/config/client.toml b/.artela/config/client.toml new file mode 100644 index 0000000..a01de0c --- /dev/null +++ b/.artela/config/client.toml @@ -0,0 +1,21 @@ +# This is a TOML config file. +# For more information, see https://github.com/toml-lang/toml + +############################################################################### +### Client Configuration ### +############################################################################### + +# The network chain ID +chain-id = "artroll_11820-1" + +# The keyring's backend, where the keys are stored (os|file|kwallet|pass|test|memory) +keyring-backend = "test" + +# CLI output format (text|json) +output = "text" + +# : to CometBFT RPC interface for this chain +node = "tcp://localhost:26657" + +# Transaction broadcasting mode (sync|async) +broadcast-mode = "sync" diff --git a/.artela/config/config.toml b/.artela/config/config.toml new file mode 100644 index 0000000..18c8ac7 --- /dev/null +++ b/.artela/config/config.toml @@ -0,0 +1,482 @@ +# This is a TOML config file. +# For more information, see https://github.com/toml-lang/toml + +# NOTE: Any path below can be absolute (e.g. "/var/myawesomeapp/data") or +# relative to the home directory (e.g. "data"). The home directory is +# "$HOME/.cometbft" by default, but could be changed via $CMTHOME env variable +# or --home cmd flag. + +# The version of the CometBFT binary that created or +# last modified the config file. Do not modify this. +version = "0.38.7" + +####################################################################### +### Main Base Config Options ### +####################################################################### + +# TCP or UNIX socket address of the ABCI application, +# or the name of an ABCI application compiled in with the CometBFT binary +proxy_app = "tcp://127.0.0.1:26658" + +# A custom human readable name for this node +moniker = "localtestnet" + +# Database backend: goleveldb | cleveldb | boltdb | rocksdb | badgerdb +# * goleveldb (github.com/syndtr/goleveldb - most popular implementation) +# - pure go +# - stable +# * cleveldb (uses levigo wrapper) +# - fast +# - requires gcc +# - use cleveldb build tag (go build -tags cleveldb) +# * boltdb (uses etcd's fork of bolt - github.com/etcd-io/bbolt) +# - EXPERIMENTAL +# - may be faster is some use-cases (random reads - indexer) +# - use boltdb build tag (go build -tags boltdb) +# * rocksdb (uses github.com/tecbot/gorocksdb) +# - EXPERIMENTAL +# - requires gcc +# - use rocksdb build tag (go build -tags rocksdb) +# * badgerdb (uses github.com/dgraph-io/badger) +# - EXPERIMENTAL +# - use badgerdb build tag (go build -tags badgerdb) +db_backend = "goleveldb" + +# Database directory +db_dir = "data" + +# Output level for logging, including package level options +log_level = "info" + +# Output format: 'plain' (colored text) or 'json' +log_format = "plain" + +##### additional base config options ##### + +# Path to the JSON file containing the initial validator set and other meta data +genesis_file = "config/genesis.json" + +# Path to the JSON file containing the private key to use as a validator in the consensus protocol +priv_validator_key_file = "config/priv_validator_key.json" + +# Path to the JSON file containing the last sign state of a validator +priv_validator_state_file = "data/priv_validator_state.json" + +# TCP or UNIX socket address for CometBFT to listen on for +# connections from an external PrivValidator process +priv_validator_laddr = "" + +# Path to the JSON file containing the private key to use for node authentication in the p2p protocol +node_key_file = "config/node_key.json" + +# Mechanism to connect to the ABCI application: socket | grpc +abci = "socket" + +# If true, query the ABCI app on connecting to a new peer +# so the app can decide if we should keep the connection or not +filter_peers = false + + +####################################################################### +### Advanced Configuration Options ### +####################################################################### + +####################################################### +### RPC Server Configuration Options ### +####################################################### +[rpc] + +# TCP or UNIX socket address for the RPC server to listen on +laddr = "tcp://127.0.0.1:26657" + +# A list of origins a cross-domain request can be executed from +# Default value '[]' disables cors support +# Use '["*"]' to allow any origin +cors_allowed_origins = [] + +# A list of methods the client is allowed to use with cross-domain requests +cors_allowed_methods = ["HEAD", "GET", "POST", ] + +# A list of non simple headers the client is allowed to use with cross-domain requests +cors_allowed_headers = ["Origin", "Accept", "Content-Type", "X-Requested-With", "X-Server-Time", ] + +# TCP or UNIX socket address for the gRPC server to listen on +# NOTE: This server only supports /broadcast_tx_commit +grpc_laddr = "" + +# Maximum number of simultaneous connections. +# Does not include RPC (HTTP&WebSocket) connections. See max_open_connections +# If you want to accept a larger number than the default, make sure +# you increase your OS limits. +# 0 - unlimited. +# Should be < {ulimit -Sn} - {MaxNumInboundPeers} - {MaxNumOutboundPeers} - {N of wal, db and other open files} +# 1024 - 40 - 10 - 50 = 924 = ~900 +grpc_max_open_connections = 900 + +# Activate unsafe RPC commands like /dial_seeds and /unsafe_flush_mempool +unsafe = false + +# Maximum number of simultaneous connections (including WebSocket). +# Does not include gRPC connections. See grpc_max_open_connections +# If you want to accept a larger number than the default, make sure +# you increase your OS limits. +# 0 - unlimited. +# Should be < {ulimit -Sn} - {MaxNumInboundPeers} - {MaxNumOutboundPeers} - {N of wal, db and other open files} +# 1024 - 40 - 10 - 50 = 924 = ~900 +max_open_connections = 900 + +# Maximum number of unique clientIDs that can /subscribe +# If you're using /broadcast_tx_commit, set to the estimated maximum number +# of broadcast_tx_commit calls per block. +max_subscription_clients = 100 + +# Maximum number of unique queries a given client can /subscribe to +# If you're using GRPC (or Local RPC client) and /broadcast_tx_commit, set to +# the estimated # maximum number of broadcast_tx_commit calls per block. +max_subscriptions_per_client = 5 + +# Experimental parameter to specify the maximum number of events a node will +# buffer, per subscription, before returning an error and closing the +# subscription. Must be set to at least 100, but higher values will accommodate +# higher event throughput rates (and will use more memory). +experimental_subscription_buffer_size = 200 + +# Experimental parameter to specify the maximum number of RPC responses that +# can be buffered per WebSocket client. If clients cannot read from the +# WebSocket endpoint fast enough, they will be disconnected, so increasing this +# parameter may reduce the chances of them being disconnected (but will cause +# the node to use more memory). +# +# Must be at least the same as "experimental_subscription_buffer_size", +# otherwise connections could be dropped unnecessarily. This value should +# ideally be somewhat higher than "experimental_subscription_buffer_size" to +# accommodate non-subscription-related RPC responses. +experimental_websocket_write_buffer_size = 200 + +# If a WebSocket client cannot read fast enough, at present we may +# silently drop events instead of generating an error or disconnecting the +# client. +# +# Enabling this experimental parameter will cause the WebSocket connection to +# be closed instead if it cannot read fast enough, allowing for greater +# predictability in subscription behavior. +experimental_close_on_slow_client = false + +# How long to wait for a tx to be committed during /broadcast_tx_commit. +# WARNING: Using a value larger than 10s will result in increasing the +# global HTTP write timeout, which applies to all connections and endpoints. +# See https://github.com/tendermint/tendermint/issues/3435 +timeout_broadcast_tx_commit = "10s" + +# Maximum size of request body, in bytes +max_body_bytes = 1000000 + +# Maximum size of request header, in bytes +max_header_bytes = 1048576 + +# The path to a file containing certificate that is used to create the HTTPS server. +# Might be either absolute path or path related to CometBFT's config directory. +# If the certificate is signed by a certificate authority, +# the certFile should be the concatenation of the server's certificate, any intermediates, +# and the CA's certificate. +# NOTE: both tls_cert_file and tls_key_file must be present for CometBFT to create HTTPS server. +# Otherwise, HTTP server is run. +tls_cert_file = "" + +# The path to a file containing matching private key that is used to create the HTTPS server. +# Might be either absolute path or path related to CometBFT's config directory. +# NOTE: both tls-cert-file and tls-key-file must be present for CometBFT to create HTTPS server. +# Otherwise, HTTP server is run. +tls_key_file = "" + +# pprof listen address (https://golang.org/pkg/net/http/pprof) +pprof_laddr = "localhost:6060" + +####################################################### +### P2P Configuration Options ### +####################################################### +[p2p] + +# Address to listen for incoming connections +laddr = "tcp://0.0.0.0:26656" + +# Address to advertise to peers for them to dial. If empty, will use the same +# port as the laddr, and will introspect on the listener to figure out the +# address. IP and port are required. Example: 159.89.10.97:26656 +external_address = "" + +# Comma separated list of seed nodes to connect to +seeds = "" + +# Comma separated list of nodes to keep persistent connections to +persistent_peers = "" + +# Path to address book +addr_book_file = "config/addrbook.json" + +# Set true for strict address routability rules +# Set false for private or local networks +addr_book_strict = true + +# Maximum number of inbound peers +max_num_inbound_peers = 40 + +# Maximum number of outbound peers to connect to, excluding persistent peers +max_num_outbound_peers = 10 + +# List of node IDs, to which a connection will be (re)established ignoring any existing limits +unconditional_peer_ids = "" + +# Maximum pause when redialing a persistent peer (if zero, exponential backoff is used) +persistent_peers_max_dial_period = "0s" + +# Time to wait before flushing messages out on the connection +flush_throttle_timeout = "100ms" + +# Maximum size of a message packet payload, in bytes +max_packet_msg_payload_size = 1024 + +# Rate at which packets can be sent, in bytes/second +send_rate = 5120000 + +# Rate at which packets can be received, in bytes/second +recv_rate = 5120000 + +# Set true to enable the peer-exchange reactor +pex = true + +# Seed mode, in which node constantly crawls the network and looks for +# peers. If another node asks it for addresses, it responds and disconnects. +# +# Does not work if the peer-exchange reactor is disabled. +seed_mode = false + +# Comma separated list of peer IDs to keep private (will not be gossiped to other peers) +private_peer_ids = "" + +# Toggle to disable guard against peers connecting from the same ip. +allow_duplicate_ip = false + +# Peer connection configuration. +handshake_timeout = "20s" +dial_timeout = "3s" + +####################################################### +### Mempool Configuration Option ### +####################################################### +[mempool] + +# The type of mempool for this node to use. +# +# Possible types: +# - "flood" : concurrent linked list mempool with flooding gossip protocol +# (default) +# - "nop" : nop-mempool (short for no operation; the ABCI app is responsible +# for storing, disseminating and proposing txs). "create_empty_blocks=false" is +# not supported. +type = "flood" + +# Recheck (default: true) defines whether CometBFT should recheck the +# validity for all remaining transaction in the mempool after a block. +# Since a block affects the application state, some transactions in the +# mempool may become invalid. If this does not apply to your application, +# you can disable rechecking. +recheck = true + +# Broadcast (default: true) defines whether the mempool should relay +# transactions to other peers. Setting this to false will stop the mempool +# from relaying transactions to other peers until they are included in a +# block. In other words, if Broadcast is disabled, only the peer you send +# the tx to will see it until it is included in a block. +broadcast = true + +# WalPath (default: "") configures the location of the Write Ahead Log +# (WAL) for the mempool. The WAL is disabled by default. To enable, set +# WalPath to where you want the WAL to be written (e.g. +# "data/mempool.wal"). +wal_dir = "" + +# Maximum number of transactions in the mempool +size = 5000 + +# Limit the total size of all txs in the mempool. +# This only accounts for raw transactions (e.g. given 1MB transactions and +# max_txs_bytes=5MB, mempool will only accept 5 transactions). +max_txs_bytes = 1073741824 + +# Size of the cache (used to filter transactions we saw earlier) in transactions +cache_size = 10000 + +# Do not remove invalid transactions from the cache (default: false) +# Set to true if it's not possible for any invalid transaction to become valid +# again in the future. +keep-invalid-txs-in-cache = false + +# Maximum size of a single transaction. +# NOTE: the max size of a tx transmitted over the network is {max_tx_bytes}. +max_tx_bytes = 1048576 + +# Maximum size of a batch of transactions to send to a peer +# Including space needed by encoding (one varint per transaction). +# XXX: Unused due to https://github.com/tendermint/tendermint/issues/5796 +max_batch_bytes = 0 + +# Experimental parameters to limit gossiping txs to up to the specified number of peers. +# We use two independent upper values for persistent and non-persistent peers. +# Unconditional peers are not affected by this feature. +# If we are connected to more than the specified number of persistent peers, only send txs to +# ExperimentalMaxGossipConnectionsToPersistentPeers of them. If one of those +# persistent peers disconnects, activate another persistent peer. +# Similarly for non-persistent peers, with an upper limit of +# ExperimentalMaxGossipConnectionsToNonPersistentPeers. +# If set to 0, the feature is disabled for the corresponding group of peers, that is, the +# number of active connections to that group of peers is not bounded. +# For non-persistent peers, if enabled, a value of 10 is recommended based on experimental +# performance results using the default P2P configuration. +experimental_max_gossip_connections_to_persistent_peers = 0 +experimental_max_gossip_connections_to_non_persistent_peers = 0 + +####################################################### +### State Sync Configuration Options ### +####################################################### +[statesync] +# State sync rapidly bootstraps a new node by discovering, fetching, and restoring a state machine +# snapshot from peers instead of fetching and replaying historical blocks. Requires some peers in +# the network to take and serve state machine snapshots. State sync is not attempted if the node +# has any local state (LastBlockHeight > 0). The node will have a truncated block history, +# starting from the height of the snapshot. +enable = false + +# RPC servers (comma-separated) for light client verification of the synced state machine and +# retrieval of state data for node bootstrapping. Also needs a trusted height and corresponding +# header hash obtained from a trusted source, and a period during which validators can be trusted. +# +# For Cosmos SDK-based chains, trust_period should usually be about 2/3 of the unbonding time (~2 +# weeks) during which they can be financially punished (slashed) for misbehavior. +rpc_servers = "" +trust_height = 0 +trust_hash = "" +trust_period = "168h0m0s" + +# Time to spend discovering snapshots before initiating a restore. +discovery_time = "15s" + +# Temporary directory for state sync snapshot chunks, defaults to the OS tempdir (typically /tmp). +# Will create a new, randomly named directory within, and remove it when done. +temp_dir = "" + +# The timeout duration before re-requesting a chunk, possibly from a different +# peer (default: 1 minute). +chunk_request_timeout = "10s" + +# The number of concurrent chunk fetchers to run (default: 1). +chunk_fetchers = "4" + +####################################################### +### Block Sync Configuration Options ### +####################################################### +[blocksync] + +# Block Sync version to use: +# +# In v0.37, v1 and v2 of the block sync protocols were deprecated. +# Please use v0 instead. +# +# 1) "v0" - the default block sync implementation +version = "v0" + +####################################################### +### Consensus Configuration Options ### +####################################################### +[consensus] + +wal_file = "data/cs.wal/wal" + +# How long we wait for a proposal block before prevoting nil +timeout_propose = "3s" +# How much timeout_propose increases with each round +timeout_propose_delta = "500ms" +# How long we wait after receiving +2/3 prevotes for “anything” (ie. not a single block or nil) +timeout_prevote = "1s" +# How much the timeout_prevote increases with each round +timeout_prevote_delta = "500ms" +# How long we wait after receiving +2/3 precommits for “anything” (ie. not a single block or nil) +timeout_precommit = "1s" +# How much the timeout_precommit increases with each round +timeout_precommit_delta = "500ms" +# How long we wait after committing a block, before starting on the new +# height (this gives us a chance to receive some more precommits, even +# though we already have +2/3). +timeout_commit = "5s" + +# How many blocks to look back to check existence of the node's consensus votes before joining consensus +# When non-zero, the node will panic upon restart +# if the same consensus key was used to sign {double_sign_check_height} last blocks. +# So, validators should stop the state machine, wait for some blocks, and then restart the state machine to avoid panic. +double_sign_check_height = 0 + +# Make progress as soon as we have all the precommits (as if TimeoutCommit = 0) +skip_timeout_commit = false + +# EmptyBlocks mode and possible interval between empty blocks +create_empty_blocks = false +create_empty_blocks_interval = "0s" + +# Reactor sleep duration parameters +peer_gossip_sleep_duration = "100ms" +peer_query_maj23_sleep_duration = "2s" + +####################################################### +### Storage Configuration Options ### +####################################################### +[storage] + +# Set to true to discard ABCI responses from the state store, which can save a +# considerable amount of disk space. Set to false to ensure ABCI responses are +# persisted. ABCI responses are required for /block_results RPC queries, and to +# reindex events in the command-line tool. +discard_abci_responses = false + +####################################################### +### Transaction Indexer Configuration Options ### +####################################################### +[tx_index] + +# What indexer to use for transactions +# +# The application will set which txs to index. In some cases a node operator will be able +# to decide which txs to index based on configuration set in the application. +# +# Options: +# 1) "null" +# 2) "kv" (default) - the simplest possible indexer, backed by key-value storage (defaults to levelDB; see DBBackend). +# - When "kv" is chosen "tx.height" and "tx.hash" will always be indexed. +# 3) "psql" - the indexer services backed by PostgreSQL. +# When "kv" or "psql" is chosen "tx.height" and "tx.hash" will always be indexed. +indexer = "kv" + +# The PostgreSQL connection configuration, the connection format: +# postgresql://:@:/? +psql-conn = "" + +####################################################### +### Instrumentation Configuration Options ### +####################################################### +[instrumentation] + +# When true, Prometheus metrics are served under /metrics on +# PrometheusListenAddr. +# Check out the documentation for the list of available metrics. +prometheus = true + +# Address to listen for Prometheus collector(s) connections +prometheus_listen_addr = ":26660" + +# Maximum number of simultaneous connections. +# If you want to accept a larger number than the default, make sure +# you increase your OS limits. +# 0 - unlimited. +max_open_connections = 3 + +# Instrumentation namespace +namespace = "cometbft" diff --git a/.artela/config/genesis.json b/.artela/config/genesis.json new file mode 100644 index 0000000..17ff57b --- /dev/null +++ b/.artela/config/genesis.json @@ -0,0 +1,494 @@ +{ + "app_name": "artela-rollkitd", + "app_version": "", + "genesis_time": "2024-08-19T02:50:07.087678Z", + "chain_id": "artroll_11820-1", + "initial_height": 1, + "app_hash": null, + "app_state": { + "06-solomachine": null, + "07-tendermint": null, + "auth": { + "params": { + "max_memo_characters": "256", + "tx_sig_limit": "7", + "tx_size_cost_per_byte": "10", + "sig_verify_cost_ed25519": "590", + "sig_verify_cost_secp256k1": "1000" + }, + "accounts": [ + { + "@type": "/artela.types.EthAccount", + "base_account": { + "address": "art1qqqqqqqqqqqqqqqqqqqqqqqqqqqqp2hvnfxf27", + "pub_key": null, + "account_number": "0", + "sequence": "0" + }, + "code_hash": "0x95c7b5b8d621c93f24e4cf03df88f089d1af333f21c06f4a3a2aa31b802bd7f9" + }, + { + "@type": "/cosmos.auth.v1beta1.BaseAccount", + "address": "art1dq4gtx924wn6k034qfxel0klacty2gd7cktd2j", + "pub_key": null, + "account_number": "1", + "sequence": "0" + }, + { + "@type": "/cosmos.auth.v1beta1.BaseAccount", + "address": "art1a2flg0np0fcrjuygyzgzuf6xc3mxct8d9rukzd", + "pub_key": null, + "account_number": "2", + "sequence": "0" + }, + { + "@type": "/cosmos.auth.v1beta1.BaseAccount", + "address": "art1z5jgh3an6hrl7ghdcdftpdztksjxl0gpjsg03v", + "pub_key": null, + "account_number": "3", + "sequence": "0" + }, + { + "@type": "/cosmos.auth.v1beta1.BaseAccount", + "address": "art12uhkvq0axk452ctlvn0q55zgnymq6clml5064g", + "pub_key": null, + "account_number": "4", + "sequence": "0" + } + ] + }, + "authz": { + "authorization": [] + }, + "bank": { + "params": { + "send_enabled": [], + "default_send_enabled": true + }, + "balances": [ + { + "address": "art1qqqqqqqqqqqqqqqqqqqqqqqqqqqqp2hvnfxf27", + "coins": [] + }, + { + "address": "art1z5jgh3an6hrl7ghdcdftpdztksjxl0gpjsg03v", + "coins": [ + { + "denom": "aart", + "amount": "100000000000000000000000000" + } + ] + }, + { + "address": "art12uhkvq0axk452ctlvn0q55zgnymq6clml5064g", + "coins": [ + { + "denom": "aart", + "amount": "100000000000000000000000000" + } + ] + }, + { + "address": "art1dq4gtx924wn6k034qfxel0klacty2gd7cktd2j", + "coins": [ + { + "denom": "aart", + "amount": "100000000000000000000000000" + } + ] + }, + { + "address": "art1a2flg0np0fcrjuygyzgzuf6xc3mxct8d9rukzd", + "coins": [ + { + "denom": "aart", + "amount": "100000000000000000000000000" + } + ] + } + ], + "supply": [], + "denom_metadata": [], + "send_enabled": [] + }, + "capability": { + "index": "1", + "owners": [] + }, + "circuit": { + "account_permissions": [], + "disabled_type_urls": [] + }, + "consensus": null, + "crisis": { + "constant_fee": { + "denom": "aart", + "amount": "1000" + } + }, + "distribution": { + "params": { + "community_tax": "0.020000000000000000", + "base_proposer_reward": "0.000000000000000000", + "bonus_proposer_reward": "0.000000000000000000", + "withdraw_addr_enabled": true + }, + "fee_pool": { + "community_pool": [] + }, + "delegator_withdraw_infos": [], + "previous_proposer": "", + "outstanding_rewards": [], + "validator_accumulated_commissions": [], + "validator_historical_rewards": [], + "validator_current_rewards": [], + "delegator_starting_infos": [], + "validator_slash_events": [] + }, + "evidence": { + "evidence": [] + }, + "evm": { + "params": { + "evm_denom": "aart", + "enable_create": true, + "enable_call": true, + "extra_eips": [ + "3855" + ], + "chain_config": { + "homestead_block": "0", + "dao_fork_block": "0", + "dao_fork_support": true, + "eip150_block": "0", + "eip150_hash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "eip155_block": "0", + "eip158_block": "0", + "byzantium_block": "0", + "constantinople_block": "0", + "petersburg_block": "0", + "istanbul_block": "0", + "muir_glacier_block": "0", + "berlin_block": "0", + "london_block": "0", + "arrow_glacier_block": "0", + "gray_glacier_block": "0", + "merge_netsplit_block": "0", + "shanghai_block": "0", + "cancun_block": "0" + }, + "allow_unprotected_txs": true + }, + "accounts": [ + { + "address": "0x000000000000000000000000000000000000aaEC", + "code": "60806040526004361015610023575b361561001957600080fd5b610021615531565b005b60003560e01c80630396cb60146101b35780630bd28e3b146101aa5780631b2e01b8146101a15780631d732756146101985780631fad948c1461018f578063205c28781461018657806335567e1a1461017d5780634b1d7cf5146101745780635287ce121461016b57806370a08231146101625780638f41ec5a14610159578063957122ab146101505780639b249f6914610147578063a61935311461013e578063b760faf914610135578063bb9fe6bf1461012c578063c23a5cea14610123578063d6383f941461011a578063ee219423146101115763fc7e286d0361000e5761010c611bcd565b61000e565b5061010c6119b5565b5061010c61184d565b5061010c6116b4565b5061010c611536565b5061010c6114f7565b5061010c6114d6565b5061010c611337565b5061010c611164565b5061010c611129565b5061010c6110a4565b5061010c610f54565b5061010c610bf8565b5061010c610b33565b5061010c610994565b5061010c6108ba565b5061010c6106e7565b5061010c610467565b5061010c610385565b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043563ffffffff8116808203610359576103547fa5ae833d0bb1dcd632d98a8b70973e8516812898e19bf27b70071ebc8dc52c01916102716102413373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b9161024d811515615697565b61026a610261600185015463ffffffff1690565b63ffffffff1690565b11156156fc565b54926103366dffffffffffffffffffffffffffff946102f461029834888460781c166121d5565b966102a4881515615761565b6102b0818911156157c6565b6102d4816102bc6105ec565b941684906dffffffffffffffffffffffffffff169052565b6001602084015287166dffffffffffffffffffffffffffff166040830152565b63ffffffff83166060820152600060808201526103313373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61582b565b6040805194855263ffffffff90911660208501523393918291820190565b0390a2005b600080fd5b6024359077ffffffffffffffffffffffffffffffffffffffffffffffff8216820361035957565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043577ffffffffffffffffffffffffffffffffffffffffffffffff81168103610359576104149033600052600160205260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b61041e8154612491565b9055005b73ffffffffffffffffffffffffffffffffffffffff81160361035957565b6024359061044d82610422565b565b60c4359061044d82610422565b359061044d82610422565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760206104fc6004356104a881610422565b73ffffffffffffffffffffffffffffffffffffffff6104c561035e565b91166000526001835260406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b54604051908152f35b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60a0810190811067ffffffffffffffff82111761055157604052565b610559610505565b604052565b610100810190811067ffffffffffffffff82111761055157604052565b67ffffffffffffffff811161055157604052565b6060810190811067ffffffffffffffff82111761055157604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff82111761055157604052565b6040519061044d82610535565b6040519060c0820182811067ffffffffffffffff82111761055157604052565b604051906040820182811067ffffffffffffffff82111761055157604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610675575b01160190565b61067d610505565b61066f565b92919261068e82610639565b9161069c60405193846105ab565b829481845281830111610359578281602093846000960137010152565b9181601f840112156103595782359167ffffffffffffffff8311610359576020838186019501011161035957565b5034610359576101c07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff60043581811161035957366023820112156103595761074a903690602481600401359101610682565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdc36016101808112610359576101006040519161078783610535565b12610359576040516107988161055e565b6107a0610440565b815260443560208201526064356040820152608435606082015260a43560808201526107ca61044f565b60a082015260e43560c08201526101043560e082015281526101243560208201526101443560408201526101643560608201526101843560808201526101a4359182116103595761083e9261082661082e9336906004016106b9565b9290916128b1565b6040519081529081906020820190565b0390f35b9060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8301126103595760043567ffffffffffffffff9283821161035957806023830112156103595781600401359384116103595760248460051b830101116103595760240191906024356108b781610422565b90565b5034610359576108c936610842565b6108d4929192611e3a565b6108dd83611d2d565b60005b84811061095d57506000927fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f9728480a183915b85831061092d576109238585611ed7565b6100216001600255565b909193600190610953610941878987611dec565b61094b8886611dca565b51908861233f565b0194019190610912565b8061098b610984610972600194869896611dca565b5161097e848a88611dec565b84613448565b9083612f30565b019290926108e0565b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356109d081610422565b6024359060009133835282602052604083206dffffffffffffffffffffffffffff81541692838311610ad557848373ffffffffffffffffffffffffffffffffffffffff829593610a788496610a3f610a2c8798610ad29c6121c0565b6dffffffffffffffffffffffffffff1690565b6dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810185905233917fd1c19fbcd4551a5edfb66d43d2e337c04837afda3482b42bdf569a8fccdae5fb91a2165af1610acc611ea7565b50615ba2565b80f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f576974686472617720616d6f756e7420746f6f206c61726765000000000000006044820152fd5b50346103595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576020600435610b7181610422565b73ffffffffffffffffffffffffffffffffffffffff610b8e61035e565b911660005260018252610bc98160406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000006040519260401b16178152f35b503461035957610c0736610842565b610c0f611e3a565b6000805b838210610df657610c249150611d2d565b7fbb47ee3e183a558b1a2ff0874b079f3fc5478b7454eacf2bfc5af2ff5878f972600080a16000805b848110610d5c57505060008093815b818110610c9357610923868660007f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d8180a2611ed7565b610cf7610ca182848a6124cb565b610ccc610cb3610cb36020840161256d565b73ffffffffffffffffffffffffffffffffffffffff1690565b7f575ff3acadd5ab348fe1855e217e0f3678f8d767d7494c9f9fefbee2e17cca4d600080a280612519565b906000915b808310610d1457505050610d0f90612491565b610c5c565b90919497610d4f610d49610d5592610d438c8b610d3c82610d368e8b8d611dec565b92611dca565b519161233f565b906121d5565b99612491565b95612491565b9190610cfc565b610d678186886124cb565b6020610d7f610d768380612519565b9290930161256d565b9173ffffffffffffffffffffffffffffffffffffffff60009316905b828410610db45750505050610daf90612491565b610c4d565b90919294610d4f81610de985610de2610dd0610dee968d611dca565b51610ddc8c8b8a611dec565b85613448565b908b613148565b612491565b929190610d9b565b610e018285876124cb565b90610e0c8280612519565b92610e1c610cb36020830161256d565b9173ffffffffffffffffffffffffffffffffffffffff8316610e416001821415612577565b610e62575b505050610e5c91610e56916121d5565b91612491565b90610c13565b909592610e7b6040999693999895989788810190611fc8565b92908a3b156103595789938b918a5193849283927fe3563a4f00000000000000000000000000000000000000000000000000000000845260049e8f850193610ec294612711565b03815a93600094fa9081610f3b575b50610f255786517f86a9f75000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a16818a0190815281906020010390fd5b0390fd5b9497509295509093509181610e56610e5c610e46565b80610f48610f4e9261057b565b8061111e565b38610ed1565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761083e73ffffffffffffffffffffffffffffffffffffffff600435610fa881610422565b608060409283928351610fba81610535565b60009381858093528260208201528287820152826060820152015216815280602052209061104965ffffffffffff6001835194610ff686610535565b80546dffffffffffffffffffffffffffff8082168852607082901c60ff161515602089015260789190911c1685870152015463ffffffff8116606086015260201c16608084019065ffffffffffff169052565b5191829182919091608065ffffffffffff8160a08401956dffffffffffffffffffffffffffff808251168652602082015115156020870152604082015116604086015263ffffffff6060820151166060860152015116910152565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff6004356110f581610422565b16600052600060205260206dffffffffffffffffffffffffffff60406000205416604051908152f35b600091031261035957565b50346103595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957602060405160018152f35b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261035957600467ffffffffffffffff8135818111610359576111b590369084016106b9565b9050602435916111c483610422565b604435908111610359576111db90369085016106b9565b92909115908161132d575b506112c6576014821015611236575b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160409060208152600060208201520190565b6112466112529261124c92612b88565b90612b96565b60601c90565b3b1561125f5738806111f5565b610f21906040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601b60208201527f41413330207061796d6173746572206e6f74206465706c6f796564000000000060408201520190565b610f21836040519182917f08c379a0000000000000000000000000000000000000000000000000000000008352820160609060208152601960208201527f41413230206163636f756e74206e6f74206465706c6f7965640000000000000060408201520190565b90503b15386111e6565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595760043567ffffffffffffffff81116103595761138960249136906004016106b9565b906113bf6040519283927f570e1a3600000000000000000000000000000000000000000000000000000000845260048401612d2c565b0360208273ffffffffffffffffffffffffffffffffffffffff92816000857f0000000000000000000000000000000000000000000000000000000000000000165af1918215611471575b600092611441575b50604051917f6ca7b806000000000000000000000000000000000000000000000000000000008352166004820152fd5b61146391925060203d811161146a575b61145b81836105ab565b810190612d17565b9038611411565b503d611451565b611479612183565b611409565b90816101609103126103595790565b60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc820112610359576004359067ffffffffffffffff8211610359576108b79160040161147e565b50346103595760206114ef6114ea3661148d565b612a0c565b604051908152f35b5060207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595761002160043561153181610422565b61562b565b5034610359576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126116b1573381528060205260408120600181019063ffffffff825416908115611653576115f06115b5611618936115a76115a2855460ff9060701c1690565b61598f565b65ffffffffffff42166159f4565b84547fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff16602082901b69ffffffffffff000000001617909455565b7fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff8154169055565b60405165ffffffffffff91909116815233907ffa9b3c14cc825c412c9ed81b3ba365a5b459439403f18829e572ed53a4180f0a90602090a280f35b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207374616b6564000000000000000000000000000000000000000000006044820152fd5b80fd5b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610359576004356116f081610422565b610ad273ffffffffffffffffffffffffffffffffffffffff6117323373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b926117ea611755610a2c86546dffffffffffffffffffffffffffff9060781c1690565b94611761861515615a0e565b6117c26001820161179a65ffffffffffff611786835465ffffffffffff9060201c1690565b16611792811515615a73565b421015615ad8565b80547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055565b7fffffff0000000000000000000000000000ffffffffffffffffffffffffffffff8154169055565b6040805173ffffffffffffffffffffffffffffffffffffffff831681526020810186905233917fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda391a2600080809581948294165af1611847611ea7565b50615b3d565b50346103595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595767ffffffffffffffff6004358181116103595761189e90369060040161147e565b602435916118ab83610422565b604435908111610359576118c6610f219136906004016106b9565b6118ce611caa565b6118d785612e2b565b6118ea6118e48287613240565b906153ba565b946118fa826000924384526121e2565b96438252819360609573ffffffffffffffffffffffffffffffffffffffff8316611981575b50505050608001519361194e6040611940602084015165ffffffffffff1690565b92015165ffffffffffff1690565b906040519687967f8b7ac980000000000000000000000000000000000000000000000000000000008852600488016127e1565b8395508394965061199b60409492939451809481936127d3565b03925af19060806119aa611ea7565b92919038808061191f565b5034610359576119c43661148d565b6119cc611caa565b6119d582612e2b565b6119df8183613240565b825160a00151919391611a0c9073ffffffffffffffffffffffffffffffffffffffff166154dc565b6154dc565b90611a30611a07855173ffffffffffffffffffffffffffffffffffffffff90511690565b94611a39612b50565b50611a68611a4c60409586810190611fc8565b90600060148310611bc55750611246611a079261124c92612b88565b91611a72916153ba565b805173ffffffffffffffffffffffffffffffffffffffff169073ffffffffffffffffffffffffffffffffffffffff821660018114916080880151978781015191886020820151611ac79065ffffffffffff1690565b91015165ffffffffffff16916060015192611ae06105f9565b9a8b5260208b0152841515898b015265ffffffffffff1660608a015265ffffffffffff16608089015260a088015215159081611bbc575b50611b515750610f2192519485947fe0cff05f00000000000000000000000000000000000000000000000000000000865260048601612cbd565b9190610f2193611b60846154dc565b611b87611b6b610619565b73ffffffffffffffffffffffffffffffffffffffff9096168652565b6020850152519586957ffaecb4e400000000000000000000000000000000000000000000000000000000875260048701612c2b565b90501538611b17565b9150506154dc565b50346103595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126103595773ffffffffffffffffffffffffffffffffffffffff600435611c1e81610422565b16600052600060205260a0604060002065ffffffffffff60018254920154604051926dffffffffffffffffffffffffffff90818116855260ff8160701c161515602086015260781c16604084015263ffffffff8116606084015260201c166080820152f35b60209067ffffffffffffffff8111611c9d575b60051b0190565b611ca5610505565b611c96565b60405190611cb782610535565b604051608083610100830167ffffffffffffffff811184821017611d20575b60405260009283815283602082015283604082015283606082015283838201528360a08201528360c08201528360e082015281528260208201528260408201528260608201520152565b611d28610505565b611cd6565b90611d3782611c83565b611d4460405191826105ab565b8281527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0611d728294611c83565b019060005b828110611d8357505050565b602090611d8e611caa565b82828501015201611d77565b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020918151811015611ddf575b60051b010190565b611de7611d9a565b611dd7565b9190811015611e2d575b60051b810135907ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea181360301821215610359570190565b611e35611d9a565b611df6565b6002805414611e495760028055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152fd5b3d15611ed2573d90611eb882610639565b91611ec660405193846105ab565b82523d6000602084013e565b606090565b73ffffffffffffffffffffffffffffffffffffffff168015611f6a57600080809381935af1611f04611ea7565b5015611f0c57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f41413931206661696c65642073656e6420746f2062656e6566696369617279006044820152fd5b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f4141393020696e76616c69642062656e656669636961727900000000000000006044820152fd5b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff82116103595760200191813603831361035957565b90816020910312610359575190565b601f82602094937fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938186528686013760008582860101520116010190565b60005b83811061207a5750506000910152565b818101518382015260200161206a565b907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f6020936120c681518092818752878088019101612067565b0116010190565b906120e76080916108b796946101c0808652850191612028565b9360e0815173ffffffffffffffffffffffffffffffffffffffff80825116602087015260208201516040870152604082015160608701526060820151858701528482015160a087015260a08201511660c086015260c081015182860152015161010084015260208101516101208401526040810151610140840152606081015161016084015201516101808201526101a081840391015261208a565b506040513d6000823e3d90fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b919082039182116121cd57565b61044d612190565b919082018092116121cd57565b905a918160206121fb6060830151936060810190611fc8565b906122348560405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af16000918161230f575b50612308575060206000803e7fdeaddead000000000000000000000000000000000000000000000000000000006000511461229b5761229561228a6108b7945a906121c0565b6080840151906121d5565b91614afc565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9250505090565b61233191925060203d8111612338575b61232981836105ab565b810190612019565b9038612244565b503d61231f565b909291925a9380602061235b6060830151946060810190611fc8565b906123948660405195869485947f1d732756000000000000000000000000000000000000000000000000000000008652600486016120cd565b03816000305af160009181612471575b5061246a575060206000803e7fdeaddead00000000000000000000000000000000000000000000000000000000600051146123fc576123f66123eb6108b795965a906121c0565b6080830151906121d5565b92614ddf565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152600f60408201527f41413935206f7574206f6620676173000000000000000000000000000000000060608201520190565b9450505050565b61248a91925060203d81116123385761232981836105ab565b90386123a4565b6001907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146124bf570190565b6124c7612190565b0190565b919081101561250c575b60051b810135907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa181360301821215610359570190565b612514611d9a565b6124d5565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610359570180359067ffffffffffffffff821161035957602001918160051b3603831361035957565b356108b781610422565b1561257e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393620696e76616c69642061676772656761746f720000000000000000006044820152fd5b90357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18236030181121561035957016020813591019167ffffffffffffffff821161035957813603831361035957565b6108b7916126578161263d8461045c565b73ffffffffffffffffffffffffffffffffffffffff169052565b602082013560208201526126f26126a361268861267760408601866125dc565b610160806040880152860191612028565b61269560608601866125dc565b908583036060870152612028565b6080840135608084015260a084013560a084015260c084013560c084015260e084013560e084015261010080850135908401526101206126e5818601866125dc565b9185840390860152612028565b9161270361014091828101906125dc565b929091818503910152612028565b949391929083604087016040885252606086019360608160051b8801019482600090815b848310612754575050505050508460206108b795968503910152612028565b9091929394977fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08b820301855288357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffea1843603018112156127cf57600191846127bd920161262c565b98602090810196950193019190612735565b8280fd5b908092918237016000815290565b9290936108b796959260c0958552602085015265ffffffffffff8092166040850152166060830152151560808201528160a0820152019061208a565b1561282457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4141393220696e7465726e616c2063616c6c206f6e6c790000000000000000006044820152fd5b9060406108b79260008152816020820152019061208a565b6040906108b793928152816020820152019061208a565b909291925a936128c230331461281d565b8151946040860151955a6113886060830151890101116129e2576108b7966000958051612909575b50505090612903915a9003608084015101943691610682565b91615047565b612938916129349161292f855173ffffffffffffffffffffffffffffffffffffffff1690565b615c12565b1590565b612944575b80806128ea565b61290392919450612953615c24565b908151612967575b5050600193909161293d565b7f1c4fada7374c0a9ee8841fc38afe82932dc0f8e69012e927f061a8bae611a20173ffffffffffffffffffffffffffffffffffffffff6020870151926129d860206129c6835173ffffffffffffffffffffffffffffffffffffffff1690565b9201519560405193849316968361289a565b0390a3388061295b565b7fdeaddead0000000000000000000000000000000000000000000000000000000060005260206000fd5b612a22612a1c6040830183611fc8565b90615c07565b90612a33612a1c6060830183611fc8565b90612ae9612a48612a1c610120840184611fc8565b60405194859360208501956101008201359260e08301359260c08101359260a08201359260808301359273ffffffffffffffffffffffffffffffffffffffff60208201359135168c9693909a9998959261012098959273ffffffffffffffffffffffffffffffffffffffff6101408a019d168952602089015260408801526060870152608086015260a085015260c084015260e08301526101008201520152565b0391612b1b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0938481018352826105ab565b51902060408051602081019283523091810191909152466060820152608092830181529091612b4a90826105ab565b51902090565b604051906040820182811067ffffffffffffffff821117612b7b575b60405260006020838281520152565b612b83610505565b612b6c565b906014116103595790601490565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009035818116939260148110612bcb57505050565b60140360031b82901b16169150565b9060c060a06108b793805184526020810151602085015260408101511515604085015265ffffffffffff80606083015116606086015260808201511660808501520151918160a0820152019061208a565b9294612c8c61044d95612c7a610100959998612c68612c54602097610140808c528b0190612bda565b9b878a019060208091805184520151910152565b80516060890152602001516080880152565b805160a08701526020015160c0860152565b73ffffffffffffffffffffffffffffffffffffffff81511660e0850152015191019060208091805184520151910152565b612d0661044d94612cf4612cdf60a0959998969960e0865260e0860190612bda565b98602085019060208091805184520151910152565b80516060840152602001516080830152565b019060208091805184520151910152565b9081602091031261035957516108b781610422565b9160206108b7938181520191612028565b90612d6c73ffffffffffffffffffffffffffffffffffffffff916108b797959694606085526060850191612028565b941660208201526040818503910152612028565b60009060033d11612d8d57565b905060046000803e60005160e01c90565b600060443d106108b7576040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc91823d016004833e815167ffffffffffffffff918282113d602484011117612e1a57818401948551938411612e22573d85010160208487010111612e1a57506108b7929101602001906105ab565b949350505050565b50949350505050565b612e386040820182611fc8565b612e50612e448461256d565b93610120810190611fc8565b9290303b1561035957600093612e949160405196879586957f957122ab00000000000000000000000000000000000000000000000000000000875260048701612d3d565b0381305afa9081612f1d575b5061044d576001612eaf612d80565b6308c379a014612ec8575b612ec057565b61044d612183565b612ed0612d9e565b80612edc575b50612eba565b80516000925015612ed657610f21906040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b80610f48612f2a9261057b565b38612ea0565b9190612f3b9061317f565b73ffffffffffffffffffffffffffffffffffffffff929183166130da5761306c57612f659061317f565b9116612ffe57612f725750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602160448201527f41413332207061796d61737465722065787069726564206f72206e6f7420647560648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413334207369676e6174757265206572726f7200000000000000000000000060608201520190565b610f21836040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601760408201527f414132322065787069726564206f72206e6f742064756500000000000000000060608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601460408201527f41413234207369676e6174757265206572726f7200000000000000000000000060608201520190565b9291906131549061317f565b909273ffffffffffffffffffffffffffffffffffffffff808095169116036130da5761306c57612f65905b80156131d25761318e9061535f565b73ffffffffffffffffffffffffffffffffffffffff65ffffffffffff8060408401511642119081156131c2575b5091511691565b90506020830151164210386131bb565b50600090600090565b156131e257565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f41413934206761732076616c756573206f766572666c6f7700000000000000006044820152fd5b916000915a9381519061325382826136b3565b61325c81612a0c565b602084015261329a6effffffffffffffffffffffffffffff60808401516060850151176040850151176101008401359060e0850135171711156131db565b6132a382613775565b6132ae818584613836565b97906132df6129346132d4875173ffffffffffffffffffffffffffffffffffffffff1690565b60208801519061546c565b6133db576132ec43600052565b73ffffffffffffffffffffffffffffffffffffffff61332460a0606097015173ffffffffffffffffffffffffffffffffffffffff1690565b166133c1575b505a810360a0840135106133545760809360c092604087015260608601525a900391013501910152565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413430206f76657220766572696669636174696f6e4761734c696d6974000060608201520190565b909350816133d2929750858461455c565b9590923861332a565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b9290916000925a825161345b81846136b3565b61346483612a0c565b60208501526134a26effffffffffffffffffffffffffffff60808301516060840151176040840151176101008601359060e0870135171711156131db565b6134ab81613775565b6134b78186868b613ba2565b98906134e86129346134dd865173ffffffffffffffffffffffffffffffffffffffff1690565b60208701519061546c565b6135e0576134f543600052565b73ffffffffffffffffffffffffffffffffffffffff61352d60a0606096015173ffffffffffffffffffffffffffffffffffffffff1690565b166135c5575b505a840360a08601351061355f5750604085015260608401526080919060c0905a900391013501910152565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601e60448201527f41413430206f76657220766572696669636174696f6e4761734c696d697400006064820152608490fd5b909250816135d79298508686856147ef565b96909138613533565b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601a60408201527f4141323520696e76616c6964206163636f756e74206e6f6e636500000000000060608201520190565b1561365557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f4141393320696e76616c6964207061796d6173746572416e64446174610000006044820152fd5b613725906136dd6136c38261256d565b73ffffffffffffffffffffffffffffffffffffffff168452565b602081013560208401526080810135604084015260a0810135606084015260c0810135608084015260e081013560c084015261010081013560e0840152610120810190611fc8565b90811561376a5761374f61124c6112468460a09461374a601461044d9998101561364e565b612b88565b73ffffffffffffffffffffffffffffffffffffffff16910152565b505060a06000910152565b60a081015173ffffffffffffffffffffffffffffffffffffffff16156137b75760c060035b60ff60408401519116606084015102016080830151019101510290565b60c0600161379a565b6137d86040929594939560608352606083019061262c565b9460208201520152565b9061044d602f60405180947f414132332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b810103600f8101855201836105ab565b916000926000925a936139046020835193613865855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d6138766040830183611fc8565b9084613e0d565b60a086015173ffffffffffffffffffffffffffffffffffffffff16906138a243600052565b85809373ffffffffffffffffffffffffffffffffffffffff809416159889613b3a575b60600151908601516040517f3a871cdd0000000000000000000000000000000000000000000000000000000081529788968795869390600485016137c0565b03938a1690f1829181613b1a575b50613b115750600190613923612d80565b6308c379a014613abd575b50613a50575b613941575b50505a900391565b61396b9073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b613986610a2c82546dffffffffffffffffffffffffffff1690565b8083116139e3576139dc926dffffffffffffffffffffffffffff9103166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b3880613939565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601760408201527f41413231206469646e2774207061792070726566756e6400000000000000000060608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613ac5612d9e565b9081613ad1575061392e565b610f2191613adf91506137e2565b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301612882565b95506139349050565b613b3391925060203d81116123385761232981836105ab565b9038613912565b9450613b80610a2c613b6c8c73ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b546dffffffffffffffffffffffffffff1690565b8b811115613b975750856060835b969150506138c5565b606087918d03613b8e565b90926000936000935a94613beb6020835193613bd2855173ffffffffffffffffffffffffffffffffffffffff1690565b9561387d613be36040830183611fc8565b90848c61412b565b03938a1690f1829181613ded575b50613de45750600190613c0a612d80565b6308c379a014613d8e575b50613d20575b613c29575b5050505a900391565b613c539073ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b91613c6f610a2c84546dffffffffffffffffffffffffffff1690565b90818311613cba575082547fffffffffffffffffffffffffffffffffffff0000000000000000000000000000169190036dffffffffffffffffffffffffffff16179055388080613c20565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601760448201527f41413231206469646e2774207061792070726566756e640000000000000000006064820152608490fd5b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601660408201527f4141323320726576657274656420286f72204f4f47290000000000000000000060608201520190565b613d96612d9e565b9081613da25750613c15565b8691613dae91506137e2565b90610f216040519283927f220266b60000000000000000000000000000000000000000000000000000000084526004840161289a565b9650613c1b9050565b613e0691925060203d81116123385761232981836105ab565b9038613bf9565b909180613e1957505050565b81515173ffffffffffffffffffffffffffffffffffffffff1692833b6140be57606083510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280613e78878760048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156140b1575b600092614091575b508082169586156140245716809503613fb7573b15613f4a5761124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d93613f1193612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a3565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313520696e6974436f6465206d757374206372656174652073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6140aa91925060203d811161146a5761145b81836105ab565b9038613ec7565b6140b9612183565b613ebf565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601f60408201527f414131302073656e64657220616c726561647920636f6e73747275637465640060608201520190565b9290918161413a575b50505050565b82515173ffffffffffffffffffffffffffffffffffffffff1693843b6143e257606084510151604051907f570e1a3600000000000000000000000000000000000000000000000000000000825260208280614199888860048401612d2c565b0381600073ffffffffffffffffffffffffffffffffffffffff95867f00000000000000000000000000000000000000000000000000000000000000001690f19182156143d5575b6000926143b5575b5080821696871561434757168096036142d9573b15614273575061124c6112467fd51a9c61267aa6196961883ecf5ff2da6619c37dac0fa92122513fb32c032d2d9361423393612b88565b602083810151935160a001516040805173ffffffffffffffffffffffffffffffffffffffff9485168152939091169183019190915290a338808080614134565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f4141313520696e6974436f6465206d757374206372656174652073656e6465726064820152608490fd5b610f21826040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152602060408201527f4141313420696e6974436f6465206d7573742072657475726e2073656e64657260608201520190565b610f21846040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601b60408201527f4141313320696e6974436f6465206661696c6564206f72204f4f47000000000060608201520190565b6143ce91925060203d811161146a5761145b81836105ab565b90386141e8565b6143dd612183565b6141e0565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601f60448201527f414131302073656e64657220616c726561647920636f6e7374727563746564006064820152608490fd5b1561444f57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f4141343120746f6f206c6974746c6520766572696669636174696f6e476173006044820152fd5b919060408382031261035957825167ffffffffffffffff81116103595783019080601f83011215610359578151916144e483610639565b916144f260405193846105ab565b838352602084830101116103595760209261451291848085019101612067565b92015190565b9061044d602f60405180947f414133332072657665727465643a20000000000000000000000000000000000060208301526138268151809260208686019101612067565b93919260609460009460009380519261459b60a08a86015195614580888811614448565b015173ffffffffffffffffffffffffffffffffffffffff1690565b916145c68373ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b946145e2610a2c87546dffffffffffffffffffffffffffff1690565b968588106147825773ffffffffffffffffffffffffffffffffffffffff60208a98946146588a966dffffffffffffffffffffffffffff8b6146919e03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b015194604051998a98899788937ff465c77e000000000000000000000000000000000000000000000000000000008552600485016137c0565b0395169103f190818391849361475c575b506147555750506001906146b4612d80565b6308c379a014614733575b506146c657565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601660408201527f4141333320726576657274656420286f72204f4f47290000000000000000000060608201520190565b61473b612d9e565b908161474757506146bf565b610f2191613adf9150614518565b9450925050565b90925061477b91503d8085833e61477381836105ab565b8101906144ad565b91386146a2565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b91949293909360609560009560009382519061481660a08b84015193614580848611614448565b936148418573ffffffffffffffffffffffffffffffffffffffff166000526000602052604060002090565b61485c610a2c82546dffffffffffffffffffffffffffff1690565b8781106149b7579273ffffffffffffffffffffffffffffffffffffffff60208a989693946146588a966dffffffffffffffffffffffffffff8d6148d69e9c9a03166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b0395169103f1908183918493614999575b506149915750506001906148f9612d80565b6308c379a014614972575b5061490c5750565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152601660448201527f4141333320726576657274656420286f72204f4f4729000000000000000000006064820152608490fd5b61497a612d9e565b90816149865750614904565b613dae925050614518565b955093505050565b9092506149b091503d8085833e61477381836105ab565b91386148e7565b610f218a6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601e60408201527f41413331207061796d6173746572206465706f73697420746f6f206c6f77000060608201520190565b60031115614a2f57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b929190614a7c6040916002865260606020870152606086019061208a565b930152565b939291906003811015614a2f57604091614a7c91865260606020870152606086019061208a565b9061044d603660405180947f4141353020706f73744f702072657665727465643a20000000000000000000006020830152614aec8151809260208686019101612067565b81010360168101855201836105ab565b929190925a93600091805191614b1183615318565b9260a0810195614b35875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff93908481169081614ca457505050614b76825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f94614bc26020928c614c329551039061553a565b015194896020614c04614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b9a5173ffffffffffffffffffffffffffffffffffffffff1690565b9401519785604051968796169a16988590949392606092608083019683521515602083015260408201520152565b0390a4565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152602060408201527f414135312070726566756e642062656c6f772061637475616c476173436f737460608201520190565b9a918051614cb4575b5050614b78565b6060850151600099509091803b15614ddb579189918983614d07956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081614dc8575b50614dc3576001614d20612d80565b6308c379a014614da4575b614d37575b3880614cad565b6040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b614dac612d9e565b80614db75750614d2b565b613adf610f2191614aa8565b614d30565b80610f48614dd59261057b565b38614d11565b8980fd5b9392915a90600092805190614df382615318565b9360a0830196614e17885173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff95908681169081614f0d57505050614e58845173ffffffffffffffffffffffffffffffffffffffff1690565b915b5a9003019485029860408301908a825110614ea757507f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f949392614bc2614c32938c60209451039061553a565b604080517f220266b600000000000000000000000000000000000000000000000000000000815260048101929092526024820152602060448201527f414135312070726566756e642062656c6f772061637475616c476173436f73746064820152608490fd5b93918051614f1d575b5050614e5a565b606087015160009a509091803b1561504357918a918a83614f70956040518097819682957fa9a234090000000000000000000000000000000000000000000000000000000084528c029060048401614a5e565b0393f19081615030575b5061502b576001614f89612d80565b6308c379a01461500e575b614fa0575b3880614f16565b610f218b6040519182917f220266b600000000000000000000000000000000000000000000000000000000835260048301608091815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b615016612d9e565b806150215750614f94565b613dae8d91614aa8565b614f99565b80610f4861503d9261057b565b38614f7a565b8a80fd5b909392915a9480519161505983615318565b9260a081019561507d875173ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff938185169182615165575050506150bd825173ffffffffffffffffffffffffffffffffffffffff1690565b985b5a90030193840297604084019089825110614c37577f49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f946151096020928c614c329551039061553a565b61511288614a25565b015194896020615139614be9865173ffffffffffffffffffffffffffffffffffffffff1690565b940151604080519182529815602082015297880152606087015290821695909116939081906080820190565b9a918151615175575b50506150bf565b8784026151818a614a25565b60028a1461520c576060860151823b15610359576151d493600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f180156151ff575b6151ec575b505b388061516e565b80610f486151f99261057b565b386151e3565b615207612183565b6151de565b6060860151823b156103595761525793600080948d604051978896879586937fa9a2340900000000000000000000000000000000000000000000000000000000855260048501614a81565b0393f19081615305575b50615300576001615270612d80565b6308c379a0146152ed575b156151e5576040517f220266b600000000000000000000000000000000000000000000000000000000815280610f21600482016080906000815260406020820152601260408201527f4141353020706f73744f7020726576657274000000000000000000000000000060608201520190565b6152f5612d9e565b80614db7575061527b565b6151e5565b80610f486153129261057b565b38615261565b60e060c082015191015180821461533c57480180821015615337575090565b905090565b5090565b6040519061534d8261058f565b60006040838281528260208201520152565b615367615340565b5065ffffffffffff808260a01c1680156153b3575b604051926153898461058f565b73ffffffffffffffffffffffffffffffffffffffff8116845260d01c602084015216604082015290565b508061537c565b6153cf6153d5916153c9615340565b5061535f565b9161535f565b9073ffffffffffffffffffffffffffffffffffffffff9182825116928315615461575b65ffffffffffff928391826040816020850151169301511693836040816020840151169201511690808410615459575b50808511615451575b506040519561543f8761058f565b16855216602084015216604082015290565b935038615431565b925038615428565b8151811693506153f8565b73ffffffffffffffffffffffffffffffffffffffff16600052600160205267ffffffffffffffff6154c88260401c60406000209077ffffffffffffffffffffffffffffffffffffffffffffffff16600052602052604060002090565b918254926154d584612491565b9055161490565b9073ffffffffffffffffffffffffffffffffffffffff6154fa612b50565b9216600052600060205263ffffffff600160406000206dffffffffffffffffffffffffffff815460781c1685520154166020830152565b61044d3361562b565b73ffffffffffffffffffffffffffffffffffffffff16600052600060205260406000206dffffffffffffffffffffffffffff8082541692830180931161561e575b8083116155c05761044d92166dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f6465706f736974206f766572666c6f77000000000000000000000000000000006044820152fd5b615626612190565b61557b565b73ffffffffffffffffffffffffffffffffffffffff9061564b348261553a565b168060005260006020527f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460206dffffffffffffffffffffffffffff60406000205416604051908152a2565b1561569e57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6d757374207370656369667920756e7374616b652064656c61790000000000006044820152fd5b1561570357565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f63616e6e6f7420646563726561736520756e7374616b652074696d65000000006044820152fd5b1561576857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6e6f207374616b652073706563696669656400000000000000000000000000006044820152fd5b156157cd57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f7374616b65206f766572666c6f770000000000000000000000000000000000006044820152fd5b9065ffffffffffff6080600161044d9461588b6dffffffffffffffffffffffffffff86511682906dffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffff0000000000000000000000000000825416179055565b602085015115156eff000000000000000000000000000082549160701b16807fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff83161783557fffffff000000000000000000000000000000ffffffffffffffffffffffffffff7cffffffffffffffffffffffffffff000000000000000000000000000000604089015160781b16921617178155019263ffffffff6060820151167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000008554161784550151167fffffffffffffffffffffffffffffffffffffffffffff000000000000ffffffff69ffffffffffff0000000083549260201b169116179055565b1561599657565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f616c726561647920756e7374616b696e670000000000000000000000000000006044820152fd5b91909165ffffffffffff808094169116019182116121cd57565b15615a1557565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f207374616b6520746f2077697468647261770000000000000000000000006044820152fd5b15615a7a57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f6d7573742063616c6c20756e6c6f636b5374616b6528292066697273740000006044820152fd5b15615adf57565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f5374616b65207769746864726177616c206973206e6f742064756500000000006044820152fd5b15615b4457565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661696c656420746f207769746864726177207374616b6500000000000000006044820152fd5b15615ba957565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6661696c656420746f20776974686472617700000000000000000000000000006044820152fd5b816040519182372090565b9060009283809360208451940192f190565b3d610800808211615c4b575b50604051906020818301016040528082526000602083013e90565b905038615c3056fea2646970667358221220a706d8b02d7086d80e9330811f5af84b2614abdc5e9a1f2260126070a31d7cee64736f6c63430008110033", + "storage": [] + } + ] + }, + "fee": { + "params": { + "no_base_fee": false, + "base_fee_change_denominator": 8, + "elasticity_multiplier": 2, + "enable_height": "0", + "base_fee": "1000000000", + "min_gas_price": "20000000000.000000000000000000", + "min_gas_multiplier": "0.500000000000000000" + }, + "block_gas": "0" + }, + "feegrant": { + "allowances": [] + }, + "feeibc": { + "identified_fees": [], + "fee_enabled_channels": [], + "registered_payees": [], + "registered_counterparty_payees": [], + "forward_relayers": [] + }, + "genutil": { + "gen_txs": [ + { + "body": { + "messages": [ + { + "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", + "description": { + "moniker": "localtestnet", + "identity": "", + "website": "", + "security_contact": "", + "details": "" + }, + "commission": { + "rate": "0.100000000000000000", + "max_rate": "0.200000000000000000", + "max_change_rate": "0.010000000000000000" + }, + "min_self_delegation": "1", + "delegator_address": "", + "validator_address": "artvaloper1dq4gtx924wn6k034qfxel0klacty2gd7k6rtfd", + "pubkey": { + "@type": "/cosmos.crypto.ed25519.PubKey", + "key": "+SrfTnc7KUBAvp1s2LdutuDBc6kr6+nBCXtzPG7t4VM=" + }, + "value": { + "denom": "aart", + "amount": "1000000000000000000000" + } + } + ], + "memo": "f4227c07ea565d792ab0b62ac8ca36f05dc54d57@192.168.50.101:26656", + "timeout_height": "0", + "extension_options": [], + "non_critical_extension_options": [] + }, + "auth_info": { + "signer_infos": [ + { + "public_key": { + "@type": "/artela.crypto.ethsecp256k1.PubKey", + "key": "Awf7YAGa6sZwRCo/iEUoCubZd1dPVYgf5VPGDmjPmNzk" + }, + "mode_info": { + "single": { + "mode": "SIGN_MODE_DIRECT" + } + }, + "sequence": "0" + } + ], + "fee": { + "amount": [ + { + "denom": "aart", + "amount": "4000000000000000" + } + ], + "gas_limit": "200000", + "payer": "", + "granter": "" + }, + "tip": null + }, + "signatures": [ + "SjrsqJaKSLJj/Q6zaV4E5h86YYtfkLpb+fCmCfxyz6hgGKRJ7guAC4fBTi0YrbU+wJJZeNZF3akMP+I7k/Pp8AE=" + ] + } + ] + }, + "gov": { + "starting_proposal_id": "1", + "deposits": [], + "votes": [], + "proposals": [], + "deposit_params": { + "min_deposit": [ + { + "denom": "aart" + } + ] + }, + "voting_params": null, + "tally_params": null, + "params": { + "min_deposit": [ + { + "denom": "aart", + "amount": "10000000" + } + ], + "max_deposit_period": "172800s", + "voting_period": "172800s", + "quorum": "0.334000000000000000", + "threshold": "0.500000000000000000", + "veto_threshold": "0.334000000000000000", + "min_initial_deposit_ratio": "0.000000000000000000", + "proposal_cancel_ratio": "0.500000000000000000", + "proposal_cancel_dest": "", + "expedited_voting_period": "86400s", + "expedited_threshold": "0.667000000000000000", + "expedited_min_deposit": [ + { + "denom": "aart", + "amount": "50000000" + } + ], + "burn_vote_quorum": false, + "burn_proposal_deposit_prevote": false, + "burn_vote_veto": true, + "min_deposit_ratio": "0.010000000000000000" + }, + "constitution": "" + }, + "group": { + "group_seq": "0", + "groups": [], + "group_members": [], + "group_policy_seq": "0", + "group_policies": [], + "proposal_seq": "0", + "proposals": [], + "votes": [] + }, + "ibc": { + "client_genesis": { + "clients": [], + "clients_consensus": [], + "clients_metadata": [], + "params": { + "allowed_clients": [ + "*" + ] + }, + "create_localhost": false, + "next_client_sequence": "0" + }, + "connection_genesis": { + "connections": [], + "client_connection_paths": [], + "next_connection_sequence": "0", + "params": { + "max_expected_time_per_block": "30000000000" + } + }, + "channel_genesis": { + "channels": [], + "acknowledgements": [], + "commitments": [], + "receipts": [], + "send_sequences": [], + "recv_sequences": [], + "ack_sequences": [], + "next_channel_sequence": "0", + "params": { + "upgrade_timeout": { + "height": { + "revision_number": "0", + "revision_height": "0" + }, + "timestamp": "600000000000" + } + } + } + }, + "interchainaccounts": { + "controller_genesis_state": { + "active_channels": [], + "interchain_accounts": [], + "ports": [], + "params": { + "controller_enabled": true + } + }, + "host_genesis_state": { + "active_channels": [], + "interchain_accounts": [], + "port": "icahost", + "params": { + "host_enabled": true, + "allow_messages": [ + "*" + ] + } + } + }, + "mint": { + "minter": { + "inflation": "0.130000000000000000", + "annual_provisions": "0.000000000000000000" + }, + "params": { + "mint_denom": "aart", + "inflation_rate_change": "0.130000000000000000", + "inflation_max": "0.200000000000000000", + "inflation_min": "0.070000000000000000", + "goal_bonded": "0.670000000000000000", + "blocks_per_year": "6311520" + } + }, + "nft": { + "classes": [], + "entries": [] + }, + "params": null, + "runtime": null, + "slashing": { + "params": { + "signed_blocks_window": "100", + "min_signed_per_window": "0.500000000000000000", + "downtime_jail_duration": "600s", + "slash_fraction_double_sign": "0.050000000000000000", + "slash_fraction_downtime": "0.010000000000000000" + }, + "signing_infos": [], + "missed_blocks": [] + }, + "staking": { + "params": { + "unbonding_time": "1814400s", + "max_validators": 100, + "max_entries": 7, + "historical_entries": 10000, + "bond_denom": "aart", + "min_commission_rate": "0.000000000000000000" + }, + "last_total_power": "0", + "last_validator_powers": [], + "validators": [], + "delegations": [], + "unbonding_delegations": [], + "redelegations": [], + "exported": false + }, + "transfer": { + "port_id": "transfer", + "denom_traces": [], + "params": { + "send_enabled": true, + "receive_enabled": true + }, + "total_escrowed": [] + }, + "upgrade": {}, + "vesting": {} + }, + "consensus": { + "validators": [ + { + "address": "CF9A8D94CC8941E4963EA1D441C4BD801C3ADE80", + "pub_key": { + "type": "tendermint/PubKeyEd25519", + "value": "+SrfTnc7KUBAvp1s2LdutuDBc6kr6+nBCXtzPG7t4VM=" + }, + "power": "1000000000000000", + "name": "Rollkit Sequencer" + } + ], + "params": { + "block": { + "max_bytes": "22020096", + "max_gas": "-1" + }, + "evidence": { + "max_age_num_blocks": "100000", + "max_age_duration": "172800000000000", + "max_bytes": "1048576" + }, + "validator": { + "pub_key_types": [ + "ed25519" + ] + }, + "version": { + "app": "0" + }, + "abci": { + "vote_extensions_enable_height": "0" + } + } + } +} \ No newline at end of file diff --git a/.artela/config/gentx/gentx-f4227c07ea565d792ab0b62ac8ca36f05dc54d57.json b/.artela/config/gentx/gentx-f4227c07ea565d792ab0b62ac8ca36f05dc54d57.json new file mode 100644 index 0000000..f9f9cbc --- /dev/null +++ b/.artela/config/gentx/gentx-f4227c07ea565d792ab0b62ac8ca36f05dc54d57.json @@ -0,0 +1 @@ +{"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"localtestnet","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.100000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1","delegator_address":"","validator_address":"artvaloper1dq4gtx924wn6k034qfxel0klacty2gd7k6rtfd","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"+SrfTnc7KUBAvp1s2LdutuDBc6kr6+nBCXtzPG7t4VM="},"value":{"denom":"aart","amount":"1000000000000000000000"}}],"memo":"f4227c07ea565d792ab0b62ac8ca36f05dc54d57@192.168.50.101:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/artela.crypto.ethsecp256k1.PubKey","key":"Awf7YAGa6sZwRCo/iEUoCubZd1dPVYgf5VPGDmjPmNzk"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[{"denom":"aart","amount":"4000000000000000"}],"gas_limit":"200000","payer":"","granter":""},"tip":null},"signatures":["SjrsqJaKSLJj/Q6zaV4E5h86YYtfkLpb+fCmCfxyz6hgGKRJ7guAC4fBTi0YrbU+wJJZeNZF3akMP+I7k/Pp8AE="]} diff --git a/.artela/config/node_key.json b/.artela/config/node_key.json new file mode 100644 index 0000000..da7cea4 --- /dev/null +++ b/.artela/config/node_key.json @@ -0,0 +1 @@ +{"priv_key":{"type":"tendermint/PrivKeyEd25519","value":"/TpLlf6Fl3NxKpur44PVcJvKMs8Qh3dfZaTXeMtOo8sgVj3f4bPC//uYQyqqpKlffUX3t8oDo3AMvIIjds3SdA=="}} \ No newline at end of file diff --git a/.artela/config/priv_validator_key.json b/.artela/config/priv_validator_key.json new file mode 100644 index 0000000..ff7401a --- /dev/null +++ b/.artela/config/priv_validator_key.json @@ -0,0 +1,11 @@ +{ + "address": "CF9A8D94CC8941E4963EA1D441C4BD801C3ADE80", + "pub_key": { + "type": "tendermint/PubKeyEd25519", + "value": "+SrfTnc7KUBAvp1s2LdutuDBc6kr6+nBCXtzPG7t4VM=" + }, + "priv_key": { + "type": "tendermint/PrivKeyEd25519", + "value": "yZyMb4PieN4JlHekxUcdy+UTtHMySUar40Wk+JQw9k75Kt9OdzspQEC+nWzYt2624MFzqSvr6cEJe3M8bu3hUw==" + } +} \ No newline at end of file diff --git a/.artela/data/priv_validator_state.json b/.artela/data/priv_validator_state.json new file mode 100644 index 0000000..48f3b67 --- /dev/null +++ b/.artela/data/priv_validator_state.json @@ -0,0 +1,5 @@ +{ + "height": "0", + "round": 0, + "step": 0 +} \ No newline at end of file diff --git a/.artela/keyring-test/15248bc7b3d5c7ff22edc352b0b44bb4246fbd01.address b/.artela/keyring-test/15248bc7b3d5c7ff22edc352b0b44bb4246fbd01.address new file mode 100644 index 0000000..4124494 --- /dev/null +++ b/.artela/keyring-test/15248bc7b3d5c7ff22edc352b0b44bb4246fbd01.address @@ -0,0 +1 @@ +eyJhbGciOiJQQkVTMi1IUzI1NitBMTI4S1ciLCJjcmVhdGVkIjoiMjAyNC0wOC0xOSAxMDo1MDowNi45NjQ0NDYgKzA4MDAgQ1NUIG09KzAuMDU0NTMwNzUxIiwiZW5jIjoiQTI1NkdDTSIsInAyYyI6ODE5MiwicDJzIjoieFdWXzh5bk5UbUQtWE1sciJ9.9Y6jXvMEkqRbjyr7hUFUR7vzsCAhhJrC_TgLOIyGcY5maVAuELxGWQ.6xXyokIf0Y_FV9iu.qOBbEsrkuhA_zi-E3W2UJgWlrTAPKpAP7YWQenN2q8KxjsB4P59UFaKzbf21QvYgJCk7OUMTOFworW32Au5Wf3_l-BBu2biSpkwWpCKcABUQ6Fgl36IZ3ywZrIzxi4wpMayowgXll5qYyZQ7OL4WxR6yZoH_sBMUeX3U36ExgfGOg_LSg0Zdgwo_YhVoJdu2g0V3JnoMlLK9VkAamRNb2kOrCc_GaTv3NNAmEPAQTM5NN3jSfeY.LLwkxjWHxIU5Sy3uQW4RVw \ No newline at end of file diff --git a/.artela/keyring-test/572f6601fd35ab45617f64de0a504899360d63fb.address b/.artela/keyring-test/572f6601fd35ab45617f64de0a504899360d63fb.address new file mode 100644 index 0000000..d1a670a --- /dev/null +++ b/.artela/keyring-test/572f6601fd35ab45617f64de0a504899360d63fb.address @@ -0,0 +1 @@ +eyJhbGciOiJQQkVTMi1IUzI1NitBMTI4S1ciLCJjcmVhdGVkIjoiMjAyNC0wOC0xOSAxMDo1MDowNy4wMzAyNDYgKzA4MDAgQ1NUIG09KzAuMDUzODk4MjUxIiwiZW5jIjoiQTI1NkdDTSIsInAyYyI6ODE5MiwicDJzIjoiSjlMUDh0SlN1TDg5VWpTUyJ9.5idZRLrfevOWlCtBafkY5tbFnWPWfwMW5qAr2G4sR_sUPLyRy-DIgw.nlYeV-kSI2b76_ef.gMe9BSpeBIOO5pP1qsh2EOt68JZs8bwJSSmifD4V67E2TfLsfmTCxLv-A2JLx3hpq53yjmTyS7WnBo-jTwZU0OdGw2OG6Q1jXgpJzaeA_o8oWQZXu-o870b7YsucgHM5yRjHlnUZFZ3KnLC19nqJZvihP6ewK2swNimtx9oFVMGatRX5bdKY_SipIgLQG7zfRgmwN5mndOiNfYysLn70KPpWgiJCRzdu_DgUHJoAwkID518V1G4.HjrZ9ezoSilaNbb4dRjYpA \ No newline at end of file diff --git a/.artela/keyring-test/682a8598aaaba7ab3e35024d9fbedfee164521be.address b/.artela/keyring-test/682a8598aaaba7ab3e35024d9fbedfee164521be.address new file mode 100644 index 0000000..da30a5c --- /dev/null +++ b/.artela/keyring-test/682a8598aaaba7ab3e35024d9fbedfee164521be.address @@ -0,0 +1 @@ +eyJhbGciOiJQQkVTMi1IUzI1NitBMTI4S1ciLCJjcmVhdGVkIjoiMjAyNC0wOC0xOSAxMDo1MDowNi44MzAxODcgKzA4MDAgQ1NUIG09KzAuMDUyOTI1MDQzIiwiZW5jIjoiQTI1NkdDTSIsInAyYyI6ODE5MiwicDJzIjoiRFRvaVl3UTBKbDViVW8zYSJ9.HXQGgwC2Pnx3wQBDIwrV9ZhG6t-utp_PiTBPiiOdjtfD9IEydaJxhw.IZuakb51c7cSGY8W.aytr6wIR7PrE560LnA_iJ2X8fgCZrUNKLV-Bd_YisFBr9cFSr8DWvOXMasbQVWHy1jJv_wFYzCZKIDDFAvXNSVPdRROGEuYmiIycIO3mekluGxG0umVZL0U5eqsndRr6ru0GuVyr6qYLiKf23RKiSQVd2HQSKmba7Zb-cuaR96Rtdlt3j8Jw0NNLmoJDkoT1xZ8LTr3cGJhbebtzY5TLbrLhjd2ak1dvrm_U2rE3xfwxsXy2eJw.RD9KCgcuWlknYJJU3jKj8Q \ No newline at end of file diff --git a/.artela/keyring-test/ea93f43e617a7039708820902e2746c4766c2ced.address b/.artela/keyring-test/ea93f43e617a7039708820902e2746c4766c2ced.address new file mode 100644 index 0000000..924a9ff --- /dev/null +++ b/.artela/keyring-test/ea93f43e617a7039708820902e2746c4766c2ced.address @@ -0,0 +1 @@ +eyJhbGciOiJQQkVTMi1IUzI1NitBMTI4S1ciLCJjcmVhdGVkIjoiMjAyNC0wOC0xOSAxMDo1MDowNi44OTc0MzQgKzA4MDAgQ1NUIG09KzAuMDU0Nzk2MjkzIiwiZW5jIjoiQTI1NkdDTSIsInAyYyI6ODE5MiwicDJzIjoidE5VeExOTHZMT1ZiaUFDSCJ9.t5vYOkEYMQT6tVdXc6ow9rS79FhoBuITT2WijXCXmIjxGSsamZy-qA.ly7j2X5sCsHokhKH.hkF_Na0YShBtBI6DRKKC9KXAbH52nJ3rYZ14Wca_yQ9S2IvZyFKS8ilAJBrii5LlUshESCFB5RFOUqCUtGkiMkVF3Ij5hRbuDL7LSXxOQIyYtQ8Sm6CwBcFFnkxADcRYPUjIjlZfkfF1a7IvGytk5tf5_H1kDjZ0tWqMCdJpxNJLDA5QLtWSXFwLhZO_PrsVJ4Pk4sHi_Cth-80UHDXJry8rItNoFyKK-6gvnNREY2umCEOg0_8.Z3zwzARjXM44OeI2Tp6t7g \ No newline at end of file diff --git a/.artela/keyring-test/mykey.info b/.artela/keyring-test/mykey.info new file mode 100644 index 0000000..6ca282c --- /dev/null +++ b/.artela/keyring-test/mykey.info @@ -0,0 +1 @@ +eyJhbGciOiJQQkVTMi1IUzI1NitBMTI4S1ciLCJjcmVhdGVkIjoiMjAyNC0wOC0xOSAxMDo1MDowNi44Mjg4OTQgKzA4MDAgQ1NUIG09KzAuMDUxNjMyODc2IiwiZW5jIjoiQTI1NkdDTSIsInAyYyI6ODE5MiwicDJzIjoiaEJZVFJzRU8zQmpxdFZTbiJ9.VP0GUlPTbO5v-u8svOFT86aZHK_11kuDr9UGe9OFPCg0LKvK5WNeVA.t4nkzVN3HUxQp_Br.6i3MWktkEEdWk39G0s4GEV2v-W4sNym0tYCMO7KMYp0tEwUV5hqNtnffxTwJgtFyKurIc85dKdu_LUCZGZvX__T_EKCHciSKCfIMXlmOSKN5HfIhFgRfiDw-rWEDT8kBrIlLJuYJSUmiiEOOak2th_JToA3k4D41N4n2b1gmAREuAVfv39BAogEW1kMXT2wM7xLQie_x7N_mkCxLb3TthqqdqjsM1kRNNJ8gnosKGc4j9s6EQs8HecD8WCJFzTlsaetZdj1M7II3LZtEzapi9mJl4-y4sdBScXLoK6tFjrnXPSExk5mZyYx1ZIleDr4tOu8KcLXsV3e9Ei6d8rn5y172Pz5w_hwUlk247_z-xdWUtP17jvCg7yqf6F4M0iEXZsyLNxYXFoulOq9GmxsBXT6krs4lY7ASrCSBQdqjoYrTrHBBWvf3yFOuko_5-M2gJkXKLQ.TbA6Hh0-6vVgUtQeDKaM1g \ No newline at end of file diff --git a/.artela/keyring-test/mykey2.info b/.artela/keyring-test/mykey2.info new file mode 100644 index 0000000..e70a41f --- /dev/null +++ b/.artela/keyring-test/mykey2.info @@ -0,0 +1 @@ +eyJhbGciOiJQQkVTMi1IUzI1NitBMTI4S1ciLCJjcmVhdGVkIjoiMjAyNC0wOC0xOSAxMDo1MDowNi44OTYxMTIgKzA4MDAgQ1NUIG09KzAuMDUzNDc0NDYwIiwiZW5jIjoiQTI1NkdDTSIsInAyYyI6ODE5MiwicDJzIjoiVFNwT3A5MkRmVGNGRUxEZSJ9.taha3k2SJ_qWgkzOLr2vy5cbU0nJyyfZmtkW3gH2tZCA3vWE3Ypx1g.iJHlks6MtIZhXZWw.pB3lHqq_pKotmTEQhBP8EA_OIvd8aIeVBrqsfGYF_Z1mIzFTUVqjTli_fDk9bFYWTYVLOaIvQdZJUKonEEIL7R1T6_2K3GnMy_blyiXqeZUKRHNRqJqQF0J85dG5zcIB5RmlpL6ZV6mAdXL0VOQ7pm7lSX3ud9jgxx6mbnXXxzxMXKK2E6PjUCp7UYGM5Vv-tpQTDCbp3ok6qp1uVMarSXHcLBD9lRXxd8YN2eTNj1ZV7wxO-cGOdF9K3_CEAu6M0YNY9_ZOS7bvQZtPyLE2OUsdcqkGwDW48Iflxforj-_5ktKn6d-69zPE52iNiZku1cbEmxEDDYrGRQpaAvuiOmgDnVoiaQPMDhEX9VeU4dOW2Li8ITZo9C_HSgwKDFYCGwXCwaMuXw496HU2k77I1R-pCSDXW-mTfqGi3gSTM4lwcxA0tAdkPkta341XS4rQWKkoUIf0tVYT.BV4SjgcLBukj9Cizq2Wnfg \ No newline at end of file diff --git a/.artela/keyring-test/mykey3.info b/.artela/keyring-test/mykey3.info new file mode 100644 index 0000000..82a639d --- /dev/null +++ b/.artela/keyring-test/mykey3.info @@ -0,0 +1 @@ +eyJhbGciOiJQQkVTMi1IUzI1NitBMTI4S1ciLCJjcmVhdGVkIjoiMjAyNC0wOC0xOSAxMDo1MDowNi45NjMwNzkgKzA4MDAgQ1NUIG09KzAuMDUzMTY0MjkzIiwiZW5jIjoiQTI1NkdDTSIsInAyYyI6ODE5MiwicDJzIjoiazV3M1ZkM1JGSktuNTJ0RSJ9.yGcqpoquFLBOHl2uLYiJNa_yTx3-IKW54e0x4QY7EQbQ8iwRf4Y8Eg.YMd7Ws7qRVwoJuUP.CU-pMZXyJ77CaGLkdlEaFd5ckh67ur3ZDDO8fzAFwTJWdozyROkyXbnHLOILwe9N1-SWainBkst3C0CIEpXkBkrtvpnNfexxkLOgURVeuZxOMdphiqd6LL3pDugOzkEuoACwSad4vu6gns3gtccWH_0pttaYIo-1gEhJ3do0TWKz-loXSGYQmworuQoVRH3sg3o-ClAEzGnjT8mPLiSg-i6Ey7SCRICw8Jh4XHAlJPUX2eNBCVFC-pvknZU0SKAp3owrFlUg4M3fCQL540gEM54STC2pSe4r2eI91Eb5hgLqcbALmhHE9CLUg0FuwztQ8I5FbLnWlmibEv263vLPFb4_bHghhtIkgq2UsE2QXoVvtp5sPtOpQX2ooSRS15ejpfcscYKFEUtQKbCBFrTg3vAti9Y0zxQ5931sreEsP5ynhL5Kllo0F2ZEYwk_kWUqrOdE36Vi-vCP.n2q9AmkLdzzm8DWUZmKhTw \ No newline at end of file diff --git a/.artela/keyring-test/mykey4.info b/.artela/keyring-test/mykey4.info new file mode 100644 index 0000000..9a5ec80 --- /dev/null +++ b/.artela/keyring-test/mykey4.info @@ -0,0 +1 @@ +eyJhbGciOiJQQkVTMi1IUzI1NitBMTI4S1ciLCJjcmVhdGVkIjoiMjAyNC0wOC0xOSAxMDo1MDowNy4wMjg5NzIgKzA4MDAgQ1NUIG09KzAuMDUyNjI0NTAxIiwiZW5jIjoiQTI1NkdDTSIsInAyYyI6ODE5MiwicDJzIjoiSWhkSVlsaGVmU1ZLM0JZViJ9.__GChGdR3vjDO2dEiVPmTCWkVnfNExqV-Bss0SDp4pjiLKNTa-n63A.swaHkQlqGGpF7j5t.zor4YsbImYM4RHudrZJN4eAjWEn5adn8YdOfnFkY0R7r9JAYXGu7yBPK9PsoRjqf6sj1bG6UepfKZ5RLoxc_QUt_UMvATLyXDjv7NRzrkFtAv81A-gqqjS4zGmpC5Pxf6t1DUE8GUBaR-Wv_o3rh3AuJEgasSYNnN3T-LniQ3QTprpTyuH6tRQfuBX1sJy66bJnebGcFaSFy7FRXZlGKfH8Z5TiAo5MlKEUqmQdzpgNkdOg8WszqAqSTgvsC9zgBwcHPxof38x69lJQzkPHOgIxhqyu3VYZOHU-8HDgE7MydGW0TkPOPLlr182xYwxUMa9TjUCMnPHp_B0v1sU45m8C-h7lSI8DVwtaC2cQ4nNyHJgj1NO1oOBI0_TCrCOcTatvNdlcOK5ZrrfqgCveGiWQ3eclYherzFuGMGjQTd5BSTFurwPwStn87lht2nuzqeVP4-_cWI-Xa.xrMifhp6fvIl_yecUd5Wvg \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..588a64a --- /dev/null +++ b/Dockerfile @@ -0,0 +1,36 @@ +# This Dockerfile might not follow best practices, but that is an intentional +# choice to have this Dockerfile use the install scripts that users use in the tutorial. + +FROM docker.io/alpine:latest + +# Install system dependencies +RUN apk update && apk add --no-cache bash curl jq git make sed ranger vim + +# Set the working directory +WORKDIR /app + +# Make sure GOPATH is set +ENV GOPATH /usr/local/go +ENV PATH $GOPATH/bin:$PATH + +# Install Rollkit dependencies +RUN curl -sSL https://rollkit.dev/install.sh | sh -s v0.13.5 + +# Install Artela rollup +RUN mkdir -p /app/artela-rollkit +COPY . /app/artela-rollkit + +# Update the working directory +WORKDIR /app/artela-rollkit + +# Initialize the Rollkit configuration +RUN rollkit toml init + +# Edit rollkit.toml config_dir +RUN sed -i 's/config_dir = "artela"/config_dir = "\.\/\.artela"/g' rollkit.toml + +# Run base rollkit command to download packages +RUN rollkit + +# Keep the container running +CMD tail -F /dev/null diff --git a/app/ante/evm/context_checker.go b/app/ante/evm/context_checker.go index 661f1a6..8b03e3a 100644 --- a/app/ante/evm/context_checker.go +++ b/app/ante/evm/context_checker.go @@ -156,9 +156,9 @@ func (vbd EthValidateBasicDecorator) AnteHandle(ctx cosmos.Context, tx cosmos.Tx } // Validate `From` field - if msgEthTx.From != "" { - return ctx, errorsmod.Wrapf(errortypes.ErrInvalidRequest, "invalid From %s, expect empty string", msgEthTx.From) - } + //if msgEthTx.From != "" { + // return ctx, errorsmod.Wrapf(errortypes.ErrInvalidRequest, "invalid From %s, expect empty string", msgEthTx.From) + //} txGasLimit += msgEthTx.GetGas() diff --git a/app/ante/evm/sig_checker.go b/app/ante/evm/sig_checker.go index 8ea2c68..4d0a03c 100644 --- a/app/ante/evm/sig_checker.go +++ b/app/ante/evm/sig_checker.go @@ -1,10 +1,13 @@ package evm import ( + "errors" + errorsmod "cosmossdk.io/errors" "github.com/cosmos/cosmos-sdk/baseapp" cosmos "github.com/cosmos/cosmos-sdk/types" errortypes "github.com/cosmos/cosmos-sdk/types/errors" + "github.com/ethereum/go-ethereum/common" "github.com/artela-network/artela-rollkit/app/interfaces" "github.com/artela-network/artela-rollkit/x/evm/types" @@ -43,6 +46,9 @@ func (esvd EthSigVerificationDecorator) AnteHandle(ctx cosmos.Context, tx cosmos } // set up the sender to the transaction field if not already + if sender != common.Address(cosmos.MustAccAddressFromBech32(msgEthTx.From)) { + return ctx, errors.New("sender address does not match the one defined on the message") + } msgEthTx.From = sender.Hex() } diff --git a/app/app.go b/app/app.go index 5d55576..a139192 100644 --- a/app/app.go +++ b/app/app.go @@ -1,6 +1,7 @@ package app import ( + "context" "io" "os" "path/filepath" @@ -19,6 +20,7 @@ import ( _ "cosmossdk.io/x/nft/module" // import for side-effects _ "cosmossdk.io/x/upgrade" // import for side-effects upgradekeeper "cosmossdk.io/x/upgrade/keeper" + aspecttypes "github.com/artela-network/aspect-core/types" dbm "github.com/cosmos/cosmos-db" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" @@ -79,6 +81,7 @@ import ( "github.com/artela-network/artela-rollkit/app/ante" "github.com/artela-network/artela-rollkit/app/ante/evm" "github.com/artela-network/artela-rollkit/app/post" + "github.com/artela-network/artela-rollkit/common" srvflags "github.com/artela-network/artela-rollkit/ethereum/server/flags" artela "github.com/artela-network/artela-rollkit/ethereum/types" evmmodulekeeper "github.com/artela-network/artela-rollkit/x/evm/keeper" @@ -155,7 +158,7 @@ type App struct { ScopedICAControllerKeeper capabilitykeeper.ScopedKeeper ScopedICAHostKeeper capabilitykeeper.ScopedKeeper - EvmKeeper evmmodulekeeper.Keeper + EvmKeeper *evmmodulekeeper.Keeper FeeKeeper feemodulekeeper.Keeper // this line is used by starport scaffolding # stargate/app/keeperDeclaration @@ -310,8 +313,8 @@ func New( &app.NFTKeeper, &app.GroupKeeper, &app.CircuitBreakerKeeper, - &app.EvmKeeper, &app.FeeKeeper, + &app.EvmKeeper, // this line is used by starport scaffolding # stargate/app/keeperDefinition ); err != nil { panic(err) @@ -319,6 +322,9 @@ func New( app.App = appBuilder.Build(db, traceStore, baseAppOptions...) + // register extra types + RegisterInterfaces(app.interfaceRegistry) + // Register legacy modules if err := app.registerIBCModules(appOpts); err != nil { return nil, err @@ -353,6 +359,10 @@ func New( app.setAnteHandler(app.txConfig, maxGasWanted) app.setPostHandler() + // init aspect pool + // set the runner cache capacity of aspect-runtime + aspecttypes.InitRuntimePool(context.Background(), common.WrapLogger(app.Logger()), cast.ToInt32(appOpts.Get(srvflags.ApplyPoolSize)), cast.ToInt32(appOpts.Get(srvflags.QueryPoolSize))) + if err := app.Load(loadLatest); err != nil { return nil, err } @@ -439,6 +449,8 @@ func (app *App) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig // register app's OpenAPI routes. docs.RegisterOpenAPIService(Name, apiSvr.Router) + + app.EvmKeeper.SetClientContext(apiSvr.ClientCtx) } func (app *App) setAnteHandler(txConfig client.TxConfig, maxGasWanted uint64) { @@ -447,7 +459,7 @@ func (app *App) setAnteHandler(txConfig client.TxConfig, maxGasWanted uint64) { AccountKeeper: app.AccountKeeper, BankKeeper: app.BankKeeper, ExtensionOptionChecker: artela.HasDynamicFeeExtensionOption, - EvmKeeper: &app.EvmKeeper, + EvmKeeper: app.EvmKeeper, FeegrantKeeper: app.FeeGrantKeeper, DistributionKeeper: app.DistrKeeper, FeeKeeper: app.FeeKeeper, @@ -468,7 +480,7 @@ func (app *App) setAnteHandler(txConfig client.TxConfig, maxGasWanted uint64) { func (app *App) setPostHandler() { options := post.PostDecorators{ - EvmKeeper: &app.EvmKeeper, + EvmKeeper: app.EvmKeeper, } if err := options.Validate(); err != nil { diff --git a/cmd/artelad/cmd/commands.go b/cmd/artrolld/cmd/commands.go similarity index 100% rename from cmd/artelad/cmd/commands.go rename to cmd/artrolld/cmd/commands.go diff --git a/cmd/artelad/cmd/config.go b/cmd/artrolld/cmd/config.go similarity index 100% rename from cmd/artelad/cmd/config.go rename to cmd/artrolld/cmd/config.go diff --git a/cmd/artelad/cmd/genaccounts.go b/cmd/artrolld/cmd/genaccounts.go similarity index 100% rename from cmd/artelad/cmd/genaccounts.go rename to cmd/artrolld/cmd/genaccounts.go diff --git a/cmd/artelad/cmd/gencontract.go b/cmd/artrolld/cmd/gencontract.go similarity index 100% rename from cmd/artelad/cmd/gencontract.go rename to cmd/artrolld/cmd/gencontract.go diff --git a/cmd/artelad/cmd/keyinfo.go b/cmd/artrolld/cmd/keyinfo.go similarity index 100% rename from cmd/artelad/cmd/keyinfo.go rename to cmd/artrolld/cmd/keyinfo.go diff --git a/cmd/artelad/cmd/root.go b/cmd/artrolld/cmd/root.go similarity index 100% rename from cmd/artelad/cmd/root.go rename to cmd/artrolld/cmd/root.go diff --git a/cmd/artelad/main.go b/cmd/artrolld/main.go similarity index 83% rename from cmd/artelad/main.go rename to cmd/artrolld/main.go index 4580546..0636d4f 100644 --- a/cmd/artelad/main.go +++ b/cmd/artrolld/main.go @@ -7,7 +7,7 @@ import ( svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" "github.com/artela-network/artela-rollkit/app" - "github.com/artela-network/artela-rollkit/cmd/artelad/cmd" + "github.com/artela-network/artela-rollkit/cmd/artrolld/cmd" ) func main() { diff --git a/compose.yaml b/compose.yaml new file mode 100644 index 0000000..350ac53 --- /dev/null +++ b/compose.yaml @@ -0,0 +1,28 @@ +# Docker Compose is used for spinning up the local-da docker container along with the GM container. + +version: "3" +services: + artroll: + container_name: artroll + # The build config can be used for debugging and testing changes to the GM Dockerfile + build: . + + # The image config can be used for running against published GM images + # image: ghcr.io/rollkit/gm:19b894c + + # Used for targetting localhost as if you were outside the container + network_mode: host + + platform: linux/amd64 + + # The command config is used for launching the GM rollup once the Docker container is running + # command: rollkit start --rollkit.aggregator --rollkit.da_address http://localhost:7980 + depends_on: + - local-da + + local-da: + image: ghcr.io/rollkit/local-da:v0.2.1 + container_name: local-da + platform: linux/amd64 + ports: + - "7980:7980" diff --git a/ethereum/rpc/tx.go b/ethereum/rpc/tx.go index 6dab1cb..ac85255 100644 --- a/ethereum/rpc/tx.go +++ b/ethereum/rpc/tx.go @@ -41,6 +41,12 @@ func (b *BackendImpl) SendTx(ctx context.Context, signedTx *ethtypes.Transaction return err } + from, err := b.GetSender(ethereumTx, b.chainID) + if err != nil { + return err + } + ethereumTx.From = sdktypes.AccAddress(from.Bytes()).String() + // Query params to use the EVM denomination res, err := b.queryClient.QueryClient.Params(b.ctx, &evmtypes.QueryParamsRequest{}) if err != nil { diff --git a/ethereum/rpc/types/utils.go b/ethereum/rpc/types/utils.go index 45468dc..ab295ef 100644 --- a/ethereum/rpc/types/utils.go +++ b/ethereum/rpc/types/utils.go @@ -242,7 +242,7 @@ func CheckTxFee(gasPrice *big.Int, gas uint64, cap float64) error { return nil } totalfee := new(big.Float).SetInt(new(big.Int).Mul(gasPrice, new(big.Int).SetUint64(gas))) - // 1 art in 10^18 uart + // 1 art in 10^18 aart oneToken := new(big.Float).SetInt(big.NewInt(params.Ether)) // quo = rounded(x/y) feeEth := new(big.Float).Quo(totalfee, oneToken) diff --git a/ethereum/types/coin.go b/ethereum/types/coin.go index 13a7bd3..a3c49e2 100644 --- a/ethereum/types/coin.go +++ b/ethereum/types/coin.go @@ -18,7 +18,7 @@ const ( AttoArtela string = "aart" // BaseDenomUnit defines the base denomination unit for Artela. - // 1 art = 1x10^{BaseDenomUnit} uart + // 1 art = 1x10^{BaseDenomUnit} aart BaseDenomUnit = 18 // DefaultGasPrice is default gas price for evm transactions @@ -28,19 +28,19 @@ const ( // PowerReduction defines the default power reduction value for staking var PowerReduction = sdkmath.NewIntFromBigInt(new(big.Int).Exp(big.NewInt(10), big.NewInt(BaseDenomUnit), nil)) -// NewArtelaCoin is a utility function that returns an "uart" coin with the given sdkmath.Int amount. +// NewArtelaCoin is a utility function that returns an "aart" coin with the given sdkmath.Int amount. // The function will panic if the provided amount is negative. func NewArtelaCoin(amount sdkmath.Int) sdk.Coin { return sdk.NewCoin(AttoArtela, amount) } -// NewArtelaDecCoin is a utility function that returns an "uart" decimal coin with the given sdkmath.Int amount. +// NewArtelaDecCoin is a utility function that returns an "aart" decimal coin with the given sdkmath.Int amount. // The function will panic if the provided amount is negative. func NewArtelaDecCoin(amount sdkmath.Int) sdk.DecCoin { return sdk.NewDecCoin(AttoArtela, amount) } -// NewArtelaCoinInt64 is a utility function that returns an "uart" coin with the given int64 amount. +// NewArtelaCoinInt64 is a utility function that returns an "aart" coin with the given int64 amount. // The function will panic if the provided amount is negative. func NewArtelaCoinInt64(amount int64) sdk.Coin { return sdk.NewInt64Coin(AttoArtela, amount) diff --git a/ethereum/utils/utils.go b/ethereum/utils/utils.go index eb10b67..5392a93 100644 --- a/ethereum/utils/utils.go +++ b/ethereum/utils/utils.go @@ -30,7 +30,7 @@ const ( LocalChainID = "artela_11820" // BaseDenom defines the Artela mainnet denomination - BaseDenom = "uart" + BaseDenom = "aart" ) // IsMainnet returns true if the chain-id has the Artela mainnet EIP155 chain prefix. diff --git a/init.sh b/init.sh index e4c0180..6cf61d3 100755 --- a/init.sh +++ b/init.sh @@ -57,6 +57,7 @@ cat $HOME/.artroll/config/genesis.json | jq '.app_state["staking"]["params"]["bo cat $HOME/.artroll/config/genesis.json | jq '.app_state["crisis"]["constant_fee"]["denom"]="aart"' >$HOME/.artroll/config/tmp_genesis.json && mv $HOME/.artroll/config/tmp_genesis.json $HOME/.artroll/config/genesis.json cat $HOME/.artroll/config/genesis.json | jq '.app_state["gov"]["deposit_params"]["min_deposit"][0]["denom"]="aart"' >$HOME/.artroll/config/tmp_genesis.json && mv $HOME/.artroll/config/tmp_genesis.json $HOME/.artroll/config/genesis.json cat $HOME/.artroll/config/genesis.json | jq '.app_state["gov"]["params"]["min_deposit"][0]["denom"]="aart"' >$HOME/.artroll/config/tmp_genesis.json && mv $HOME/.artroll/config/tmp_genesis.json $HOME/.artroll/config/genesis.json +cat $HOME/.artroll/config/genesis.json | jq '.app_state["gov"]["params"]["expedited_min_deposit"][0]["denom"]="aart"' >$HOME/.artroll/config/tmp_genesis.json && mv $HOME/.artroll/config/tmp_genesis.json $HOME/.artroll/config/genesis.json cat $HOME/.artroll/config/genesis.json | jq '.app_state["mint"]["params"]["mint_denom"]="aart"' >$HOME/.artroll/config/tmp_genesis.json && mv $HOME/.artroll/config/tmp_genesis.json $HOME/.artroll/config/genesis.json # Set gas limit in genesis @@ -77,7 +78,7 @@ artela-rollkitd add-genesis-account $KEY4 100000000000000000000000000aart --keyr # Sign genesis transaction echo gentx $KEY 1000000000000000000000aart --keyring-backend $KEYRING --chain-id $CHAINID -artela-rollkitd gentx $KEY 1000000000000000000000aart --keyring-backend $KEYRING --chain-id $CHAINID +artela-rollkitd gentx $KEY 1000000000000000000000aart --keyring-backend $KEYRING --chain-id $CHAINID --fees 4000000000000000aart # Collect genesis tx artela-rollkitd collect-gentxs diff --git a/kurtosis.yml b/kurtosis.yml new file mode 100644 index 0000000..f4dea4e --- /dev/null +++ b/kurtosis.yml @@ -0,0 +1,4 @@ +dname: github.com/artela-network/artela-rollkit +description: |- + Rollkit Artela-rollkit tutorial Kurtosis package +replace: {} diff --git a/main.star b/main.star new file mode 100644 index 0000000..4fa2ad5 --- /dev/null +++ b/main.star @@ -0,0 +1,62 @@ +# This Kurtosis package spins up a minimal GM rollup that connects to a DA node +# +# NOTE: currently this is only connecting to a local DA node + +da_node = import_module("github.com/rollkit/local-da/main.star@v0.3.0") + +def run(plan): + ########## + # DA + ########## + + da_address = da_node.run( + plan, + ) + plan.print("connecting to da layer via {0}".format(da_address)) + + ##### + # Artela-rollkit + ##### + + plan.print("Adding Artela-rollkit service") + plan.print("NOTE: This can take a few minutes to start up...") + artroll_start_cmd = [ + "rollkit", + "start", + "--rollkit.aggregator", + "--rollkit.da_address {0}".format(da_address), + ] + artroll_port_number = 26657 + artroll_port_spec = PortSpec( + number=artroll_port_number, transport_protocol="TCP", application_protocol="http" + ) + artroll_frontend_port_spec = PortSpec( + number=1317, transport_protocol="TCP", application_protocol="http" + ) + artroll_ports = { + "jsonrpc": artroll_port_spec, + "frontend": artroll_frontend_port_spec, + } + artroll = plan.add_service( + name="artroll", + config=ServiceConfig( + # Using rollkit version v0.13.5 + image="ghcr.io/rollkit/gm:05bd40e", + cmd=["/bin/sh", "-c", " ".join(gm_start_cmd)], + ports=gm_ports, + public_ports=gm_ports, + ready_conditions=ReadyCondition( + recipe=ExecRecipe( + command=["rollkit", "status"], + extract={ + "output": "fromjson | .node_info.network", + }, + ), + field="extract.output", + assertion="==", + target_value="gm", + interval="1s", + timeout="1m", + ), + ), + ) diff --git a/readme.md b/readme.md index 2697664..98461cc 100644 --- a/readme.md +++ b/readme.md @@ -1,5 +1,5 @@ -# artela -**artela** is a blockchain built using Cosmos SDK and Tendermint and created with [Ignite CLI](https://ignite.com/cli). +# artela-rollkit +**artela-rollkit** is a rollup kit built using Celestia's rollkit and created with [Ignite CLI](https://ignite.com/cli). ## Get started diff --git a/x/evm/keeper/config.go b/x/evm/keeper/config.go index 8010a94..f1afc72 100644 --- a/x/evm/keeper/config.go +++ b/x/evm/keeper/config.go @@ -39,7 +39,7 @@ func (k *Keeper) EVMConfig(ctx cosmos.Context, proposerAddress cosmos.ConsAddres } func (k *Keeper) EVMConfigFromCtx(ctx cosmos.Context) (*states.EVMConfig, error) { - return k.EVMConfig(ctx, ctx.BlockHeader().ProposerAddress, k.eip155ChainID) + return k.EVMConfig(ctx, ctx.BlockHeader().ProposerAddress, k.ChainID()) } // VMConfig creates an EVM configuration from the debug setting and the extra EIPs enabled on the diff --git a/x/evm/keeper/evm.go b/x/evm/keeper/evm.go index 5237bb6..89fe74f 100644 --- a/x/evm/keeper/evm.go +++ b/x/evm/keeper/evm.go @@ -140,7 +140,7 @@ func (k *Keeper) ApplyTransaction(ctx cosmos.Context, tx *ethereum.Transaction) ) // build evm config and txs config - evmConfig, err := k.EVMConfig(ctx, ctx.BlockHeader().ProposerAddress, k.eip155ChainID) + evmConfig, err := k.EVMConfig(ctx, ctx.BlockHeader().ProposerAddress, k.ChainID()) if err != nil { return nil, errorsmod.Wrap(err, "failed to load evm config") } @@ -257,7 +257,7 @@ func (k *Keeper) ApplyTransaction(ctx cosmos.Context, tx *ethereum.Transaction) // ApplyMessage calls ApplyMessageWithConfig with an empty TxConfig. func (k *Keeper) ApplyMessage(ctx cosmos.Context, msg *core.Message, tracer vm.EVMLogger, commit bool) (*types.MsgEthereumTxResponse, error) { - evmConfig, err := k.EVMConfig(ctx, ctx.BlockHeader().ProposerAddress, k.eip155ChainID) + evmConfig, err := k.EVMConfig(ctx, ctx.BlockHeader().ProposerAddress, k.ChainID()) if err != nil { return nil, errorsmod.Wrap(err, "failed to load evm config") } diff --git a/x/evm/keeper/msg_server.go b/x/evm/keeper/msg_server.go index 5f09cc0..6e232d9 100644 --- a/x/evm/keeper/msg_server.go +++ b/x/evm/keeper/msg_server.go @@ -18,12 +18,12 @@ import ( ) type msgServer struct { - Keeper + *Keeper } // NewMsgServerImpl returns an implementation of the MsgServer interface // for the provided Keeper. -func NewMsgServerImpl(keeper Keeper) types.MsgServer { +func NewMsgServerImpl(keeper *Keeper) types.MsgServer { return &msgServer{Keeper: keeper} } diff --git a/x/evm/keeper/proposer.go b/x/evm/keeper/proposer.go index 810484b..e032164 100644 --- a/x/evm/keeper/proposer.go +++ b/x/evm/keeper/proposer.go @@ -18,7 +18,11 @@ func (k Keeper) GetProposerAddress(ctx cosmos.Context, proposerAddress cosmos.Co ) } - return common.BytesToAddress(cosmos.MustAccAddressFromBech32(validator.GetOperator())), nil + valAddress, err := cosmos.ValAddressFromBech32(validator.GetOperator()) + if err != nil { + return common.Address{}, err + } + return common.BytesToAddress(valAddress), nil } // GetProposerAddress returns current block proposer's address when provided proposer address is empty. diff --git a/x/evm/keeper/query.go b/x/evm/keeper/query.go index bf33039..bac11f1 100644 --- a/x/evm/keeper/query.go +++ b/x/evm/keeper/query.go @@ -620,7 +620,7 @@ func (k Keeper) BaseFee(c context.Context, _ *types.QueryBaseFeeRequest) (*types ctx := cosmos.UnwrapSDKContext(c) params := k.GetParams(ctx) - ethCfg := params.ChainConfig.EthereumConfig(ctx.BlockHeight(), k.eip155ChainID) + ethCfg := params.ChainConfig.EthereumConfig(ctx.BlockHeight(), k.ChainID()) baseFee := k.GetBaseFee(ctx, ethCfg) res := &types.QueryBaseFeeResponse{} diff --git a/x/evm/module/module.go b/x/evm/module/module.go index 9b198bb..504b81c 100644 --- a/x/evm/module/module.go +++ b/x/evm/module/module.go @@ -94,14 +94,14 @@ func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *r type AppModule struct { AppModuleBasic - keeper keeper.Keeper + keeper *keeper.Keeper accountKeeper types.AccountKeeper bankKeeper types.BankKeeper } func NewAppModule( cdc codec.Codec, - keeper keeper.Keeper, + keeper *keeper.Keeper, accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, ) AppModule { @@ -128,12 +128,12 @@ func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, gs json.Ra // Initialize global index to index in genesis state cdc.MustUnmarshalJSON(gs, &genState) - InitGenesis(ctx, am.keeper, am.accountKeeper, genState) + InitGenesis(ctx, *am.keeper, am.accountKeeper, genState) } // ExportGenesis returns the module's exported genesis state as raw JSON bytes. func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { - genState := ExportGenesis(ctx, am.keeper, am.accountKeeper) + genState := ExportGenesis(ctx, *am.keeper, am.accountKeeper) return cdc.MustMarshalJSON(genState) } @@ -146,7 +146,7 @@ func (AppModule) ConsensusVersion() uint64 { return 1 } // The begin block implementation is optional. func (am AppModule) BeginBlock(ctx context.Context) error { sdkCtx := sdk.UnwrapSDKContext(ctx) - BeginBlock(sdkCtx, &am.keeper) + BeginBlock(sdkCtx, am.keeper) return nil } @@ -154,7 +154,7 @@ func (am AppModule) BeginBlock(ctx context.Context) error { // The end block implementation is optional. func (am AppModule) EndBlock(ctx context.Context) error { sdkCtx := sdk.UnwrapSDKContext(ctx) - return EndBlock(sdkCtx, &am.keeper) + return EndBlock(sdkCtx, am.keeper) } // IsOnePerModuleType implements the depinject.OnePerModuleType interface. @@ -195,7 +195,7 @@ type ModuleInputs struct { type ModuleOutputs struct { depinject.Out - EvmKeeper keeper.Keeper + EvmKeeper *keeper.Keeper Module appmodule.AppModule } @@ -220,10 +220,10 @@ func ProvideModule(in ModuleInputs) ModuleOutputs { ) m := NewAppModule( in.Cdc, - k, + &k, in.AccountKeeper, in.BankKeeper, ) - return ModuleOutputs{EvmKeeper: k, Module: m} + return ModuleOutputs{EvmKeeper: &k, Module: m} } diff --git a/x/evm/types/tx_wrapper.go b/x/evm/types/tx_wrapper.go index 4a856f1..d603898 100644 --- a/x/evm/types/tx_wrapper.go +++ b/x/evm/types/tx_wrapper.go @@ -23,7 +23,6 @@ import ( "google.golang.org/protobuf/proto" "google.golang.org/protobuf/protoadapt" - artela "github.com/artela-network/artela-rollkit/ethereum/types" "github.com/artela-network/artela-rollkit/ethereum/utils" ) @@ -151,7 +150,7 @@ func (msg *MsgEthereumTx) BuildTx(b client.TxBuilder, evmDenom string) (signing. builder.SetExtensionOptions(option) // A valid msg should have empty `From` - msg.From = "" + //msg.From = "" err = builder.SetMsgs(msg) if err != nil { @@ -172,16 +171,11 @@ func (msg MsgEthereumTx) Type() string { return TypeMsgEthereumTx } // ValidateBasic implements the cosmos.Msg interface. It performs basic validation // checks of a Transaction. If returns an error if validation fails. func (msg MsgEthereumTx) ValidateBasic() error { - if msg.From != "" { - if err := artela.ValidateAddress(msg.From); err != nil { - return errorsmod.Wrap(err, "invalid from address") - } - } - - // Validate Size_ field, should be kept empty - if msg.Size() != 0 { - return errorsmod.Wrapf(errortypes.ErrInvalidRequest, "txs size is deprecated") - } + //if msg.From != "" { + // if err := artela.ValidateAddress(msg.From); err != nil { + // return errorsmod.Wrap(err, "invalid from address") + // } + //} txData, err := UnpackTxData(msg.Data) if err != nil {