diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS deleted file mode 100644 index 74263b766da2..000000000000 --- a/.github/CODEOWNERS +++ /dev/null @@ -1,47 +0,0 @@ -* @gakonst -bin/ @onbjerg -crates/blockchain-tree/ @rakita @rkrasiuk @mattsse @Rjected -crates/blockchain-tree-api/ @rakita @rkrasiuk @mattsse @Rjected -crates/chainspec/ @Rjected @joshieDo @mattsse -crates/chain-state/ @fgimenez @mattsse @rkrasiuk -crates/cli/ @onbjerg @mattsse -crates/config/ @onbjerg -crates/consensus/ @rkrasiuk @mattsse @Rjected -crates/engine @rkrasiuk @mattsse @Rjected -crates/e2e-test-utils/ @mattsse @Rjected -crates/engine/ @rkrasiuk @mattsse @Rjected @fgimenez -crates/errors/ @mattsse -crates/ethereum/ @mattsse @Rjected -crates/ethereum-forks/ @mattsse @Rjected -crates/etl/ @joshieDo @shekhirin -crates/evm/ @rakita @mattsse @Rjected -crates/exex/ @onbjerg @shekhirin -crates/fs-util/ @onbjerg @emhane -crates/metrics/ @onbjerg -crates/net/ @emhane @mattsse @Rjected -crates/net/downloaders/ @onbjerg @rkrasiuk @emhane -crates/node/ @mattsse @Rjected @onbjerg -crates/optimism/ @mattsse @Rjected @fgimenez -crates/payload/ @mattsse @Rjected -crates/primitives/ @Rjected -crates/primitives-traits/ @Rjected @joshieDo -crates/prune/ @shekhirin @joshieDo -crates/revm/ @mattsse @rakita -crates/rpc/ @mattsse @Rjected @emhane -crates/stages/ @onbjerg @rkrasiuk @shekhirin -crates/static-file/ @joshieDo @shekhirin -crates/storage/codecs/ @joshieDo -crates/storage/db/ @joshieDo @rakita -crates/storage/db-api/ @joshieDo @rakita -crates/storage/db-common/ @Rjected @onbjerg -crates/storage/errors/ @rakita @onbjerg -crates/storage/libmdbx-rs/ @rakita @shekhirin -crates/storage/nippy-jar/ @joshieDo @shekhirin -crates/storage/provider/ @rakita @joshieDo @shekhirin -crates/storage/storage-api/ @joshieDo @rkrasiuk -crates/tasks/ @mattsse -crates/tokio-util/ @fgimenez @emhane -crates/tracing/ @onbjerg -crates/transaction-pool/ @mattsse -crates/trie/ @rkrasiuk @Rjected -.github/ @onbjerg @gakonst @DaniPopes diff --git a/.github/ISSUE_TEMPLATE/bug.yml b/.github/ISSUE_TEMPLATE/bug.yml deleted file mode 100644 index 1142a5bf251c..000000000000 --- a/.github/ISSUE_TEMPLATE/bug.yml +++ /dev/null @@ -1,115 +0,0 @@ -name: Bug Report -description: Create a bug report -labels: ["C-bug", "S-needs-triage"] -body: - - type: markdown - attributes: - value: | - Thanks for taking the time to fill out this bug report! Please provide as much detail as possible. - - If you believe you have found a vulnerability, please provide details [here](mailto:georgios@paradigm.xyz) instead. - - type: textarea - id: what-happened - attributes: - label: Describe the bug - description: | - A clear and concise description of what the bug is. - - If the bug is in a crate you are using (i.e. you are not running the standard `reth` binary) please mention that as well. - validations: - required: true - - type: textarea - id: reproduction-steps - attributes: - label: Steps to reproduce - description: Please provide any steps you think might be relevant to reproduce the bug. - placeholder: | - Steps to reproduce: - - 1. Start '...' - 2. Then '...' - 3. Check '...' - 4. See error - validations: - required: true - - type: textarea - id: logs - attributes: - label: Node logs - description: | - If applicable, please provide the node logs leading up to the bug. - - **Please also provide debug logs.** By default, these can be found in: - - - `~/.cache/reth/logs` on Linux - - `~/Library/Caches/reth/logs` on macOS - - `%localAppData%/reth/logs` on Windows - render: text - validations: - required: false - - type: dropdown - id: platform - attributes: - label: Platform(s) - description: What platform(s) did this occur on? - multiple: true - options: - - Linux (x86) - - Linux (ARM) - - Mac (Intel) - - Mac (Apple Silicon) - - Windows (x86) - - Windows (ARM) - validations: - required: true - - type: textarea - id: client-version - attributes: - label: What version/commit are you on? - description: This can be obtained with `reth --version` - validations: - required: true - - type: textarea - id: database-version - attributes: - label: What database version are you on? - description: This can be obtained with `reth db version` - validations: - required: true - - type: textarea - id: network - attributes: - label: Which chain / network are you on? - description: This is the argument you pass to `reth --chain`. If you are using `--dev`, type in 'dev' here. If you are not running with `--chain` or `--dev` then it is mainnet. - validations: - required: true - - type: dropdown - id: node-type - attributes: - label: What type of node are you running? - options: - - Archive (default) - - Full via --full flag - - Pruned with custom reth.toml config - validations: - required: true - - type: textarea - id: prune-config - attributes: - label: What prune config do you use, if any? - description: The `[prune]` section in `reth.toml` file - validations: - required: false - - type: input - attributes: - label: If you've built Reth from source, provide the full command you used - validations: - required: false - - type: checkboxes - id: terms - attributes: - label: Code of Conduct - description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/paradigmxyz/reth/blob/main/CONTRIBUTING.md#code-of-conduct) - options: - - label: I agree to follow the Code of Conduct - required: true diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml deleted file mode 100644 index cfefdb13a695..000000000000 --- a/.github/ISSUE_TEMPLATE/config.yml +++ /dev/null @@ -1,5 +0,0 @@ -blank_issues_enabled: false -contact_links: - - name: GitHub Discussions - url: https://github.com/paradigmxyz/reth/discussions - about: Please ask and answer questions here to keep the issue tracker clean. diff --git a/.github/ISSUE_TEMPLATE/docs.yml b/.github/ISSUE_TEMPLATE/docs.yml deleted file mode 100644 index c1c1c2d51b43..000000000000 --- a/.github/ISSUE_TEMPLATE/docs.yml +++ /dev/null @@ -1,19 +0,0 @@ -name: Documentation -description: Suggest a change to our documentation -labels: ["C-docs", "S-needs-triage"] -body: - - type: markdown - attributes: - value: | - If you are unsure if the docs are relevant or needed, please open up a discussion first. - - type: textarea - attributes: - label: Describe the change - description: | - Please describe the documentation you want to change or add, and if it is for end-users or contributors. - validations: - required: true - - type: textarea - attributes: - label: Additional context - description: Add any other context to the feature (like screenshots, resources) diff --git a/.github/ISSUE_TEMPLATE/feature.yml b/.github/ISSUE_TEMPLATE/feature.yml deleted file mode 100644 index 005c33ae3faa..000000000000 --- a/.github/ISSUE_TEMPLATE/feature.yml +++ /dev/null @@ -1,21 +0,0 @@ -name: Feature request -description: Suggest a feature -labels: ["C-enhancement", "S-needs-triage"] -body: - - type: markdown - attributes: - value: | - Please ensure that the feature has not already been requested in the issue tracker. - - type: textarea - attributes: - label: Describe the feature - description: | - Please describe the feature and what it is aiming to solve, if relevant. - - If the feature is for a crate, please include a proposed API surface. - validations: - required: true - - type: textarea - attributes: - label: Additional context - description: Add any other context to the feature (like screenshots, resources) diff --git a/.github/assets/check_wasm.sh b/.github/assets/check_wasm.sh deleted file mode 100755 index 7cd93f6ac5c4..000000000000 --- a/.github/assets/check_wasm.sh +++ /dev/null @@ -1,65 +0,0 @@ -#!/usr/bin/env bash -set +e # Disable immediate exit on error - -# Array of crates -wasm_crates=( - # The following were confirmed not working in the past, but could be enabled if issues have been resolved - # reth-consensus - # reth-db - # reth-evm-ethereum - # The following are confirmed working - reth-codecs - reth-errors - reth-ethereum-forks - reth-evm - reth-network-peers - reth-primitives - reth-primitives-traits - reth-revm -) - -# Array to hold the results -results=() -# Flag to track if any command fails -any_failed=0 - -for crate in "${wasm_crates[@]}"; do - cmd="cargo +stable build -p $crate --target wasm32-wasip1 --no-default-features" - - if [ -n "$CI" ]; then - echo "::group::$cmd" - else - printf "\n%s:\n %s\n" "$crate" "$cmd" - fi - - # Run the command and capture the return code - $cmd - ret_code=$? - - # Store the result in the dictionary - if [ $ret_code -eq 0 ]; then - results+=("✅:$crate") - else - results+=("❌:$crate") - any_failed=1 - fi - - if [ -n "$CI" ]; then - echo "::endgroup::" - fi -done - -# Sort the results by status and then by crate name -IFS=$'\n' sorted_results=($(sort <<<"${results[*]}")) -unset IFS - -# Print summary -echo -e "\nSummary of build results:" -for result in "${sorted_results[@]}"; do - status="${result%%:*}" - crate="${result##*:}" - echo "$status $crate" -done - -# Exit with a non-zero status if any command fails -exit $any_failed diff --git a/.github/assets/hive/Dockerfile b/.github/assets/hive/Dockerfile deleted file mode 100644 index 9f75ba6f1cf2..000000000000 --- a/.github/assets/hive/Dockerfile +++ /dev/null @@ -1,8 +0,0 @@ -FROM ubuntu - -COPY dist/reth /usr/local/bin - -COPY LICENSE-* ./ - -EXPOSE 30303 30303/udp 9001 8545 8546 -ENTRYPOINT ["/usr/local/bin/reth"] \ No newline at end of file diff --git a/.github/assets/hive/build_simulators.sh b/.github/assets/hive/build_simulators.sh deleted file mode 100755 index 45583d549a37..000000000000 --- a/.github/assets/hive/build_simulators.sh +++ /dev/null @@ -1,38 +0,0 @@ -#!/usr/bin/env bash -set -eo pipefail - -# Create the hive_assets directory -mkdir hive_assets/ - -cd hivetests -go build . - -./hive -client reth # first builds and caches the client - -# Run each hive command in the background for each simulator and wait -echo "Building images" -./hive -client reth --sim "pyspec" -sim.timelimit 1s || true & -./hive -client reth --sim "ethereum/engine" -sim.timelimit 1s || true & -./hive -client reth --sim "devp2p" -sim.timelimit 1s || true & -./hive -client reth --sim "ethereum/rpc-compat" -sim.timelimit 1s || true & -./hive -client reth --sim "smoke/genesis" -sim.timelimit 1s || true & -./hive -client reth --sim "smoke/network" -sim.timelimit 1s || true & -./hive -client reth --sim "ethereum/sync" -sim.timelimit 1s || true & -wait - -# Run docker save in parallel and wait -echo "Saving images" -docker save hive/hiveproxy:latest -o ../hive_assets/hiveproxy.tar & -docker save hive/simulators/devp2p:latest -o ../hive_assets/devp2p.tar & -docker save hive/simulators/ethereum/engine:latest -o ../hive_assets/engine.tar & -docker save hive/simulators/ethereum/rpc-compat:latest -o ../hive_assets/rpc_compat.tar & -docker save hive/simulators/ethereum/pyspec:latest -o ../hive_assets/pyspec.tar & -docker save hive/simulators/smoke/genesis:latest -o ../hive_assets/smoke_genesis.tar & -docker save hive/simulators/smoke/network:latest -o ../hive_assets/smoke_network.tar & -docker save hive/simulators/ethereum/sync:latest -o ../hive_assets/ethereum_sync.tar & -wait - -# Make sure we don't rebuild images on the CI jobs -git apply ../.github/assets/hive/no_sim_build.diff -go build . -mv ./hive ../hive_assets/ \ No newline at end of file diff --git a/.github/assets/hive/expected_failures.yaml b/.github/assets/hive/expected_failures.yaml deleted file mode 100644 index 61ff69ecab6a..000000000000 --- a/.github/assets/hive/expected_failures.yaml +++ /dev/null @@ -1,120 +0,0 @@ -# https://github.com/paradigmxyz/reth/issues/7015 -# https://github.com/paradigmxyz/reth/issues/6332 -rpc-compat: - - debug_getRawBlock/get-invalid-number (reth) - - debug_getRawHeader/get-invalid-number (reth) - - debug_getRawReceipts/get-invalid-number (reth) - - debug_getRawTransaction/get-invalid-hash (reth) - - - eth_call/call-callenv (reth) - - eth_createAccessList/create-al-contract-eip1559 (reth) - - eth_createAccessList/create-al-contract (reth) - - eth_feeHistory/fee-history (reth) - - eth_getStorageAt/get-storage-invalid-key-too-large (reth) - - eth_getStorageAt/get-storage-invalid-key (reth) - - eth_getTransactionReceipt/get-access-list (reth) - - eth_getTransactionReceipt/get-blob-tx (reth) - - eth_getTransactionReceipt/get-dynamic-fee (reth) - -# https://github.com/paradigmxyz/reth/issues/8732 -engine-withdrawals: - - Withdrawals Fork On Genesis (Paris) (reth) - - Withdrawals Fork on Block 1 (Paris) (reth) - - Withdrawals Fork on Block 2 (Paris) (reth) - - Withdrawals Fork on Block 3 (Paris) (reth) - - Withdraw to a single account (Paris) (reth) - - Withdraw to two accounts (Paris) (reth) - - Withdraw many accounts (Paris) (reth) - - Withdraw zero amount (Paris) (reth) - - Empty Withdrawals (Paris) (reth) - - Corrupted Block Hash Payload (INVALID) (Paris) (reth) - - Withdrawals Fork on Block 1 - 8 Block Re-Org NewPayload (Paris) (reth) - - Withdrawals Fork on Block 1 - 8 Block Re-Org, Sync (Paris) (reth) - - Withdrawals Fork on Block 8 - 10 Block Re-Org NewPayload (Paris) (reth) - - Withdrawals Fork on Block 8 - 10 Block Re-Org Sync (Paris) (reth) - - Withdrawals Fork on Canonical Block 8 / Side Block 7 - 10 Block Re-Org (Paris) (reth) - - Withdrawals Fork on Canonical Block 8 / Side Block 7 - 10 Block Re-Org Sync (Paris) (reth) - - Withdrawals Fork on Canonical Block 8 / Side Block 9 - 10 Block Re-Org (Paris) (reth) - - Withdrawals Fork on Canonical Block 8 / Side Block 9 - 10 Block Re-Org Sync (Paris) (reth) - -# https://github.com/paradigmxyz/reth/issues/8305 -# https://github.com/paradigmxyz/reth/issues/6217 -engine-api: - - Inconsistent Head in ForkchoiceState (Paris) (reth) - - Invalid NewPayload, StateRoot, Syncing=True, EmptyTxs=True, DynFeeTxs=False (Paris) (reth) - - Invalid NewPayload, StateRoot, Syncing=True, EmptyTxs=False, DynFeeTxs=False (Paris) (reth) - - Invalid NewPayload, PrevRandao, Syncing=True, EmptyTxs=False, DynFeeTxs=False (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, StateRoot, EmptyTxs=True, CanonicalReOrg=False, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, StateRoot, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, StateRoot, EmptyTxs=True, CanonicalReOrg=True, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, StateRoot, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, GasLimit, EmptyTxs=False, CanonicalReOrg=False, Invalid P8 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Timestamp, EmptyTxs=False, CanonicalReOrg=False, Invalid P8 (Paris) (reth) - - # Hive issue - # https://github.com/ethereum/hive/issues/1135 - - Invalid Missing Ancestor Syncing ReOrg, Transaction Signature, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Signature, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Nonce, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Nonce, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Gas, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Gas, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction GasPrice, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction GasPrice, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Value, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Value, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, ReceiptsRoot, EmptyTxs=False, CanonicalReOrg=False, Invalid P8 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, ReceiptsRoot, EmptyTxs=False, CanonicalReOrg=True, Invalid P8 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, GasLimit, EmptyTxs=False, CanonicalReOrg=True, Invalid P8 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, GasUsed, EmptyTxs=False, CanonicalReOrg=False, Invalid P8 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, GasUsed, EmptyTxs=False, CanonicalReOrg=True, Invalid P8 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Timestamp, EmptyTxs=False, CanonicalReOrg=True, Invalid P8 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Incomplete Transactions, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Paris) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Incomplete Transactions, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Paris) (reth) - -# https://github.com/paradigmxyz/reth/issues/8305 -# https://github.com/paradigmxyz/reth/issues/6217 -# https://github.com/paradigmxyz/reth/issues/8306 -# https://github.com/paradigmxyz/reth/issues/7144 -engine-cancun: - - Blob Transaction Ordering, Multiple Clients (Cancun) (reth) - - Inconsistent Head in ForkchoiceState (Cancun) (reth) - - Invalid NewPayload, StateRoot, Syncing=True, EmptyTxs=True, DynFeeTxs=False (Cancun) (reth) - - Invalid NewPayload, StateRoot, Syncing=True, EmptyTxs=False, DynFeeTxs=False (Cancun) (reth) - - Invalid NewPayload, PrevRandao, Syncing=True, EmptyTxs=False, DynFeeTxs=False (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, StateRoot, EmptyTxs=True, CanonicalReOrg=False, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, StateRoot, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, StateRoot, EmptyTxs=True, CanonicalReOrg=True, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, StateRoot, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, GasLimit, EmptyTxs=False, CanonicalReOrg=False, Invalid P8 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Timestamp, EmptyTxs=False, CanonicalReOrg=False, Invalid P8 (Cancun) (reth) - - Invalid PayloadAttributes, Missing BeaconRoot, Syncing=True (Cancun) (reth) - - Invalid NewPayload, ParentBeaconBlockRoot, Syncing=True, EmptyTxs=False, DynFeeTxs=False (Cancun) (reth) - - Invalid NewPayload, BlobGasUsed, Syncing=True, EmptyTxs=False, DynFeeTxs=False (Cancun) (reth) - - Invalid NewPayload, Blob Count on BlobGasUsed, Syncing=True, EmptyTxs=False, DynFeeTxs=False (Cancun) (reth) - - Invalid NewPayload, ExcessBlobGas, Syncing=True, EmptyTxs=False, DynFeeTxs=False (Cancun) (reth) - - # Hive issue - # https://github.com/ethereum/hive/issues/1135 - - Invalid Missing Ancestor Syncing ReOrg, ReceiptsRoot, EmptyTxs=False, CanonicalReOrg=False, Invalid P8 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, ReceiptsRoot, EmptyTxs=False, CanonicalReOrg=True, Invalid P8 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, GasLimit, EmptyTxs=False, CanonicalReOrg=True, Invalid P8 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, GasUsed, EmptyTxs=False, CanonicalReOrg=False, Invalid P8 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, GasUsed, EmptyTxs=False, CanonicalReOrg=True, Invalid P8 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Timestamp, EmptyTxs=False, CanonicalReOrg=True, Invalid P8 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Incomplete Transactions, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Incomplete Transactions, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Signature, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Signature, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Nonce, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Nonce, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Gas, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Gas, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction GasPrice, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction GasPrice, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Value, EmptyTxs=False, CanonicalReOrg=False, Invalid P9 (Cancun) (reth) - - Invalid Missing Ancestor Syncing ReOrg, Transaction Value, EmptyTxs=False, CanonicalReOrg=True, Invalid P9 (Cancun) (reth) - -# https://github.com/paradigmxyz/reth/issues/8579 -sync: - - sync reth -> reth diff --git a/.github/assets/hive/load_images.sh b/.github/assets/hive/load_images.sh deleted file mode 100755 index 05e1cb9905fa..000000000000 --- a/.github/assets/hive/load_images.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env bash -set -eo pipefail - -# List of tar files to load -IMAGES=( - "/tmp/hiveproxy.tar" - "/tmp/devp2p.tar" - "/tmp/engine.tar" - "/tmp/rpc_compat.tar" - "/tmp/pyspec.tar" - "/tmp/smoke_genesis.tar" - "/tmp/smoke_network.tar" - "/tmp/ethereum_sync.tar" - "/tmp/reth_image.tar" -) - -# Loop through the images and load them -for IMAGE_TAR in "${IMAGES[@]}"; do - echo "Loading image $IMAGE_TAR..." - docker load -i "$IMAGE_TAR" & -done - -wait - -docker image ls -a \ No newline at end of file diff --git a/.github/assets/hive/no_sim_build.diff b/.github/assets/hive/no_sim_build.diff deleted file mode 100644 index 0b109efe7cd0..000000000000 --- a/.github/assets/hive/no_sim_build.diff +++ /dev/null @@ -1,53 +0,0 @@ -diff --git a/internal/libdocker/builder.go b/internal/libdocker/builder.go -index 4731c9d..d717f52 100644 ---- a/internal/libdocker/builder.go -+++ b/internal/libdocker/builder.go -@@ -7,9 +7,7 @@ import ( - "fmt" - "io" - "io/fs" -- "os" - "path/filepath" -- "strings" - - "github.com/ethereum/hive/internal/libhive" - docker "github.com/fsouza/go-dockerclient" -@@ -53,24 +51,8 @@ func (b *Builder) BuildClientImage(ctx context.Context, client libhive.ClientDes - - // BuildSimulatorImage builds a docker image of a simulator. - func (b *Builder) BuildSimulatorImage(ctx context.Context, name string) (string, error) { -- dir := b.config.Inventory.SimulatorDirectory(name) -- buildContextPath := dir -- buildDockerfile := "Dockerfile" -- // build context dir of simulator can be overridden with "hive_context.txt" file containing the desired build path -- if contextPathBytes, err := os.ReadFile(filepath.Join(filepath.FromSlash(dir), "hive_context.txt")); err == nil { -- buildContextPath = filepath.Join(dir, strings.TrimSpace(string(contextPathBytes))) -- if strings.HasPrefix(buildContextPath, "../") { -- return "", fmt.Errorf("cannot access build directory outside of Hive root: %q", buildContextPath) -- } -- if p, err := filepath.Rel(buildContextPath, filepath.Join(filepath.FromSlash(dir), "Dockerfile")); err != nil { -- return "", fmt.Errorf("failed to derive relative simulator Dockerfile path: %v", err) -- } else { -- buildDockerfile = p -- } -- } - tag := fmt.Sprintf("hive/simulators/%s:latest", name) -- err := b.buildImage(ctx, buildContextPath, buildDockerfile, tag, nil) -- return tag, err -+ return tag, nil - } - - // BuildImage creates a container by archiving the given file system, -diff --git a/internal/libdocker/proxy.go b/internal/libdocker/proxy.go -index a53e5af..0bb2ea9 100644 ---- a/internal/libdocker/proxy.go -+++ b/internal/libdocker/proxy.go -@@ -16,7 +16,7 @@ const hiveproxyTag = "hive/hiveproxy" - - // Build builds the hiveproxy image. - func (cb *ContainerBackend) Build(ctx context.Context, b libhive.Builder) error { -- return b.BuildImage(ctx, hiveproxyTag, hiveproxy.Source) -+ return nil - } - - // ServeAPI starts the API server. diff --git a/.github/assets/hive/parse.py b/.github/assets/hive/parse.py deleted file mode 100644 index ee75fdf55317..000000000000 --- a/.github/assets/hive/parse.py +++ /dev/null @@ -1,43 +0,0 @@ -import json -import yaml -import sys -import argparse - -# Argument parser setup -parser = argparse.ArgumentParser(description="Check for unexpected test results based on an exclusion list.") -parser.add_argument("report_json", help="Path to the hive report JSON file.") -parser.add_argument("--exclusion", required=True, help="Path to the exclusion YAML file.") -args = parser.parse_args() - -# Load hive JSON -with open(args.report_json, 'r') as file: - report = json.load(file) - -# Load exclusion YAML -with open(args.exclusion, 'r') as file: - exclusion_data = yaml.safe_load(file) - exclusions = exclusion_data.get(report['name'], []) - -# Collect unexpected failures and passes -unexpected_failures = [] -unexpected_passes = [] - -for test in report['testCases'].values(): - test_name = test['name'] - test_pass = test['summaryResult']['pass'] - if test_name in exclusions: - if test_pass: - unexpected_passes.append(test_name) - else: - if not test_pass: - unexpected_failures.append(test_name) - -# Check if there are any unexpected failures or passes and exit with error -if unexpected_failures or unexpected_passes: - if unexpected_failures: - print("Unexpected Failures:", unexpected_failures) - if unexpected_passes: - print("Unexpected Passes:", unexpected_passes) - sys.exit(1) - -print("Success.") \ No newline at end of file diff --git a/.github/assets/hive/run_simulator.sh b/.github/assets/hive/run_simulator.sh deleted file mode 100755 index 731c94c3f69b..000000000000 --- a/.github/assets/hive/run_simulator.sh +++ /dev/null @@ -1,38 +0,0 @@ -#!/usr/bin/env bash -# set -x - -cd hivetests/ - -sim="${1}" -limit="${2}" - -run_hive() { - hive --sim "${sim}" --sim.limit "${limit}" --sim.parallelism 4 --client reth 2>&1 | tee /tmp/log || true -} - -check_log() { - tail -n 1 /tmp/log | sed -r 's/\x1B\[[0-9;]*[mK]//g' -} - -attempt=0 -max_attempts=5 - -while [ $attempt -lt $max_attempts ]; do - run_hive - - # Check if no tests were run. sed removes ansi colors - if check_log | grep -q "suites=0"; then - echo "no tests were run, retrying in 10 seconds" - sleep 10 - attempt=$((attempt + 1)) - continue - fi - - # Check the last line of the log for "finished", "tests failed", or "test failed" - if check_log | grep -Eq "(finished|tests? failed)"; then - exit 0 - else - exit 1 - fi -done -exit 1 diff --git a/.github/assets/install_geth.sh b/.github/assets/install_geth.sh deleted file mode 100755 index 8469f5a73f8e..000000000000 --- a/.github/assets/install_geth.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env bash - -# Installs Geth (https://geth.ethereum.org) in $HOME/bin for x86_64 Linux. - -set -eo pipefail - -GETH_BUILD=${GETH_BUILD:-"1.13.4-3f907d6a"} - -name="geth-linux-amd64-$GETH_BUILD" - -mkdir -p "$HOME/bin" -wget "https://gethstore.blob.core.windows.net/builds/$name.tar.gz" -tar -xvf "$name.tar.gz" -rm "$name.tar.gz" -mv "$name/geth" "$HOME/bin/geth" -rm -rf "$name" -chmod +x "$HOME/bin/geth" - -# Add $HOME/bin to $PATH -[[ "$PATH" != *$HOME/bin* ]] && export PATH=$HOME/bin:$PATH -[ -n "$CI" ] && echo "$HOME/bin" >> "$GITHUB_PATH" - -geth version diff --git a/.github/assets/label_pr.js b/.github/assets/label_pr.js deleted file mode 100644 index 16ace2db0327..000000000000 --- a/.github/assets/label_pr.js +++ /dev/null @@ -1,57 +0,0 @@ -// Filter function for labels we do not want on PRs automatically. -function shouldIncludeLabel (label) { - const isStatus = label.startsWith('S-'); - const isTrackingIssue = label === 'C-tracking-issue'; - const isPreventStale = label === 'M-prevent-stale'; - const isDifficulty = label.startsWith('D-'); - - return !isStatus && !isTrackingIssue && !isPreventStale && !isDifficulty; -} - -// Get the issue number from an issue link in the forms ` ` or ` #`. -function getIssueLink (repoUrl, body) { - const urlPattern = new RegExp(`(close|closes|closed|fix|fixes|fixed|resolve|resolves|resolved) ${repoUrl}/issues/(?\\d+)`, 'i') - const issuePattern = new RegExp(`(close|closes|closed|fix|fixes|fixed|resolve|resolves|resolved) \#(?\\d+)`, 'i') - - const urlRe = body.match(urlPattern); - const issueRe = body.match(issuePattern); - if (urlRe?.groups?.issue_number) { - return urlRe.groups.issue_number - } else { - return issueRe?.groups?.issue_number - } -} - -module.exports = async ({ github, context }) => { - try { - const prNumber = context.payload.pull_request.number; - const prBody = context.payload.pull_request.body; - const repo = context.repo; - - const repoUrl = context.payload.repository.html_url; - const issueNumber = getIssueLink(repoUrl, prBody); - if (!issueNumber) { - console.log('No issue reference found in PR description.'); - return; - } - - const issue = await github.rest.issues.get({ - ...repo, - issue_number: issueNumber, - }); - - const issueLabels = issue.data.labels - .map(label => label.name) - .filter(shouldIncludeLabel); - if (issueLabels.length > 0) { - await github.rest.issues.addLabels({ - ...repo, - issue_number: prNumber, - labels: issueLabels, - }); - } - } catch (err) { - console.error('Failed to label PR'); - console.error(err); - } -} diff --git a/.github/dependabot.yml b/.github/dependabot.yml deleted file mode 100644 index 8c139c7bec29..000000000000 --- a/.github/dependabot.yml +++ /dev/null @@ -1,6 +0,0 @@ -version: 2 -updates: -- package-ecosystem: "github-actions" - directory: "/" - schedule: - interval: "weekly" diff --git a/.github/workflows/assertoor.yml b/.github/workflows/assertoor.yml deleted file mode 100644 index a5028f7ff31a..000000000000 --- a/.github/workflows/assertoor.yml +++ /dev/null @@ -1,230 +0,0 @@ -name: Assertoor Tests - -on: - workflow_dispatch: - schedule: - - cron: '0 0 * * *' - -jobs: - get_tests: - name: "Run assertoor tests on reth pairs" - runs-on: ubuntu-latest - outputs: - test_result: ${{ steps.test_result.outputs.test_result }} - test_status: ${{ steps.test_result.outputs.test_status }} - failed_test_status: ${{ steps.test_result.outputs.failed_test_status }} - if: github.repository == 'paradigmxyz/reth' - steps: - - name: Checkout Repository - uses: actions/checkout@v4 - - name: Setup Kurtosis - shell: bash - run: | - echo "deb [trusted=yes] https://apt.fury.io/kurtosis-tech/ /" | sudo tee /etc/apt/sources.list.d/kurtosis.list - sudo apt update - sudo apt install kurtosis-cli - kurtosis analytics disable - - - name: Run Kurtosis - shell: bash - id: services - run: | - export github_sha=${{ github.sha }} - export github_repository=${{ github.repository }} - - cat etc/assertoor/assertoor-template.yaml | envsubst > etc/assertoor/assertoor.yaml - - kurtosis run github.com/ethpandaops/ethereum-package --enclave assertoor-${{ github.run_id }} --args-file etc/assertoor/assertoor.yaml - - enclave_dump=$(kurtosis enclave inspect assertoor-${{ github.run_id }}) - - assertoor_url=$(echo "$enclave_dump" | grep assertoor | grep http | sed 's/.*\(http:\/\/[0-9.:]\+\).*/\1/') - echo "assertoor_url: ${assertoor_url}" - echo "assertoor_url=${assertoor_url}" >> $GITHUB_OUTPUT - - - name: Await test completion - shell: bash - id: test_result - run: | - assertoor_url="${{ steps.services.outputs.assertoor_url }}" - - YELLOW='\033[1;33m' - GRAY='\033[0;37m' - GREEN='\033[0;32m' - RED='\033[0;31m' - NC='\033[0m' - - # print assertor logs - assertoor_container=$(docker container list | grep assertoor | sed 's/^\([^ ]\+\) .*$/\1/') - docker logs -f $assertoor_container & - - # helper to fetch task status for specific test id - get_tasks_status() { - tasks=$(curl -s ${assertoor_url}/api/v1/test_run/$1 | jq -c ".data.tasks[] | {index, parent_index, name, title, status, result}") - declare -A task_graph_map - task_graph_map[0]="" - - while read task; do - task_id=$(echo "$task" | jq -r ".index") - task_parent=$(echo "$task" | jq -r ".parent_index") - task_name=$(echo "$task" | jq -r ".name") - task_title=$(echo "$task" | jq -r ".title") - task_status=$(echo "$task" | jq -r ".status") - task_result=$(echo "$task" | jq -r ".result") - - task_graph="${task_graph_map[$task_parent]}" - task_graph_map[$task_id]="$task_graph |" - if [ ! -z "$task_graph" ]; then - task_graph="${task_graph}- " - fi - - if [ "$task_status" == "pending" ]; then - task_status="${GRAY}pending ${NC}" - elif [ "$task_status" == "running" ]; then - task_status="${YELLOW}running ${NC}" - elif [ "$task_status" == "complete" ]; then - task_status="${GREEN}complete${NC}" - fi - - if [ "$task_result" == "none" ]; then - task_result="${GRAY}none ${NC}" - elif [ "$task_result" == "success" ]; then - task_result="${GREEN}success${NC}" - elif [ "$task_result" == "failure" ]; then - task_result="${RED}failure${NC}" - fi - - echo -e " $(printf '%-4s' "$task_id")\t$task_status\t$task_result\t$(printf '%-50s' "$task_graph$task_name") \t$task_title" - done <<< $(echo "$tasks") - } - - # poll & check test status - final_test_result="" - failed_test_id="" - while true - do - pending_tests=0 - failed_tests=0 - total_tests=0 - running_test="" - - status_lines=() - task_lines="" - status_lines+=("$(date +'%Y-%m-%d %H:%M:%S') Test Status:") - - tests=$(curl -s ${assertoor_url}/api/v1/test_runs | jq -c ".data[] | {run_id, test_id, name, status}") - while read test; do - if [ -z "$test" ]; then - continue - fi - run_id=$(echo "$test" | jq -r ".run_id") - test_id=$(echo "$test" | jq -r ".test_id") - test_name=$(echo "$test" | jq -r ".name") - test_status=$(echo "$test" | jq -r ".status") - - if [ "$test_status" == "pending" ]; then - pending_tests=$(expr $pending_tests + 1) - status_name="${GRAY}pending${NC}" - elif [ "$test_status" == "running" ]; then - pending_tests=$(expr $pending_tests + 1) - running_test="$run_id" - status_name="${YELLOW}running${NC}" - - elif [ "$test_status" == "success" ]; then - status_name="${GREEN}success${NC}" - elif [ "$test_status" == "failure" ]; then - failed_tests=$(expr $failed_tests + 1) - failed_test_id="$run_id" - status_name="${RED}failure${NC}" - else - status_name="$test_status" - fi - status_lines+=(" $(printf '%-3s' "$test_id") $status_name \t$test_name") - total_tests=$(expr $total_tests + 1) - done <<< $(echo "$tests") - - for status_line in "${status_lines[@]}" - do - echo -e "$status_line" - done - - if ! [ -z "$running_test" ]; then - task_lines=$(get_tasks_status "$running_test") - echo "Active Test Task Status:" - echo "$task_lines" - fi - - if [ $failed_tests -gt 0 ]; then - final_test_result="failure" - break - fi - if [ $total_tests -gt 0 ] && [ $pending_tests -le 0 ]; then - final_test_result="success" - break - fi - - sleep 60 - done - - # save test results & status to github output - echo "test_result=$(echo "$final_test_result")" >> $GITHUB_OUTPUT - echo "test_status<> $GITHUB_OUTPUT - for status_line in "${status_lines[@]}" - do - echo -e "$status_line" >> $GITHUB_OUTPUT - done - echo "EOF" >> $GITHUB_OUTPUT - - if ! [ -z "$failed_test_id" ]; then - echo "failed_test_status<> $GITHUB_OUTPUT - get_tasks_status "$failed_test_id" >> $GITHUB_OUTPUT - echo "EOF" >> $GITHUB_OUTPUT - else - echo "failed_test_status=" >> $GITHUB_OUTPUT - fi - - - name: Generate dump and remove kurtosis enclave - shell: bash - run: | - mkdir -p ./temp/dump - cd ./temp/dump - cp ../../etc/assertoor/assertoor.yaml ./kurtosis-params.yaml - - kurtosis enclave dump assertoor-${{ github.run_id }} - kurtosis enclave rm -f assertoor-${{ github.run_id }} - - - name: Upload dump artifact - uses: actions/upload-artifact@v4 - with: - name: "kurtosis-enclave-dump-${{ github.run_id }}" - path: ./temp/dump - - - name: Return test result - shell: bash - run: | - test_result="${{ steps.test_result.outputs.test_result }}" - test_status=$( - cat <<"EOF" - ${{ steps.test_result.outputs.test_status }} - EOF - ) - failed_test_status=$( - cat <<"EOF" - ${{ steps.test_result.outputs.failed_test_status }} - EOF - ) - - echo "Test Result: $test_result" - echo "$test_status" - - if ! [ "$test_result" == "success" ]; then - echo "" - echo "Failed Test Task Status:" - echo "$failed_test_status" - - echo "" - echo "See 'Await test completion' task for detailed logs about this failure!" - echo "" - - exit 1 # fail action - fi diff --git a/.github/workflows/bench.yml b/.github/workflows/bench.yml deleted file mode 100644 index f8d1d475e300..000000000000 --- a/.github/workflows/bench.yml +++ /dev/null @@ -1,60 +0,0 @@ -# Runs benchmarks. - -on: - pull_request: - merge_group: - push: - branches: [main] - -env: - CARGO_TERM_COLOR: always - BASELINE: base - IAI_CALLGRIND_RUNNER: iai-callgrind-runner - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -name: bench -jobs: - iai: - runs-on: - group: Reth - # Only run benchmarks in merge groups and on main - if: github.event_name != 'pull_request' - steps: - - uses: actions/checkout@v4 - - name: Install Valgrind - run: sudo apt update && sudo apt install valgrind - - uses: dtolnay/rust-toolchain@stable - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - name: Install cargo-binstall - uses: taiki-e/install-action@cargo-binstall - - name: Install iai-callgrind-runner - run: | - echo "::group::Install" - version=$(cargo metadata --format-version=1 |\ - jq '.packages[] | select(.name == "iai-callgrind").version' |\ - tr -d '"' - ) - cargo binstall iai-callgrind-runner --version $version --no-confirm --no-symlinks --force - echo "::endgroup::" - echo "::group::Verification" - which iai-callgrind-runner - echo "::endgroup::" - - name: Checkout base - uses: actions/checkout@v4 - with: - ref: ${{ github.base_ref || 'main' }} - - name: Generate test vectors - run: cargo run --bin reth --features dev -- test-vectors tables - - name: Save baseline - run: cargo bench -p reth-db --bench iai --profile profiling --features test-utils -- --save-baseline=$BASELINE - - name: Checkout PR - uses: actions/checkout@v4 - with: - clean: false - - name: Compare PR benchmarks - run: cargo bench -p reth-db --bench iai --profile profiling --features test-utils -- --baseline=$BASELINE diff --git a/.github/workflows/book.yml b/.github/workflows/book.yml deleted file mode 100644 index 56d5c427466e..000000000000 --- a/.github/workflows/book.yml +++ /dev/null @@ -1,135 +0,0 @@ -# Documentation and mdbook related jobs. - -name: book - -on: - push: - branches: [main] - pull_request: - branches: [main] - merge_group: - -jobs: - test: - runs-on: ubuntu-latest - name: test - timeout-minutes: 60 - - steps: - - uses: actions/checkout@v4 - - - name: Install mdbook - run: | - mkdir mdbook - curl -sSL https://github.com/rust-lang/mdBook/releases/download/v0.4.14/mdbook-v0.4.14-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=./mdbook - echo $(pwd)/mdbook >> $GITHUB_PATH - - - name: Install mdbook-template - run: | - mkdir mdbook-template - curl -sSL https://github.com/sgoudham/mdbook-template/releases/latest/download/mdbook-template-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=./mdbook-template - echo $(pwd)/mdbook-template >> $GITHUB_PATH - - - name: Run tests - run: mdbook test - - lint: - runs-on: ubuntu-latest - name: lint - timeout-minutes: 60 - - steps: - - uses: actions/checkout@v4 - - - name: Install mdbook-linkcheck - run: | - mkdir mdbook-linkcheck - curl -sSL -o mdbook-linkcheck.zip https://github.com/Michael-F-Bryan/mdbook-linkcheck/releases/latest/download/mdbook-linkcheck.x86_64-unknown-linux-gnu.zip - unzip mdbook-linkcheck.zip -d ./mdbook-linkcheck - chmod +x $(pwd)/mdbook-linkcheck/mdbook-linkcheck - echo $(pwd)/mdbook-linkcheck >> $GITHUB_PATH - - - name: Run linkcheck - run: mdbook-linkcheck --standalone - - build: - runs-on: ubuntu-latest - timeout-minutes: 60 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@nightly - - name: Install mdbook - run: | - mkdir mdbook - curl -sSL https://github.com/rust-lang/mdBook/releases/download/v0.4.14/mdbook-v0.4.14-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=./mdbook - echo $(pwd)/mdbook >> $GITHUB_PATH - - - name: Install mdbook-template - run: | - mkdir mdbook-template - curl -sSL https://github.com/sgoudham/mdbook-template/releases/latest/download/mdbook-template-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=./mdbook-template - echo $(pwd)/mdbook-template >> $GITHUB_PATH - - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - - name: Build book - run: mdbook build - - - name: Build docs - run: cargo docs --exclude "example-*" - env: - # Keep in sync with ./ci.yml:jobs.docs - RUSTDOCFLAGS: - --cfg docsrs --show-type-layout --generate-link-to-definition --enable-index-page - -Zunstable-options - - - name: Move docs to book folder - run: | - mv target/doc target/book/docs - - - name: Archive artifact - shell: sh - run: | - chmod -c -R +rX "target/book" | - while read line; do - echo "::warning title=Invalid file permissions automatically fixed::$line" - done - tar \ - --dereference --hard-dereference \ - --directory "target/book" \ - -cvf "$RUNNER_TEMP/artifact.tar" \ - --exclude=.git \ - --exclude=.github \ - . - - - name: Upload artifact - uses: actions/upload-artifact@v4 - with: - name: github-pages - path: ${{ runner.temp }}/artifact.tar - retention-days: 1 - if-no-files-found: error - - deploy: - # Only deploy if a push to main - if: github.ref_name == 'main' && github.event_name == 'push' - runs-on: ubuntu-latest - needs: [test, lint, build] - - # Grant GITHUB_TOKEN the permissions required to make a Pages deployment - permissions: - pages: write - id-token: write - - environment: - name: github-pages - url: ${{ steps.deployment.outputs.page_url }} - - timeout-minutes: 60 - - steps: - - name: Deploy to GitHub Pages - id: deployment - uses: actions/deploy-pages@v4 diff --git a/.github/workflows/deny.yml b/.github/workflows/deny.yml deleted file mode 100644 index f85484ca2ec2..000000000000 --- a/.github/workflows/deny.yml +++ /dev/null @@ -1,27 +0,0 @@ -# Runs `cargo-deny` when modifying `Cargo.lock`. - -name: deny - -on: - push: - branches: [main] - paths: [Cargo.lock] - pull_request: - branches: [main] - paths: [Cargo.lock] - merge_group: - -env: - CARGO_TERM_COLOR: always - -concurrency: deny-${{ github.head_ref || github.run_id }} - -jobs: - deny: - name: deny - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: EmbarkStudios/cargo-deny-action@v2 - with: - command: check all diff --git a/.github/workflows/dependencies.yml b/.github/workflows/dependencies.yml deleted file mode 100644 index 336004eded9f..000000000000 --- a/.github/workflows/dependencies.yml +++ /dev/null @@ -1,61 +0,0 @@ -# Runs `cargo update` periodically. - -name: Update Dependencies - -on: - schedule: - # Run weekly - - cron: "0 0 * * SUN" - workflow_dispatch: - # Needed so we can run it manually - -env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - BRANCH: cargo-update - TITLE: "chore(deps): weekly `cargo update`" - BODY: | - Automation to keep dependencies in `Cargo.lock` current. - -
cargo update log -

- - ```log - $cargo_update_log - ``` - -

-
- -jobs: - update: - name: Update - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@nightly - - - name: cargo update - # Remove first line that always just says "Updating crates.io index" - run: cargo update --color never 2>&1 | sed '/crates.io index/d' | tee -a cargo_update.log - - - name: craft commit message and PR body - id: msg - run: | - export cargo_update_log="$(cat cargo_update.log)" - - echo "commit_message<> $GITHUB_OUTPUT - printf "$TITLE\n\n$cargo_update_log\n" >> $GITHUB_OUTPUT - echo "EOF" >> $GITHUB_OUTPUT - - echo "body<> $GITHUB_OUTPUT - echo "$BODY" | envsubst >> $GITHUB_OUTPUT - echo "EOF" >> $GITHUB_OUTPUT - - - name: Create Pull Request - uses: peter-evans/create-pull-request@v6 - with: - add-paths: ./Cargo.lock - commit-message: ${{ steps.msg.outputs.commit_message }} - title: ${{ env.TITLE }} - body: ${{ steps.msg.outputs.body }} - branch: ${{ env.BRANCH }} diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml deleted file mode 100644 index 2af324a39eb7..000000000000 --- a/.github/workflows/docker.yml +++ /dev/null @@ -1,48 +0,0 @@ -# Publishes the Docker image. - -name: docker - -on: - workflow_dispatch: {} - push: - tags: - - v* - -env: - REPO_NAME: ${{ github.repository_owner }}/reth - IMAGE_NAME: ${{ github.repository_owner }}/reth - OP_IMAGE_NAME: ${{ github.repository_owner }}/op-reth - CARGO_TERM_COLOR: always - DOCKER_IMAGE_NAME: ghcr.io/${{ github.repository_owner }}/reth - OP_DOCKER_IMAGE_NAME: ghcr.io/${{ github.repository_owner }}/op-reth - DOCKER_USERNAME: ${{ github.actor }} - -jobs: - build: - name: build and push - runs-on: ubuntu-20.04 - permissions: - packages: write - contents: read - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - uses: taiki-e/install-action@cross - - name: Log in to Docker - run: | - echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io --username ${DOCKER_USERNAME} --password-stdin - - name: Set up Docker builder - run: | - docker run --privileged --rm tonistiigi/binfmt --install arm64,amd64 - docker buildx create --use --name cross-builder - - name: Build and push reth image, tag as "latest" - run: make PROFILE=maxperf docker-build-push-latest - - name: Build and push reth image - run: make PROFILE=maxperf docker-build-push - - name: Build and push op-reth image, tag as "latest" - run: make IMAGE_NAME=$OP_IMAGE_NAME DOCKER_IMAGE_NAME=$OP_DOCKER_IMAGE_NAME PROFILE=maxperf op-docker-build-push-latest - - name: Build and push op-reth image - run: make IMAGE_NAME=$OP_IMAGE_NAME DOCKER_IMAGE_NAME=$OP_DOCKER_IMAGE_NAME PROFILE=maxperf op-docker-build-push diff --git a/.github/workflows/eth-sync.yml b/.github/workflows/eth-sync.yml deleted file mode 100644 index f473e29a57c6..000000000000 --- a/.github/workflows/eth-sync.yml +++ /dev/null @@ -1,53 +0,0 @@ -# Runs an ethereum mainnet sync test. - -name: eth-sync-test - -on: - pull_request: - merge_group: - push: - branches: [ main ] - -env: - CARGO_TERM_COLOR: always - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - sync: - name: sync / 100k blocks - # Only run sync tests in merge groups - if: github.event_name == 'merge_group' - runs-on: - group: Reth - env: - RUST_LOG: info,sync=error - RUST_BACKTRACE: 1 - timeout-minutes: 60 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - name: Build reth - run: | - cargo install --features asm-keccak,jemalloc --path bin/reth - - name: Run sync - run: | - reth node \ - --debug.tip 0x91c90676cab257a59cd956d7cb0bceb9b1a71d79755c23c7277a0697ccfaf8c4 \ - --debug.max-block 100000 \ - --debug.terminate - - name: Verify the target block hash - run: | - reth db get static-file headers 100000 \ - | grep 0x91c90676cab257a59cd956d7cb0bceb9b1a71d79755c23c7277a0697ccfaf8c4 - - name: Run stage unwind for 100 blocks - run: | - reth stage unwind num-blocks 100 - - name: Run stage unwind to block hash - run: | - reth stage unwind to-block 0x52e0509d33a988ef807058e2980099ee3070187f7333aae12b64d4d675f34c5a diff --git a/.github/workflows/hive.yml b/.github/workflows/hive.yml deleted file mode 100644 index c524e9eb7ffd..000000000000 --- a/.github/workflows/hive.yml +++ /dev/null @@ -1,244 +0,0 @@ -# Runs `ethereum/hive` tests. - -name: hive - -on: - workflow_dispatch: - schedule: - # every day - - cron: "0 0 * * *" - -env: - CARGO_TERM_COLOR: always - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - prepare-reth: - if: github.repository == 'paradigmxyz/reth' - timeout-minutes: 45 - runs-on: - group: Reth - steps: - - uses: actions/checkout@v4 - - run: mkdir artifacts - - uses: dtolnay/rust-toolchain@stable - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - name: Build reth - run: | - cargo build --features asm-keccak --profile hivetests --bin reth --locked - mkdir dist && cp ./target/hivetests/reth ./dist/reth - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 - - name: Build and export reth image - uses: docker/build-push-action@v6 - with: - context: . - file: .github/assets/hive/Dockerfile - tags: ghcr.io/paradigmxyz/reth:latest - outputs: type=docker,dest=./artifacts/reth_image.tar - cache-from: type=gha - cache-to: type=gha,mode=max - - - name: Upload reth image - uses: actions/upload-artifact@v4 - with: - name: artifacts - path: ./artifacts - - prepare-hive: - if: github.repository == 'paradigmxyz/reth' - timeout-minutes: 45 - runs-on: - group: Reth - steps: - - uses: actions/checkout@v4 - - name: Checkout hive tests - uses: actions/checkout@v4 - with: - repository: ethereum/hive - ref: master - path: hivetests - - - uses: actions/setup-go@v5 - with: - go-version: "^1.13.1" - - run: go version - - - name: Build hive assets - run: .github/assets/hive/build_simulators.sh - - - name: Upload hive assets - uses: actions/upload-artifact@v4 - with: - name: hive_assets - path: ./hive_assets - test: - timeout-minutes: 60 - strategy: - fail-fast: false - matrix: - # ethereum/rpc to be deprecated: - # https://github.com/ethereum/hive/pull/1117 - sim: [smoke/genesis, smoke/network, ethereum/sync] - include: - - sim: devp2p - limit: discv4 - - sim: devp2p - limit: eth - include: - # status - - TestStatus - # get block headers - - TestGetBlockHeaders - - TestSimultaneousRequests - - TestSameRequestID - - TestZeroRequestID - # get block bodies - - TestGetBlockBodies - # malicious handshakes + status - - TestMaliciousHandshake - - TestMaliciousStatus - # test transactions - - TestLargeTxRequest - - TestTransaction - - TestInvalidTxs - - TestNewPooledTxs - - TestBlobViolations - - sim: ethereum/engine - limit: engine-exchange-capabilities - - sim: ethereum/engine - limit: engine-withdrawals - - sim: ethereum/engine - limit: engine-auth - - sim: ethereum/engine - limit: engine-api - - sim: ethereum/engine - limit: cancun - # eth_ rpc methods - - sim: ethereum/rpc-compat - include: - - eth_blockNumber - - eth_call - - eth_chainId - - eth_createAccessList - - eth_estimateGas - - eth_feeHistory - - eth_getBalance - - eth_getBlockBy - - eth_getBlockTransactionCountBy - - eth_getCode - - eth_getProof - - eth_getStorage - - eth_getTransactionBy - - eth_getTransactionCount - - eth_getTransactionReceipt - - eth_sendRawTransaction - - eth_syncing - # debug_ rpc methods - - sim: ethereum/rpc-compat - include: [debug_] - # Pyspec cancun jobs - - sim: pyspec - include: [cancun/eip4844] - - sim: pyspec - include: [cancun/eip4788] - - sim: pyspec - include: [cancun/eip6780] - - sim: pyspec - include: [cancun/eip5656] - - sim: pyspec - include: [cancun/eip1153] - - sim: pyspec - include: [cancun/eip7516] - # Pyspec shanghai jobs - - sim: pyspec - include: [shanghai/eip3651] - - sim: pyspec - include: [shanghai/eip3855] - - sim: pyspec - include: [shanghai/eip3860] - - sim: pyspec - include: [shanghai/eip4895] - # Pyspec merge and earlier jobs - - sim: pyspec - include: [merge/] - - sim: pyspec - include: [berlin/] - - sim: pyspec - include: [istanbul/] - - sim: pyspec - include: [homestead/] - - sim: pyspec - include: [frontier/] - needs: - - prepare-reth - - prepare-hive - name: run - runs-on: - group: Reth - permissions: - issues: write - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Download hive assets - uses: actions/download-artifact@v4 - with: - name: hive_assets - path: /tmp - - - name: Download reth image - uses: actions/download-artifact@v4 - with: - name: artifacts - path: /tmp - - - name: Load Docker images - run: .github/assets/hive/load_images.sh - - - name: Move hive binary - run: | - mv /tmp/hive /usr/local/bin - chmod +x /usr/local/bin/hive - - - name: Checkout hive tests - uses: actions/checkout@v4 - with: - repository: ethereum/hive - ref: master - path: hivetests - - - name: Run ${{ matrix.sim }} simulator - run: .github/assets/hive/run_simulator.sh "${{ matrix.sim }}$" "${{matrix.limit}}/${{join(matrix.include, '|')}}" - - - name: Parse hive output - run: | - find hivetests/workspace/logs -type f -name "*.json" ! -name "hive.json" | xargs -I {} python .github/assets/hive/parse.py {} --exclusion .github/assets/hive/expected_failures.yaml - - - name: Print simulator output - if: ${{ failure() }} - run: | - cat hivetests/workspace/logs/*simulator*.log - - - name: Print reth client logs - if: ${{ failure() }} - run: | - cat hivetests/workspace/logs/reth/client-*.log - notify-on-error: - needs: test - if: failure() - runs-on: - group: Reth - steps: - - name: Discord Webhook Action - uses: tsickert/discord-webhook@v6.0.0 - with: - webhook-url: ${{ secrets.RETH_ALERTS_WEBHOOK }} - content: "Failed run: https://github.com/paradigmxyz/reth/actions/runs/${{ github.run_id }}" diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml deleted file mode 100644 index 103a87706bca..000000000000 --- a/.github/workflows/integration.yml +++ /dev/null @@ -1,62 +0,0 @@ -# Runs integration tests. - -name: integration - -on: - pull_request: - merge_group: - push: - branches: [main] - -env: - CARGO_TERM_COLOR: always - SEED: rustethereumethereumrust - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - test: - name: test / ${{ matrix.network }} - runs-on: - group: Reth - env: - RUST_BACKTRACE: 1 - strategy: - matrix: - network: ["ethereum", "optimism"] - timeout-minutes: 60 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - name: Install Geth - run: .github/assets/install_geth.sh - - uses: taiki-e/install-action@nextest - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - if: matrix.network == 'ethereum' - name: Run tests - run: | - cargo nextest run \ - --locked --features "asm-keccak ${{ matrix.network }}" \ - --workspace --exclude ef-tests \ - -E "kind(test)" - - if: matrix.network == 'optimism' - name: Run tests - run: | - cargo nextest run \ - --locked -p reth-node-optimism --features "optimism" - - integration-success: - name: integration success - runs-on: ubuntu-latest - if: always() - needs: [test] - timeout-minutes: 30 - steps: - - name: Decide whether the needed jobs succeeded or failed - uses: re-actors/alls-green@release/v1 - with: - jobs: ${{ toJSON(needs) }} diff --git a/.github/workflows/label-pr.yml b/.github/workflows/label-pr.yml deleted file mode 100644 index 07727173531b..000000000000 --- a/.github/workflows/label-pr.yml +++ /dev/null @@ -1,23 +0,0 @@ -name: Label PRs - -on: - pull_request: - types: [opened] - -jobs: - label_prs: - runs-on: ubuntu-latest - permissions: - issues: write - pull-requests: write - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Label PRs - uses: actions/github-script@v7 - with: - script: | - const label_pr = require('./.github/assets/label_pr.js') - await label_pr({github, context}) diff --git a/.github/workflows/lint-actions.yml b/.github/workflows/lint-actions.yml deleted file mode 100644 index 4c2171784d35..000000000000 --- a/.github/workflows/lint-actions.yml +++ /dev/null @@ -1,22 +0,0 @@ -name: Lint GitHub Actions workflows -on: - pull_request: - paths: - - '.github/**' - merge_group: - push: - paths: - - '.github/**' - -jobs: - actionlint: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Download actionlint - id: get_actionlint - run: bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash) - shell: bash - - name: Check workflow files - run: SHELLCHECK_OPTS="-S error" ${{ steps.get_actionlint.outputs.executable }} -color - shell: bash diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml deleted file mode 100644 index 0b29e2d55691..000000000000 --- a/.github/workflows/lint.yml +++ /dev/null @@ -1,209 +0,0 @@ -name: lint - -on: - pull_request: - merge_group: - push: - branches: [main] - -env: - CARGO_TERM_COLOR: always - -jobs: - clippy-binaries: - name: clippy / ${{ matrix.network }} - runs-on: ubuntu-latest - timeout-minutes: 30 - strategy: - matrix: - include: - - binary: reth - network: ethereum - - binary: op-reth - network: optimism - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@clippy - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - run: cargo clippy --bin "${{ matrix.binary }}" --workspace --features "${{ matrix.network }} asm-keccak jemalloc jemalloc-prof min-error-logs min-warn-logs min-info-logs min-debug-logs min-trace-logs" - env: - RUSTFLAGS: -D warnings - - clippy: - name: clippy - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@clippy - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - run: cargo clippy --workspace --lib --examples --tests --benches --all-features --locked - env: - RUSTFLAGS: -D warnings - - wasm: - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - with: - target: wasm32-wasip1 - - uses: taiki-e/install-action@cargo-hack - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - name: Run Wasm checks - run: .github/assets/check_wasm.sh - - crate-checks: - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - uses: taiki-e/install-action@cargo-hack - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - run: cargo hack check - - msrv: - name: MSRV / ${{ matrix.network }} - runs-on: ubuntu-latest - timeout-minutes: 30 - strategy: - matrix: - include: - - binary: reth - network: ethereum - - binary: op-reth - network: optimism - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@master - with: - toolchain: "1.80" # MSRV - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - run: cargo build --bin "${{ matrix.binary }}" --workspace --features "${{ matrix.network }}" - env: - RUSTFLAGS: -D warnings - - docs: - name: docs - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@nightly - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - run: cargo docs --document-private-items - env: - # Keep in sync with ./book.yml:jobs.build - # This should only add `-D warnings` - RUSTDOCFLAGS: --cfg docsrs --show-type-layout --generate-link-to-definition --enable-index-page -Zunstable-options -D warnings - - fmt: - name: fmt - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@nightly - with: - components: rustfmt - - run: cargo fmt --all --check - - book: - name: book - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@master - with: - toolchain: "1.80" # MSRV - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - run: cargo build --bin reth --workspace --features ethereum - env: - RUSTFLAGS: -D warnings - - run: ./book/cli/update.sh target/debug/reth - - name: Check book changes - run: git diff --exit-code - - codespell: - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: codespell-project/actions-codespell@v2 - with: - skip: "*.json" - - grafana: - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - name: Check dashboard JSON with jq - uses: sergeysova/jq-action@v2 - with: - cmd: jq empty etc/grafana/dashboards/overview.json - - no-test-deps: - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - name: Ensure no arbitrary or proptest dependency on default build - run: cargo tree --package reth -e=features,no-dev | grep -Eq "arbitrary|proptest" && exit 1 || exit 0 - - # Checks that selected rates can compile with power set of features - features: - name: features - runs-on: ubuntu-latest - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@clippy - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - name: cargo install cargo-hack - uses: taiki-e/install-action@cargo-hack - - run: make check-features - env: - RUSTFLAGS: -D warnings - - lint-success: - name: lint success - runs-on: ubuntu-latest - if: always() - needs: - - clippy-binaries - - clippy - - crate-checks - - docs - - fmt - - book - - codespell - - grafana - - no-test-deps - - features - timeout-minutes: 30 - steps: - - name: Decide whether the needed jobs succeeded or failed - uses: re-actors/alls-green@release/v1 - with: - jobs: ${{ toJSON(needs) }} diff --git a/.github/workflows/op-sync.yml b/.github/workflows/op-sync.yml deleted file mode 100644 index 26fa68d7f905..000000000000 --- a/.github/workflows/op-sync.yml +++ /dev/null @@ -1,56 +0,0 @@ -# Runs a base mainnet sync test. - -name: op-sync-test - -on: - pull_request: - merge_group: - push: - branches: [ main ] - -env: - CARGO_TERM_COLOR: always - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - sync: - name: op sync / 10k blocks - # Only run sync tests in merge groups - if: github.event_name == 'merge_group' - runs-on: - group: Reth - env: - RUST_LOG: info,sync=error - RUST_BACKTRACE: 1 - timeout-minutes: 60 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - name: Build op-reth - run: | - cargo install --features asm-keccak,jemalloc,optimism --bin op-reth --path bin/reth - - name: Run sync - # https://basescan.org/block/10000 - run: | - op-reth node \ - --chain base \ - --debug.tip 0xbb9b85352c7ebca6ba8efc63bd66cecd038c92ec8ebd02e153a3e0b197e672b7 \ - --debug.max-block 10000 \ - --debug.terminate - - name: Verify the target block hash - run: | - op-reth db --chain base get static-file headers 10000 \ - | grep 0xbb9b85352c7ebca6ba8efc63bd66cecd038c92ec8ebd02e153a3e0b197e672b7 - - name: Run stage unwind for 100 blocks - run: | - op-reth stage --chain base unwind num-blocks 100 - - name: Run stage unwind to block hash - run: | - op-reth stage --chain base unwind to-block 0x118a6e922a8c6cab221fc5adfe5056d2b72d58c6580e9c5629de55299e2cf8de - diff --git a/.github/workflows/release-dist.yml b/.github/workflows/release-dist.yml deleted file mode 100644 index 2142360e0396..000000000000 --- a/.github/workflows/release-dist.yml +++ /dev/null @@ -1,20 +0,0 @@ -# This workflow auto-publishes Reth to external package managers such as -# Homebrew when a release is published. - -name: release externally - -on: - release: - types: [published] - -jobs: - release-homebrew: - runs-on: ubuntu-latest - steps: - - name: Update Homebrew formula - uses: dawidd6/action-homebrew-bump-formula@v3 - with: - token: ${{ secrets.HOMEBREW }} - no_fork: true - tap: paradigmxyz/brew - formula: reth diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index 5735ae6ef528..000000000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,197 +0,0 @@ -# This workflow is modified from Lighthouse: -# https://github.com/sigp/lighthouse/blob/441fc1691b69f9edc4bbdc6665f3efab16265c9b/.github/workflows/release.yml - -name: release - -on: - push: - tags: - - v* - -env: - REPO_NAME: ${{ github.repository_owner }}/reth - OP_IMAGE_NAME: ${{ github.repository_owner }}/op-reth - IMAGE_NAME: ${{ github.repository_owner }}/reth - CARGO_TERM_COLOR: always - -jobs: - extract-version: - name: extract version - runs-on: ubuntu-latest - steps: - - name: Extract version - run: echo "VERSION=$(echo ${GITHUB_REF#refs/tags/})" >> $GITHUB_OUTPUT - id: extract_version - outputs: - VERSION: ${{ steps.extract_version.outputs.VERSION }} - - build: - name: build release - runs-on: ${{ matrix.configs.os }} - needs: extract-version - strategy: - matrix: - configs: - - target: x86_64-unknown-linux-gnu - os: ubuntu-20.04 - profile: maxperf - - target: aarch64-unknown-linux-gnu - os: ubuntu-20.04 - profile: maxperf - - target: x86_64-apple-darwin - os: macos-13 - profile: maxperf - - target: aarch64-apple-darwin - os: macos-14 - profile: maxperf - - target: x86_64-pc-windows-gnu - os: ubuntu-20.04 - profile: maxperf - build: - - command: build - binary: reth - - command: op-build - binary: op-reth - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - with: - target: ${{ matrix.configs.target }} - - uses: taiki-e/install-action@cross - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - - name: Apple M1 setup - if: matrix.configs.target == 'aarch64-apple-darwin' - run: | - echo "SDKROOT=$(xcrun -sdk macosx --show-sdk-path)" >> $GITHUB_ENV - echo "MACOSX_DEPLOYMENT_TARGET=$(xcrun -sdk macosx --show-sdk-platform-version)" >> $GITHUB_ENV - - - name: Build Reth - run: make PROFILE=${{ matrix.configs.profile }} ${{ matrix.build.command }}-${{ matrix.configs.target }} - - name: Move binary - run: | - mkdir artifacts - [[ "${{ matrix.configs.target }}" == *windows* ]] && ext=".exe" - mv "target/${{ matrix.configs.target }}/${{ matrix.configs.profile }}/${{ matrix.build.binary }}${ext}" ./artifacts - - - name: Configure GPG and create artifacts - env: - GPG_SIGNING_KEY: ${{ secrets.GPG_SIGNING_KEY }} - GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} - run: | - export GPG_TTY=$(tty) - echo -n "$GPG_SIGNING_KEY" | base64 --decode | gpg --batch --import - cd artifacts - tar -czf ${{ matrix.build.binary }}-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.configs.target }}.tar.gz ${{ matrix.build.binary }}* - echo "$GPG_PASSPHRASE" | gpg --passphrase-fd 0 --pinentry-mode loopback --batch -ab ${{ matrix.build.binary }}-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.configs.target }}.tar.gz - mv *tar.gz* .. - shell: bash - - - name: Upload artifact - uses: actions/upload-artifact@v4 - with: - name: ${{ matrix.build.binary }}-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.configs.target }}.tar.gz - path: ${{ matrix.build.binary }}-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.configs.target }}.tar.gz - - - name: Upload signature - uses: actions/upload-artifact@v4 - with: - name: ${{ matrix.build.binary }}-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.configs.target }}.tar.gz.asc - path: ${{ matrix.build.binary }}-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.configs.target }}.tar.gz.asc - - draft-release: - name: draft release - needs: [build, extract-version] - runs-on: ubuntu-latest - env: - VERSION: ${{ needs.extract-version.outputs.VERSION }} - permissions: - # Required to post the release - contents: write - steps: - # This is necessary for generating the changelog. - # It has to come before "Download Artifacts" or else it deletes the artifacts. - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - name: Download artifacts - uses: actions/download-artifact@v4 - - name: Generate full changelog - id: changelog - run: | - echo "CHANGELOG<> $GITHUB_OUTPUT - echo "$(git log --pretty=format:"- %s" $(git describe --tags --abbrev=0 ${{ env.VERSION }}^)..${{ env.VERSION }})" >> $GITHUB_OUTPUT - echo "EOF" >> $GITHUB_OUTPUT - - name: Create release draft - env: - GITHUB_USER: ${{ github.repository_owner }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # The formatting here is borrowed from Lighthouse (which is borrowed from OpenEthereum): - # https://github.com/openethereum/openethereum/blob/6c2d392d867b058ff867c4373e40850ca3f96969/.github/workflows/build.yml - run: | - body=$(cat <<- "ENDBODY" - ![image](https://raw.githubusercontent.com/paradigmxyz/reth/main/assets/reth-prod.png) - - ## Testing Checklist (DELETE ME) - - - [ ] Run on testnet for 1-3 days. - - [ ] Resync a mainnet node. - - [ ] Ensure all CI checks pass. - - ## Release Checklist (DELETE ME) - - - [ ] Ensure all crates have had their versions bumped. - - [ ] Write the summary. - - [ ] Fill out the update priority. - - [ ] Ensure all binaries have been added. - - [ ] Prepare release posts (Twitter, ...). - - ## Summary - - Add a summary, including: - - - Critical bug fixes - - New features - - Any breaking changes (and what to expect) - - ## Update Priority - - This table provides priorities for which classes of users should update particular components. - - | User Class | Priority | - |----------------------|-----------------| - | Payload Builders | | - | Non-Payload Builders | | - - *See [Update Priorities](https://paradigmxyz.github.io/reth/installation/priorities.html) for more information about this table.* - - ## All Changes - - ${{ steps.changelog.outputs.CHANGELOG }} - - ## Binaries - - [See pre-built binaries documentation.](https://paradigmxyz.github.io/reth/installation/binaries.html) - - The binaries are signed with the PGP key: `50FB 7CC5 5B2E 8AFA 59FE 03B7 AA5E D56A 7FBF 253E` - - | System | Architecture | Binary | PGP Signature | - |:---:|:---:|:---:|:---| - | | x86_64 | [reth-${{ env.VERSION }}-x86_64-unknown-linux-gnu.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-x86_64-unknown-linux-gnu.tar.gz) | [PGP Signature](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-x86_64-unknown-linux-gnu.tar.gz.asc) | - | | aarch64 | [reth-${{ env.VERSION }}-aarch64-unknown-linux-gnu.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-aarch64-unknown-linux-gnu.tar.gz) | [PGP Signature](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-aarch64-unknown-linux-gnu.tar.gz.asc) | - | | x86_64 | [reth-${{ env.VERSION }}-x86_64-pc-windows-gnu.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-x86_64-pc-windows-gnu.tar.gz) | [PGP Signature](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-x86_64-pc-windows-gnu.tar.gz.asc) | - | | x86_64 | [reth-${{ env.VERSION }}-x86_64-apple-darwin.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-x86_64-apple-darwin.tar.gz) | [PGP Signature](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-x86_64-apple-darwin.tar.gz.asc) | - | | aarch64 | [reth-${{ env.VERSION }}-aarch64-apple-darwin.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-aarch64-apple-darwin.tar.gz) | [PGP Signature](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/reth-${{ env.VERSION }}-aarch64-apple-darwin.tar.gz.asc) | - | | | | | - | **System** | **Option** | - | **Resource** | - | | Docker | | [${{ env.IMAGE_NAME }}](https://github.com/paradigmxyz/reth/pkgs/container/reth) | - ENDBODY - ) - assets=() - for asset in ./*reth-*.tar.gz*; do - assets+=("$asset/$asset") - done - tag_name="${{ env.VERSION }}" - echo "$body" | gh release create --draft -t "Reth $tag_name" -F "-" "$tag_name" "${assets[@]}" diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml deleted file mode 100644 index 60ffa8f73d72..000000000000 --- a/.github/workflows/stage.yml +++ /dev/null @@ -1,72 +0,0 @@ -# Runs all `stage run` commands. - -name: stage-test - -on: - pull_request: - merge_group: - push: - branches: [ main ] - -env: - CARGO_TERM_COLOR: always - FROM_BLOCK: 0 - TO_BLOCK: 50000 - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - stage: - name: stage-run-test - # Only run stage commands test in merge groups - if: github.event_name == 'merge_group' - runs-on: - group: Reth - env: - RUST_LOG: info,sync=error - RUST_BACKTRACE: 1 - timeout-minutes: 60 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - name: Build reth - run: | - cargo install --features asm-keccak,jemalloc --path bin/reth - - name: Run headers stage - run: | - reth stage run headers --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run bodies stage - run: | - reth stage run bodies --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run senders stage - run: | - reth stage run senders --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run execution stage - run: | - reth stage run execution --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run account-hashing stage - run: | - reth stage run account-hashing --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run storage hashing stage - run: | - reth stage run storage-hashing --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run hashing stage - run: | - reth stage run hashing --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run merkle stage - run: | - reth stage run merkle --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run transaction lookup stage - run: | - reth stage run tx-lookup --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run account history stage - run: | - reth stage run account-history --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints - - name: Run storage history stage - run: | - reth stage run storage-history --from ${{ env.FROM_BLOCK }} --to ${{ env.TO_BLOCK }} --commit --checkpoints diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml deleted file mode 100644 index 38cca2fb1a9b..000000000000 --- a/.github/workflows/stale.yml +++ /dev/null @@ -1,29 +0,0 @@ -# Marks issues as stale. - -name: stale issues - -on: - workflow_dispatch: {} - schedule: - - cron: "30 1 * * *" - -jobs: - close-issues: - runs-on: ubuntu-latest - permissions: - issues: write - pull-requests: write - steps: - - uses: actions/stale@v9 - with: - days-before-stale: 21 - days-before-close: 7 - stale-issue-label: "S-stale" - stale-pr-label: "S-stale" - exempt-issue-labels: "M-prevent-stale" - exempt-pr-labels: "M-prevent-stale" - stale-issue-message: "This issue is stale because it has been open for 21 days with no activity." - close-issue-message: "This issue was closed because it has been inactive for 7 days since being marked as stale." - exempt-all-milestones: true - exempt-all-assignees: true - repo-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/telos_ci.yml b/.github/workflows/telos_ci.yml new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/.github/workflows/unit.yml b/.github/workflows/unit.yml deleted file mode 100644 index a6663aea8843..000000000000 --- a/.github/workflows/unit.yml +++ /dev/null @@ -1,100 +0,0 @@ -# Runs unit tests. - -name: unit - -on: - pull_request: - merge_group: - push: - branches: [main] - -env: - CARGO_TERM_COLOR: always - SEED: rustethereumethereumrust - -concurrency: - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - test: - name: test / ${{ matrix.network }} (${{ matrix.partition }}/2) - runs-on: - group: Reth - env: - RUST_BACKTRACE: 1 - strategy: - matrix: - partition: [1, 2] - network: ["ethereum", "optimism"] - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - uses: taiki-e/install-action@nextest - - name: Run tests - run: | - cargo nextest run \ - --locked --features "asm-keccak ${{ matrix.network }}" \ - --workspace --exclude ef-tests \ - --partition hash:${{ matrix.partition }}/2 \ - -E "!kind(test)" - - state: - name: Ethereum state tests - runs-on: - group: Reth - env: - RUST_LOG: info,sync=error - RUST_BACKTRACE: 1 - timeout-minutes: 30 - steps: - - uses: actions/checkout@v4 - - name: Checkout ethereum/tests - uses: actions/checkout@v4 - with: - repository: ethereum/tests - ref: 1c23e3c27ac53b794de0844d2d5e19cd2495b9d8 - path: testing/ef-tests/ethereum-tests - submodules: recursive - fetch-depth: 1 - - uses: dtolnay/rust-toolchain@stable - - uses: taiki-e/install-action@nextest - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - run: cargo nextest run --release -p ef-tests --features "asm-keccak ef-tests" - - doc: - name: doc tests (${{ matrix.network }}) - runs-on: - group: Reth - env: - RUST_BACKTRACE: 1 - timeout-minutes: 30 - strategy: - matrix: - network: ["ethereum", "optimism"] - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - uses: Swatinem/rust-cache@v2 - with: - cache-on-failure: true - - name: Run doctests - run: cargo test --doc --workspace --features "${{ matrix.network }}" - - unit-success: - name: unit success - runs-on: ubuntu-latest - if: always() - needs: [test, state, doc] - timeout-minutes: 30 - steps: - - name: Decide whether the needed jobs succeeded or failed - uses: re-actors/alls-green@release/v1 - with: - jobs: ${{ toJSON(needs) }} diff --git a/Cargo.lock b/Cargo.lock index cff59f03244a..da35cd01a3cf 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -71,6 +71,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" dependencies = [ "cfg-if", + "const-random", "getrandom 0.2.15", "once_cell", "version_check", @@ -107,6 +108,22 @@ version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5c6cb57a04249c6480766f7f7cef5467412af1490f8d1e243141daddada3264f" +[[package]] +name = "alloy" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f4a4aaae80afd4be443a6aecd92a6b255dcdd000f97996928efb33d8a71e100" +dependencies = [ + "alloy-consensus", + "alloy-core", + "alloy-eips", + "alloy-genesis", + "alloy-provider", + "alloy-rpc-client", + "alloy-serde", + "alloy-transport-http", +] + [[package]] name = "alloy-chains" version = "0.1.25" @@ -136,6 +153,18 @@ dependencies = [ "serde", ] +[[package]] +name = "alloy-core" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "529fc6310dc1126c8de51c376cbc59c79c7f662bd742be7dc67055d5421a81b4" +dependencies = [ + "alloy-dyn-abi", + "alloy-json-abi", + "alloy-primitives", + "alloy-sol-types", +] + [[package]] name = "alloy-dyn-abi" version = "0.7.7" @@ -280,7 +309,7 @@ dependencies = [ "proptest", "proptest-derive 0.4.0", "rand 0.8.5", - "ruint", + "ruint 1.12.3", "serde", "tiny-keccak", ] @@ -314,7 +343,7 @@ dependencies = [ "futures-utils-wasm", "lru", "pin-project", - "reqwest", + "reqwest 0.12.5", "serde", "serde_json", "tokio", @@ -343,9 +372,9 @@ dependencies = [ [[package]] name = "alloy-rlp" -version = "0.3.7" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a43b18702501396fa9bcdeecd533bc85fac75150d308fc0f6800a01e6234a003" +checksum = "26154390b1d205a4a7ac7352aa2eb4f81f391399d4e2f546fb81a2f8bb383f62" dependencies = [ "alloy-rlp-derive", "arrayvec", @@ -354,9 +383,9 @@ dependencies = [ [[package]] name = "alloy-rlp-derive" -version = "0.3.7" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d83524c1f6162fcb5b0decf775498a125066c86dda6066ed609531b0e912f85a" +checksum = "4d0f2d905ebd295e7effec65e5f6868d153936130ae718352771de3e7d03c75c" dependencies = [ "proc-macro2", "quote", @@ -377,7 +406,7 @@ dependencies = [ "alloy-transport-ws", "futures", "pin-project", - "reqwest", + "reqwest 0.12.5", "serde", "serde_json", "tokio", @@ -656,7 +685,7 @@ checksum = "2437d145d80ea1aecde8574d2058cceb8b3c9cba05f6aea8e67907c660d46698" dependencies = [ "alloy-json-rpc", "alloy-transport", - "reqwest", + "reqwest 0.12.5", "serde_json", "tower", "tracing", @@ -691,11 +720,11 @@ dependencies = [ "alloy-pubsub", "alloy-transport", "futures", - "http", + "http 1.1.0", "rustls", "serde_json", "tokio", - "tokio-tungstenite", + "tokio-tungstenite 0.23.1", "tracing", "ws_stream_wasm", ] @@ -790,6 +819,80 @@ dependencies = [ "windows-sys 0.52.0", ] +[[package]] +name = "antelope-client" +version = "0.2.1" +source = "git+https://github.com/telosnetwork/antelope-rs?branch=finish_table_rows_params#c8d60b2f465f53c0245b615e6f76070755a8a587" +dependencies = [ + "antelope-client-macros", + "async-trait", + "base64 0.21.7", + "bs58", + "chrono", + "digest 0.10.7", + "ecdsa", + "flate2", + "hex", + "hmac 0.12.1", + "k256", + "log", + "once_cell", + "p256", + "rand 0.8.5", + "rand_core 0.6.4", + "reqwest 0.11.27", + "ripemd", + "serde", + "serde-big-array", + "serde_json", + "sha2 0.10.8", + "signature", + "thiserror", + "tokio", +] + +[[package]] +name = "antelope-client" +version = "0.2.1" +source = "git+https://github.com/telosnetwork/antelope-rs?branch=serialization#4bb0af2b4dab220b8185e450ba84f008209df896" +dependencies = [ + "antelope-client-macros", + "async-trait", + "base64 0.21.7", + "bs58", + "chrono", + "digest 0.10.7", + "ecdsa", + "flate2", + "hex", + "hmac 0.12.1", + "k256", + "log", + "once_cell", + "p256", + "rand 0.8.5", + "rand_core 0.6.4", + "reqwest 0.11.27", + "ripemd", + "serde", + "serde-big-array", + "serde_json", + "sha2 0.10.8", + "signature", + "thiserror", + "tokio", +] + +[[package]] +name = "antelope-client-macros" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5fe146e985f20989c1c9e9aca87f854ba430b5a5fadaac3f115bc9f81619634" +dependencies = [ + "quote", + "syn 1.0.109", +] + [[package]] name = "anyhow" version = "1.0.86" @@ -955,6 +1058,248 @@ version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" +[[package]] +name = "arrow" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "219d05930b81663fd3b32e3bde8ce5bff3c4d23052a99f11a8fa50a3b47b2658" +dependencies = [ + "arrow-arith", + "arrow-array", + "arrow-buffer", + "arrow-cast", + "arrow-csv", + "arrow-data", + "arrow-ipc", + "arrow-json", + "arrow-ord", + "arrow-row", + "arrow-schema", + "arrow-select", + "arrow-string", +] + +[[package]] +name = "arrow-arith" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0272150200c07a86a390be651abdd320a2d12e84535f0837566ca87ecd8f95e0" +dependencies = [ + "arrow-array", + "arrow-buffer", + "arrow-data", + "arrow-schema", + "chrono", + "half", + "num", +] + +[[package]] +name = "arrow-array" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8010572cf8c745e242d1b632bd97bd6d4f40fefed5ed1290a8f433abaa686fea" +dependencies = [ + "ahash", + "arrow-buffer", + "arrow-data", + "arrow-schema", + "chrono", + "half", + "hashbrown 0.14.5", + "num", +] + +[[package]] +name = "arrow-buffer" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0d0a2432f0cba5692bf4cb757469c66791394bac9ec7ce63c1afe74744c37b27" +dependencies = [ + "bytes", + "half", + "num", +] + +[[package]] +name = "arrow-cast" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9abc10cd7995e83505cc290df9384d6e5412b207b79ce6bdff89a10505ed2cba" +dependencies = [ + "arrow-array", + "arrow-buffer", + "arrow-data", + "arrow-schema", + "arrow-select", + "atoi", + "base64 0.22.1", + "chrono", + "half", + "lexical-core", + "num", + "ryu", +] + +[[package]] +name = "arrow-csv" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95cbcba196b862270bf2a5edb75927380a7f3a163622c61d40cbba416a6305f2" +dependencies = [ + "arrow-array", + "arrow-buffer", + "arrow-cast", + "arrow-data", + "arrow-schema", + "chrono", + "csv", + "csv-core", + "lazy_static", + "lexical-core", + "regex", +] + +[[package]] +name = "arrow-data" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2742ac1f6650696ab08c88f6dd3f0eb68ce10f8c253958a18c943a68cd04aec5" +dependencies = [ + "arrow-buffer", + "arrow-schema", + "half", + "num", +] + +[[package]] +name = "arrow-ipc" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a42ea853130f7e78b9b9d178cb4cd01dee0f78e64d96c2949dc0a915d6d9e19d" +dependencies = [ + "arrow-array", + "arrow-buffer", + "arrow-cast", + "arrow-data", + "arrow-schema", + "flatbuffers", +] + +[[package]] +name = "arrow-json" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eaafb5714d4e59feae964714d724f880511500e3569cc2a94d02456b403a2a49" +dependencies = [ + "arrow-array", + "arrow-buffer", + "arrow-cast", + "arrow-data", + "arrow-schema", + "chrono", + "half", + "indexmap 2.3.0", + "lexical-core", + "num", + "serde", + "serde_json", +] + +[[package]] +name = "arrow-ord" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3e6b61e3dc468f503181dccc2fc705bdcc5f2f146755fa5b56d0a6c5943f412" +dependencies = [ + "arrow-array", + "arrow-buffer", + "arrow-data", + "arrow-schema", + "arrow-select", + "half", + "num", +] + +[[package]] +name = "arrow-row" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "848ee52bb92eb459b811fb471175ea3afcf620157674c8794f539838920f9228" +dependencies = [ + "ahash", + "arrow-array", + "arrow-buffer", + "arrow-data", + "arrow-schema", + "half", + "hashbrown 0.14.5", +] + +[[package]] +name = "arrow-schema" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02d9483aaabe910c4781153ae1b6ae0393f72d9ef757d38d09d450070cf2e528" + +[[package]] +name = "arrow-select" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "849524fa70e0e3c5ab58394c770cb8f514d0122d20de08475f7b472ed8075830" +dependencies = [ + "ahash", + "arrow-array", + "arrow-buffer", + "arrow-data", + "arrow-schema", + "num", +] + +[[package]] +name = "arrow-string" +version = "51.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9373cb5a021aee58863498c37eb484998ef13377f69989c6c5ccfbd258236cdb" +dependencies = [ + "arrow-array", + "arrow-buffer", + "arrow-data", + "arrow-schema", + "arrow-select", + "memchr", + "num", + "regex", + "regex-syntax 0.8.4", +] + +[[package]] +name = "arrowbatch" +version = "1.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e304bae8e33446c64842dba444042ce65cb23e2b1e439fa2f4abb7591db562c5" +dependencies = [ + "arrow", + "base64 0.22.1", + "chrono", + "env_logger", + "futures", + "futures-util", + "hex", + "log", + "moka", + "num", + "num-bigint", + "rlp", + "serde", + "serde_json", + "tokio", + "tokio-tungstenite 0.21.0", + "tungstenite 0.21.0", + "uuid", + "zstd", +] + [[package]] name = "asn1_der" version = "0.7.6" @@ -980,9 +1325,9 @@ dependencies = [ [[package]] name = "async-compression" -version = "0.4.12" +version = "0.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fec134f64e2bc57411226dfc4e52dec859ddfc7e711fc5e07b612584f000e4aa" +checksum = "cd066d0b4ef8ecb03a55319dc13aa6910616d0f44008a045bb1835af830abff5" dependencies = [ "brotli", "flate2", @@ -1052,6 +1397,15 @@ dependencies = [ "rustc_version 0.4.0", ] +[[package]] +name = "atoi" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f28d99ec8bfea296261ca1af174f24225171fea9664ba9003cbebee704810528" +dependencies = [ + "num-traits", +] + [[package]] name = "atomic-waker" version = "1.1.2" @@ -1085,6 +1439,33 @@ version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" +[[package]] +name = "aws-lc-rs" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ae74d9bd0a7530e8afd1770739ad34b36838829d6ad61818f9230f683f5ad77" +dependencies = [ + "aws-lc-sys", + "mirai-annotations", + "paste", + "zeroize", +] + +[[package]] +name = "aws-lc-sys" +version = "0.20.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f0e249228c6ad2d240c2dc94b714d711629d52bad946075d8e9b2f5391f0703" +dependencies = [ + "bindgen", + "cc", + "cmake", + "dunce", + "fs_extra", + "libc", + "paste", +] + [[package]] name = "backon" version = "0.4.4" @@ -1181,12 +1562,15 @@ dependencies = [ "itertools 0.12.1", "lazy_static", "lazycell", + "log", + "prettyplease", "proc-macro2", "quote", "regex", "rustc-hash 1.1.0", "shlex", "syn 2.0.72", + "which", ] [[package]] @@ -1438,6 +1822,56 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "bollard" +version = "0.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a063d51a634c7137ecd9f6390ec78e1c512e84c9ded80198ec7df3339a16a33" +dependencies = [ + "base64 0.22.1", + "bollard-stubs", + "bytes", + "futures-core", + "futures-util", + "hex", + "home", + "http 1.1.0", + "http-body-util", + "hyper 1.4.1", + "hyper-named-pipe", + "hyper-rustls", + "hyper-util", + "hyperlocal", + "log", + "pin-project-lite", + "rustls", + "rustls-native-certs", + "rustls-pemfile 2.1.3", + "rustls-pki-types", + "serde", + "serde_derive", + "serde_json", + "serde_repr", + "serde_urlencoded", + "thiserror", + "tokio", + "tokio-util", + "tower-service", + "url", + "winapi", +] + +[[package]] +name = "bollard-stubs" +version = "1.45.0-rc.26.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d7c5415e3a6bc6d3e99eff6268e488fd4ee25e7b28c10f08fa6760bd9de16e4" +dependencies = [ + "serde", + "serde_repr", + "serde_with", +] + [[package]] name = "boyer-moore-magiclen" version = "0.2.20" @@ -1746,6 +2180,15 @@ version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" +[[package]] +name = "cmake" +version = "0.1.51" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb1e43aa7fd152b1f968787f7dbcdeb306d1867ff373c69955211876c053f91a" +dependencies = [ + "cc", +] + [[package]] name = "coins-bip32" version = "0.11.1" @@ -1899,6 +2342,26 @@ version = "0.9.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" +[[package]] +name = "const-random" +version = "0.1.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87e00182fe74b066627d63b85fd550ac2998d4b0bd86bfed477a0ae4c7c71359" +dependencies = [ + "const-random-macro", +] + +[[package]] +name = "const-random-macro" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f9d839f2a20b0aee515dc581a6172f2321f96cab76c1a38a4c584a194955390e" +dependencies = [ + "getrandom 0.2.15", + "once_cell", + "tiny-keccak", +] + [[package]] name = "const_format" version = "0.2.32" @@ -2346,6 +2809,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f55bf8e7b65898637379c1b74eb1551107c8294ed26d855ceb9fd1a09cfc9bc0" dependencies = [ "const-oid", + "pem-rfc7468", "zeroize", ] @@ -2508,6 +2972,17 @@ dependencies = [ "syn 2.0.72", ] +[[package]] +name = "docker_credential" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "31951f49556e34d90ed28342e1df7e1cb7a229c4cab0aecc627b5d91edd41d07" +dependencies = [ + "base64 0.21.7", + "serde", + "serde_json", +] + [[package]] name = "doctest-file" version = "1.0.0" @@ -2587,7 +3062,7 @@ dependencies = [ "reth-db", "reth-db-api", "reth-evm-ethereum", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-stages", "serde", @@ -2614,6 +3089,8 @@ dependencies = [ "ff", "generic-array", "group", + "hkdf", + "pem-rfc7468", "pkcs8", "rand_core 0.6.4", "sec1", @@ -2627,6 +3104,15 @@ version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a357d28ed41a50f9c765dbfe56cbc04a64e53e5fc58ba79fbc34c10ef3df831f" +[[package]] +name = "encoding_rs" +version = "0.8.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" +dependencies = [ + "cfg-if", +] + [[package]] name = "endian-type" version = "0.1.2" @@ -2676,6 +3162,19 @@ dependencies = [ "syn 2.0.72", ] +[[package]] +name = "env_logger" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4cd405aab171cb85d6735e5c8d9db038c17d3ca007a4d2c25f337935c3d90580" +dependencies = [ + "humantime", + "is-terminal", + "log", + "regex", + "termcolor", +] + [[package]] name = "equivalent" version = "1.0.1" @@ -2744,7 +3243,7 @@ dependencies = [ "clap", "eyre", "futures-util", - "reqwest", + "reqwest 0.12.5", "reth", "reth-node-ethereum", "serde", @@ -2775,7 +3274,7 @@ dependencies = [ "reth-network", "reth-network-api", "reth-network-peers", - "reth-primitives", + "reth-primitives 1.0.5", "reth-tracing", "secp256k1", "serde_json", @@ -2793,7 +3292,7 @@ dependencies = [ "reth-chainspec", "reth-node-core", "reth-node-ethereum", - "reth-primitives", + "reth-primitives 1.0.5", "serde_json", "tokio", ] @@ -2812,8 +3311,8 @@ dependencies = [ "reth-node-core", "reth-node-ethereum", "reth-payload-builder", - "reth-primitives", - "reth-rpc-types", + "reth-primitives 1.0.5", + "reth-rpc-types 1.0.5", "reth-tracing", "serde", "thiserror", @@ -2832,7 +3331,7 @@ dependencies = [ "reth-node-api", "reth-node-core", "reth-node-ethereum", - "reth-primitives", + "reth-primitives 1.0.5", "reth-tracing", "tokio", ] @@ -2845,7 +3344,7 @@ dependencies = [ "futures-util", "reth", "reth-node-ethereum", - "reth-rpc-types", + "reth-rpc-types 1.0.5", ] [[package]] @@ -2872,7 +3371,7 @@ dependencies = [ "reth-node-api", "reth-node-ethereum", "reth-payload-builder", - "reth-primitives", + "reth-primitives 1.0.5", "tracing", ] @@ -2888,9 +3387,9 @@ dependencies = [ "reth-network", "reth-network-api", "reth-node-ethereum", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "tokio", "tokio-stream", "tracing", @@ -2903,9 +3402,9 @@ dependencies = [ "eyre", "reth-chainspec", "reth-db", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", - "reth-rpc-types", + "reth-rpc-types 1.0.5", ] [[package]] @@ -2920,7 +3419,7 @@ dependencies = [ "reth-eth-wire", "reth-network", "reth-network-peers", - "reth-primitives", + "reth-primitives 1.0.5", "secp256k1", "tokio", ] @@ -2974,7 +3473,7 @@ dependencies = [ "reth-chainspec", "reth-discv4", "reth-network", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-tracing", "secp256k1", @@ -3011,7 +3510,7 @@ dependencies = [ "reth-node-api", "reth-node-core", "reth-node-ethereum", - "reth-primitives", + "reth-primitives 1.0.5", "reth-tracing", "schnellru", "tokio", @@ -3121,6 +3620,16 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "flatbuffers" +version = "23.5.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4dac53e22462d78c16d64a1cd22371b54cc3fe94aa15e7886a2fa6e5d1ab8640" +dependencies = [ + "bitflags 1.3.2", + "rustc_version 0.4.0", +] + [[package]] name = "flate2" version = "1.0.31" @@ -3137,6 +3646,21 @@ version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + [[package]] name = "form_urlencoded" version = "1.2.1" @@ -3152,6 +3676,12 @@ version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c2141d6d6c8512188a7891b4b01590a45f6dac67afb4f255c4124dbb86d4eaa" +[[package]] +name = "fs_extra" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42703706b716c37f96a77aea830392ad231f44c9e9a67872fa5548707e11b11c" + [[package]] name = "funty" version = "2.0.0" @@ -3346,7 +3876,7 @@ dependencies = [ "futures-core", "futures-sink", "gloo-utils", - "http", + "http 1.1.0", "js-sys", "pin-project", "serde", @@ -3393,6 +3923,25 @@ dependencies = [ "subtle", ] +[[package]] +name = "h2" +version = "0.3.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81fe527a889e1532da5c525686d96d4c2e74cdd345badf8dfef9f6b39dd5f5e8" +dependencies = [ + "bytes", + "fnv", + "futures-core", + "futures-sink", + "futures-util", + "http 0.2.12", + "indexmap 2.3.0", + "slab", + "tokio", + "tokio-util", + "tracing", +] + [[package]] name = "h2" version = "0.4.5" @@ -3404,7 +3953,7 @@ dependencies = [ "fnv", "futures-core", "futures-sink", - "http", + "http 1.1.0", "indexmap 2.3.0", "slab", "tokio", @@ -3420,6 +3969,7 @@ checksum = "6dd08c532ae367adf81c312a4580bc67f1d0fe8bc9c460520283f4c0ff277888" dependencies = [ "cfg-if", "crunchy", + "num-traits", ] [[package]] @@ -3542,6 +4092,15 @@ dependencies = [ "hmac 0.8.1", ] +[[package]] +name = "home" +version = "0.5.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3d1354bf6b7235cb4a0576c2619fd4ed18183f689b12b006a0ee7329eeff9a5" +dependencies = [ + "windows-sys 0.52.0", +] + [[package]] name = "hostname" version = "0.3.1" @@ -3553,6 +4112,17 @@ dependencies = [ "winapi", ] +[[package]] +name = "http" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "601cbb57e577e2f5ef5be8e7b83f0f63994f25aa94d673e54a92d5c516d101f1" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + [[package]] name = "http" version = "1.1.0" @@ -3564,6 +4134,17 @@ dependencies = [ "itoa", ] +[[package]] +name = "http-body" +version = "0.4.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ceab25649e9960c0311ea418d17bee82c0dcec1bd053b5f9a66e265a693bed2" +dependencies = [ + "bytes", + "http 0.2.12", + "pin-project-lite", +] + [[package]] name = "http-body" version = "1.0.1" @@ -3571,7 +4152,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" dependencies = [ "bytes", - "http", + "http 1.1.0", ] [[package]] @@ -3582,8 +4163,8 @@ checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" dependencies = [ "bytes", "futures-util", - "http", - "http-body", + "http 1.1.0", + "http-body 1.0.1", "pin-project-lite", ] @@ -3647,6 +4228,30 @@ dependencies = [ "serde", ] +[[package]] +name = "hyper" +version = "0.14.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a152ddd61dfaec7273fe8419ab357f33aee0d914c5f4efbf0d96fa749eea5ec9" +dependencies = [ + "bytes", + "futures-channel", + "futures-core", + "futures-util", + "h2 0.3.26", + "http 0.2.12", + "http-body 0.4.6", + "httparse", + "httpdate", + "itoa", + "pin-project-lite", + "socket2 0.4.10", + "tokio", + "tower-service", + "tracing", + "want", +] + [[package]] name = "hyper" version = "1.4.1" @@ -3656,9 +4261,9 @@ dependencies = [ "bytes", "futures-channel", "futures-util", - "h2", - "http", - "http-body", + "h2 0.4.5", + "http 1.1.0", + "http-body 1.0.1", "httparse", "httpdate", "itoa", @@ -3668,6 +4273,21 @@ dependencies = [ "want", ] +[[package]] +name = "hyper-named-pipe" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73b7d8abf35697b81a825e386fc151e0d503e8cb5fcb93cc8669c376dfd6f278" +dependencies = [ + "hex", + "hyper 1.4.1", + "hyper-util", + "pin-project-lite", + "tokio", + "tower-service", + "winapi", +] + [[package]] name = "hyper-rustls" version = "0.27.2" @@ -3675,8 +4295,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" dependencies = [ "futures-util", - "http", - "hyper", + "http 1.1.0", + "hyper 1.4.1", "hyper-util", "log", "rustls", @@ -3688,6 +4308,35 @@ dependencies = [ "webpki-roots", ] +[[package]] +name = "hyper-tls" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" +dependencies = [ + "bytes", + "hyper 0.14.30", + "native-tls", + "tokio", + "tokio-native-tls", +] + +[[package]] +name = "hyper-tls" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" +dependencies = [ + "bytes", + "http-body-util", + "hyper 1.4.1", + "hyper-util", + "native-tls", + "tokio", + "tokio-native-tls", + "tower-service", +] + [[package]] name = "hyper-util" version = "0.1.6" @@ -3697,9 +4346,9 @@ dependencies = [ "bytes", "futures-channel", "futures-util", - "http", - "http-body", - "hyper", + "http 1.1.0", + "http-body 1.0.1", + "hyper 1.4.1", "pin-project-lite", "socket2 0.5.7", "tokio", @@ -3708,6 +4357,21 @@ dependencies = [ "tracing", ] +[[package]] +name = "hyperlocal" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "986c5ce3b994526b3cd75578e62554abd09f0899d6206de48b3e96ab34ccc8c7" +dependencies = [ + "hex", + "http-body-util", + "hyper 1.4.1", + "hyper-util", + "pin-project-lite", + "tokio", + "tower-service", +] + [[package]] name = "iai-callgrind" version = "0.11.1" @@ -4203,7 +4867,7 @@ dependencies = [ "futures-channel", "futures-util", "gloo-net", - "http", + "http 1.1.0", "jsonrpsee-core", "pin-project", "rustls", @@ -4228,8 +4892,8 @@ dependencies = [ "bytes", "futures-timer", "futures-util", - "http", - "http-body", + "http 1.1.0", + "http-body 1.0.1", "http-body-util", "jsonrpsee-types", "parking_lot 0.12.3", @@ -4253,8 +4917,8 @@ checksum = "4d5f8f6ddb09312a9592ec9e21a3ccd6f61e51730d9d56321351eff971b0fe55" dependencies = [ "async-trait", "base64 0.22.1", - "http-body", - "hyper", + "http-body 1.0.1", + "hyper 1.4.1", "hyper-rustls", "hyper-util", "jsonrpsee-core", @@ -4290,10 +4954,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "85bf179199ad809157ceaab653f71cdb67f55d9e0093a6907c5765414a6b3bbb" dependencies = [ "futures-util", - "http", - "http-body", + "http 1.1.0", + "http-body 1.0.1", "http-body-util", - "hyper", + "hyper 1.4.1", "hyper-util", "jsonrpsee-core", "jsonrpsee-types", @@ -4316,7 +4980,7 @@ version = "0.24.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "98deeee954567f75632fa40666ac93a66d4f9f4ed4ca15bd6b7ed0720b53e761" dependencies = [ - "http", + "http 1.1.0", "serde", "serde_json", "thiserror", @@ -4339,7 +5003,7 @@ version = "0.24.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "385cf0a6103a9f64987cdf0f7c9d0b08e1d7183dd952820beffb3676e7df7787" dependencies = [ - "http", + "http 1.1.0", "jsonrpsee-client-transport", "jsonrpsee-core", "jsonrpsee-types", @@ -4410,34 +5074,98 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a4933f3f57a8e9d9da04db23fb153356ecaf00cbd14aee46279c33dc80925c37" [[package]] -name = "kzg-rs" -version = "0.1.0" +name = "kzg-rs" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd9920cd4460ce3cbca19c62f3bb9a9611562478a4dc9d2c556f4a7d049c5b6b" +dependencies = [ + "bls12_381", + "glob", + "hex", + "once_cell", + "serde", + "serde_derive", + "serde_yaml", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" +dependencies = [ + "spin", +] + +[[package]] +name = "lazycell" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" + +[[package]] +name = "lexical-core" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2cde5de06e8d4c2faabc400238f9ae1c74d5412d03a7bd067645ccbc47070e46" +dependencies = [ + "lexical-parse-float", + "lexical-parse-integer", + "lexical-util", + "lexical-write-float", + "lexical-write-integer", +] + +[[package]] +name = "lexical-parse-float" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "683b3a5ebd0130b8fb52ba0bdc718cc56815b6a097e28ae5a6997d0ad17dc05f" +dependencies = [ + "lexical-parse-integer", + "lexical-util", + "static_assertions", +] + +[[package]] +name = "lexical-parse-integer" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d0994485ed0c312f6d965766754ea177d07f9c00c9b82a5ee62ed5b47945ee9" +dependencies = [ + "lexical-util", + "static_assertions", +] + +[[package]] +name = "lexical-util" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd9920cd4460ce3cbca19c62f3bb9a9611562478a4dc9d2c556f4a7d049c5b6b" +checksum = "5255b9ff16ff898710eb9eb63cb39248ea8a5bb036bea8085b1a767ff6c4e3fc" dependencies = [ - "bls12_381", - "glob", - "hex", - "once_cell", - "serde", - "serde_derive", - "serde_yaml", + "static_assertions", ] [[package]] -name = "lazy_static" -version = "1.5.0" +name = "lexical-write-float" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" +checksum = "accabaa1c4581f05a3923d1b4cfd124c329352288b7b9da09e766b0668116862" dependencies = [ - "spin", + "lexical-util", + "lexical-write-integer", + "static_assertions", ] [[package]] -name = "lazycell" -version = "1.3.0" +name = "lexical-write-integer" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" +checksum = "e1b6f3d1f4422866b68192d62f77bc5c700bee84f3069f2469d7bc8c77852446" +dependencies = [ + "lexical-util", + "static_assertions", +] [[package]] name = "libc" @@ -4452,7 +5180,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4979f22fdb869068da03c9f7528f8297c6fd2606bc3a4affe42e6a823fdb8da4" dependencies = [ "cfg-if", - "windows-targets 0.48.5", + "windows-targets 0.52.6", ] [[package]] @@ -4832,7 +5560,7 @@ dependencies = [ "futures-util", "http-types", "pin-project-lite", - "reqwest", + "reqwest 0.12.5", "serde", "serde_json", "thiserror", @@ -4895,6 +5623,12 @@ dependencies = [ "windows-sys 0.52.0", ] +[[package]] +name = "mirai-annotations" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c9be0862c1b3f26a88803c4a49de6889c10e608b3ee9344e6ef5b45fb37ad3d1" + [[package]] name = "mockall" version = "0.12.1" @@ -4943,6 +5677,26 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "moka" +version = "0.12.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32cf62eb4dd975d2dde76432fb1075c49e3ee2331cf36f1f8fd4b66550d32b6f" +dependencies = [ + "crossbeam-channel", + "crossbeam-epoch", + "crossbeam-utils", + "once_cell", + "parking_lot 0.12.3", + "quanta", + "rustc_version 0.4.0", + "smallvec", + "tagptr", + "thiserror", + "triomphe", + "uuid", +] + [[package]] name = "more-asserts" version = "0.3.1" @@ -5003,6 +5757,23 @@ dependencies = [ "unsigned-varint 0.7.2", ] +[[package]] +name = "native-tls" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + [[package]] name = "nibble_vec" version = "0.1.0" @@ -5254,12 +6025,50 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" +[[package]] +name = "openssl" +version = "0.10.66" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9529f4786b70a3e8c61e11179af17ab6188ad8d0ded78c5529441ed39d4bd9c1" +dependencies = [ + "bitflags 2.6.0", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.72", +] + [[package]] name = "openssl-probe" version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" +[[package]] +name = "openssl-sys" +version = "0.9.103" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f9e8deee91df40a943c71b917e5874b951d32a802526c85721ce3b776c929d6" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + [[package]] name = "option-ext" version = "0.2.0" @@ -5393,6 +6202,31 @@ dependencies = [ "windows-targets 0.52.6", ] +[[package]] +name = "parse-display" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "914a1c2265c98e2446911282c6ac86d8524f495792c38c5bd884f80499c7538a" +dependencies = [ + "parse-display-derive", + "regex", + "regex-syntax 0.8.4", +] + +[[package]] +name = "parse-display-derive" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ae7800a4c974efd12df917266338e79a7a74415173caf7e70aa0a0707345281" +dependencies = [ + "proc-macro2", + "quote", + "regex", + "regex-syntax 0.8.4", + "structmeta", + "syn 2.0.72", +] + [[package]] name = "paste" version = "1.0.15" @@ -5419,6 +6253,15 @@ dependencies = [ "serde", ] +[[package]] +name = "pem-rfc7468" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88b39c9bfcfc231068454382784bb460aae594343fb030d46e9f50a645418412" +dependencies = [ + "base64ct", +] + [[package]] name = "percent-encoding" version = "2.3.1" @@ -6156,6 +6999,46 @@ dependencies = [ "memchr", ] +[[package]] +name = "reqwest" +version = "0.11.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd67538700a17451e7cba03ac727fb961abb7607553461627b97de0b89cf4a62" +dependencies = [ + "base64 0.21.7", + "bytes", + "encoding_rs", + "futures-core", + "futures-util", + "h2 0.3.26", + "http 0.2.12", + "http-body 0.4.6", + "hyper 0.14.30", + "hyper-tls 0.5.0", + "ipnet", + "js-sys", + "log", + "mime", + "native-tls", + "once_cell", + "percent-encoding", + "pin-project-lite", + "rustls-pemfile 1.0.4", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper 0.1.2", + "system-configuration", + "tokio", + "tokio-native-tls", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "winreg 0.50.0", +] + [[package]] name = "reqwest" version = "0.12.5" @@ -6166,29 +7049,32 @@ dependencies = [ "bytes", "futures-core", "futures-util", - "http", - "http-body", + "http 1.1.0", + "http-body 1.0.1", "http-body-util", - "hyper", + "hyper 1.4.1", "hyper-rustls", + "hyper-tls 0.6.0", "hyper-util", "ipnet", "js-sys", "log", "mime", + "native-tls", "once_cell", "percent-encoding", "pin-project-lite", "quinn", "rustls", "rustls-native-certs", - "rustls-pemfile", + "rustls-pemfile 2.1.3", "rustls-pki-types", "serde", "serde_json", "serde_urlencoded", - "sync_wrapper", + "sync_wrapper 1.0.1", "tokio", + "tokio-native-tls", "tokio-rustls", "tokio-util", "tower-service", @@ -6259,12 +7145,13 @@ dependencies = [ "reth-node-events", "reth-node-metrics", "reth-node-optimism", + "reth-node-telos", "reth-optimism-cli", "reth-optimism-primitives", "reth-payload-builder", "reth-payload-primitives", "reth-payload-validator", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune", "reth-revm", @@ -6273,13 +7160,14 @@ dependencies = [ "reth-rpc-builder", "reth-rpc-eth-types", "reth-rpc-server-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-stages", "reth-stages-api", "reth-static-file", - "reth-static-file-types", + "reth-static-file-types 1.0.5", "reth-tasks", + "reth-telos-rpc", "reth-tracing", "reth-transaction-pool", "reth-trie", @@ -6308,10 +7196,10 @@ dependencies = [ "reth-execution-types", "reth-network-p2p", "reth-network-peers", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-revm", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-stages-api", "reth-tokio-util", "reth-transaction-pool", @@ -6332,7 +7220,7 @@ dependencies = [ "reth-metrics", "reth-payload-builder", "reth-payload-primitives", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-revm", "reth-tasks", @@ -6371,11 +7259,11 @@ dependencies = [ "reth-payload-builder", "reth-payload-primitives", "reth-payload-validator", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune", "reth-prune-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-stages", "reth-stages-api", @@ -6412,14 +7300,14 @@ dependencies = [ "eyre", "futures", "libc", - "reqwest", + "reqwest 0.12.5", "reth-cli-runner", "reth-db", "reth-node-api", "reth-node-core", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-tracing", "serde", @@ -6453,7 +7341,7 @@ dependencies = [ "reth-execution-types", "reth-metrics", "reth-network", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune-types", "reth-revm", @@ -6473,7 +7361,7 @@ version = "1.0.5" dependencies = [ "reth-consensus", "reth-execution-errors", - "reth-primitives", + "reth-primitives 1.0.5", "reth-storage-errors", "thiserror", ] @@ -6494,7 +7382,7 @@ dependencies = [ "reth-errors", "reth-execution-types", "reth-metrics", - "reth-primitives", + "reth-primitives 1.0.5", "reth-storage-api", "reth-trie", "revm", @@ -6517,10 +7405,10 @@ dependencies = [ "derive_more", "once_cell", "op-alloy-rpc-types", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-network-peers", - "reth-primitives-traits", - "reth-trie-common", + "reth-primitives-traits 1.0.5", + "reth-trie-common 1.0.5", "serde", "serde_json", ] @@ -6577,12 +7465,12 @@ dependencies = [ "reth-node-core", "reth-node-events", "reth-node-metrics", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune", "reth-stages", "reth-static-file", - "reth-static-file-types", + "reth-static-file-types 1.0.5", "reth-trie", "reth-trie-db", "secp256k1", @@ -6630,12 +7518,28 @@ dependencies = [ "modular-bitfield", "proptest", "proptest-arbitrary-interop", - "reth-codecs-derive", + "reth-codecs-derive 1.0.5", "serde", "serde_json", "test-fuzz", ] +[[package]] +name = "reth-codecs" +version = "1.0.5" +source = "git+https://github.com/telosnetwork/telos-reth?branch=telos-main#15f441221100c585045cad7043b89c751ac9323f" +dependencies = [ + "alloy-consensus", + "alloy-eips", + "alloy-genesis", + "alloy-primitives", + "alloy-trie", + "bytes", + "modular-bitfield", + "reth-codecs-derive 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "serde", +] + [[package]] name = "reth-codecs-derive" version = "1.0.5" @@ -6647,6 +7551,17 @@ dependencies = [ "syn 2.0.72", ] +[[package]] +name = "reth-codecs-derive" +version = "1.0.5" +source = "git+https://github.com/telosnetwork/telos-reth?branch=telos-main#15f441221100c585045cad7043b89c751ac9323f" +dependencies = [ + "convert_case 0.6.0", + "proc-macro2", + "quote", + "syn 2.0.72", +] + [[package]] name = "reth-config" version = "1.0.5" @@ -6667,7 +7582,7 @@ name = "reth-consensus" version = "1.0.5" dependencies = [ "auto_impl", - "reth-primitives", + "reth-primitives 1.0.5", "thiserror-no-std", ] @@ -6679,7 +7594,7 @@ dependencies = [ "rand 0.8.5", "reth-chainspec", "reth-consensus", - "reth-primitives", + "reth-primitives 1.0.5", "reth-storage-api", ] @@ -6693,12 +7608,12 @@ dependencies = [ "auto_impl", "eyre", "futures", - "reqwest", + "reqwest 0.12.5", "reth-node-api", "reth-node-core", "reth-rpc-api", "reth-rpc-builder", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-tracing", "ringbuffer", "serde", @@ -6727,13 +7642,13 @@ dependencies = [ "reth-libmdbx", "reth-metrics", "reth-nippy-jar", - "reth-primitives", - "reth-primitives-traits", + "reth-primitives 1.0.5", + "reth-primitives-traits 1.0.5", "reth-prune-types", "reth-stages-types", "reth-storage-errors", "reth-tracing", - "reth-trie-common", + "reth-trie-common 1.0.5", "rustc-hash 2.0.0", "serde", "serde_json", @@ -6761,13 +7676,13 @@ dependencies = [ "proptest", "proptest-arbitrary-interop", "rand 0.8.5", - "reth-codecs", - "reth-primitives", - "reth-primitives-traits", + "reth-codecs 1.0.5", + "reth-primitives 1.0.5", + "reth-primitives-traits 1.0.5", "reth-prune-types", "reth-stages-types", "reth-storage-errors", - "reth-trie-common", + "reth-trie-common 1.0.5", "serde", "test-fuzz", ] @@ -6780,14 +7695,14 @@ dependencies = [ "boyer-moore-magiclen", "eyre", "reth-chainspec", - "reth-codecs", + "reth-codecs 1.0.5", "reth-config", "reth-db", "reth-db-api", "reth-etl", "reth-fs-util", - "reth-primitives", - "reth-primitives-traits", + "reth-primitives 1.0.5", + "reth-primitives-traits 1.0.5", "reth-provider", "reth-stages-types", "reth-trie", @@ -6810,7 +7725,7 @@ dependencies = [ "generic-array", "parking_lot 0.12.3", "rand 0.8.5", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-net-banlist", "reth-net-nat", "reth-network-peers", @@ -6840,7 +7755,7 @@ dependencies = [ "multiaddr", "rand 0.8.5", "reth-chainspec", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-metrics", "reth-network-peers", "reth-tracing", @@ -6863,7 +7778,7 @@ dependencies = [ "parking_lot 0.12.3", "rand 0.8.5", "reth-chainspec", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-network-peers", "reth-tokio-util", "reth-tracing", @@ -6899,7 +7814,7 @@ dependencies = [ "reth-metrics", "reth-network-p2p", "reth-network-peers", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-storage-api", "reth-tasks", @@ -6932,7 +7847,7 @@ dependencies = [ "reth-node-builder", "reth-node-ethereum", "reth-payload-builder", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-rpc", "reth-rpc-layer", @@ -7004,7 +7919,7 @@ dependencies = [ "reth-network-p2p", "reth-payload-builder", "reth-payload-validator", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune", "reth-prune-types", @@ -7042,12 +7957,12 @@ dependencies = [ "reth-payload-builder", "reth-payload-primitives", "reth-payload-validator", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune", "reth-prune-types", "reth-revm", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-stages", "reth-stages-api", @@ -7071,14 +7986,14 @@ dependencies = [ "reth-beacon-consensus", "reth-engine-primitives", "reth-errors", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-evm", "reth-fs-util", "reth-payload-validator", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-revm", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "revm-primitives", "serde", @@ -7115,12 +8030,12 @@ dependencies = [ "proptest-arbitrary-interop", "rand 0.8.5", "reth-chainspec", - "reth-codecs", + "reth-codecs 1.0.5", "reth-ecies", "reth-eth-wire-types", "reth-metrics", "reth-network-peers", - "reth-primitives", + "reth-primitives 1.0.5", "reth-tracing", "secp256k1", "serde", @@ -7147,8 +8062,8 @@ dependencies = [ "proptest-arbitrary-interop", "rand 0.8.5", "reth-chainspec", - "reth-codecs-derive", - "reth-primitives", + "reth-codecs-derive 1.0.5", + "reth-primitives 1.0.5", "serde", "thiserror", ] @@ -7173,7 +8088,7 @@ dependencies = [ "reth-chainspec", "reth-consensus", "reth-consensus-common", - "reth-primitives", + "reth-primitives 1.0.5", "tracing", ] @@ -7186,8 +8101,8 @@ dependencies = [ "reth-engine-primitives", "reth-evm-ethereum", "reth-payload-primitives", - "reth-primitives", - "reth-rpc-types", + "reth-primitives 1.0.5", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "revm-primitives", "serde", @@ -7214,6 +8129,23 @@ dependencies = [ "thiserror-no-std", ] +[[package]] +name = "reth-ethereum-forks" +version = "1.0.5" +source = "git+https://github.com/telosnetwork/telos-reth?branch=telos-main#15f441221100c585045cad7043b89c751ac9323f" +dependencies = [ + "alloy-chains", + "alloy-primitives", + "alloy-rlp", + "auto_impl", + "crc", + "dyn-clone", + "once_cell", + "rustc-hash 2.0.0", + "serde", + "thiserror-no-std", +] + [[package]] name = "reth-ethereum-payload-builder" version = "1.0.5" @@ -7224,7 +8156,7 @@ dependencies = [ "reth-evm-ethereum", "reth-execution-types", "reth-payload-builder", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-revm", "reth-transaction-pool", @@ -7253,7 +8185,7 @@ dependencies = [ "reth-chainspec", "reth-execution-errors", "reth-execution-types", - "reth-primitives", + "reth-primitives 1.0.5", "reth-prune-types", "reth-storage-errors", "revm", @@ -7268,10 +8200,10 @@ dependencies = [ "alloy-sol-types", "reth-chainspec", "reth-ethereum-consensus", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-evm", "reth-execution-types", - "reth-primitives", + "reth-primitives 1.0.5", "reth-prune-types", "reth-revm", "reth-testing-utils", @@ -7285,12 +8217,12 @@ name = "reth-evm-optimism" version = "1.0.5" dependencies = [ "reth-chainspec", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-evm", "reth-execution-errors", "reth-execution-types", "reth-optimism-consensus", - "reth-primitives", + "reth-primitives 1.0.5", "reth-prune-types", "reth-revm", "revm", @@ -7322,7 +8254,7 @@ dependencies = [ "alloy-primitives", "reth-chainspec", "reth-execution-errors", - "reth-primitives", + "reth-primitives 1.0.5", "reth-trie", "revm", "serde", @@ -7347,8 +8279,8 @@ dependencies = [ "reth-node-api", "reth-node-core", "reth-payload-builder", - "reth-primitives", - "reth-primitives-traits", + "reth-primitives 1.0.5", + "reth-primitives-traits 1.0.5", "reth-provider", "reth-prune-types", "reth-revm", @@ -7383,7 +8315,7 @@ dependencies = [ "reth-node-core", "reth-node-ethereum", "reth-payload-builder", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-tasks", "reth-transaction-pool", @@ -7495,7 +8427,7 @@ name = "reth-net-nat" version = "1.0.5" dependencies = [ "futures-util", - "reqwest", + "reqwest 0.12.5", "reth-tracing", "serde_with", "thiserror", @@ -7537,7 +8469,7 @@ dependencies = [ "reth-network-p2p", "reth-network-peers", "reth-network-types", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-storage-api", "reth-tasks", @@ -7570,7 +8502,7 @@ dependencies = [ "enr", "futures", "reth-eth-wire-types", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-network-p2p", "reth-network-peers", "reth-network-types", @@ -7591,7 +8523,7 @@ dependencies = [ "reth-consensus", "reth-eth-wire-types", "reth-network-peers", - "reth-primitives", + "reth-primitives 1.0.5", "reth-storage-errors", "serde", "thiserror", @@ -7620,7 +8552,7 @@ name = "reth-network-types" version = "1.0.5" dependencies = [ "humantime-serde", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-net-banlist", "reth-network-p2p", "reth-network-peers", @@ -7701,7 +8633,7 @@ dependencies = [ "reth-node-metrics", "reth-payload-builder", "reth-payload-validator", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune", "reth-rpc", @@ -7709,7 +8641,7 @@ dependencies = [ "reth-rpc-engine-api", "reth-rpc-eth-types", "reth-rpc-layer", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-stages", "reth-static-file", "reth-tasks", @@ -7751,14 +8683,14 @@ dependencies = [ "reth-network", "reth-network-p2p", "reth-network-peers", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune-types", "reth-rpc-api", "reth-rpc-eth-api", "reth-rpc-eth-types", "reth-rpc-server-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-stages-types", "reth-storage-errors", @@ -7819,8 +8751,8 @@ dependencies = [ "reth-db-api", "reth-network", "reth-network-api", - "reth-primitives", - "reth-primitives-traits", + "reth-primitives 1.0.5", + "reth-primitives-traits 1.0.5", "reth-provider", "reth-prune", "reth-stages", @@ -7834,14 +8766,14 @@ name = "reth-node-metrics" version = "1.0.5" dependencies = [ "eyre", - "http", + "http 1.1.0", "jsonrpsee", "metrics", "metrics-exporter-prometheus", "metrics-process", "metrics-util", "procfs", - "reqwest", + "reqwest 0.12.5", "reth-chainspec", "reth-db", "reth-db-api", @@ -7868,7 +8800,7 @@ dependencies = [ "jsonrpsee", "jsonrpsee-types", "parking_lot 0.12.3", - "reqwest", + "reqwest 0.12.5", "reth", "reth-auto-seal-consensus", "reth-basic-payload-builder", @@ -7887,12 +8819,12 @@ dependencies = [ "reth-optimism-payload-builder", "reth-optimism-rpc", "reth-payload-builder", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-revm", "reth-rpc-eth-api", "reth-rpc-eth-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-tracing", "reth-transaction-pool", @@ -7903,6 +8835,41 @@ dependencies = [ "tracing", ] +[[package]] +name = "reth-node-telos" +version = "1.0.5" +dependencies = [ + "antelope-client 0.2.1 (git+https://github.com/telosnetwork/antelope-rs?branch=finish_table_rows_params)", + "clap", + "eyre", + "reth", + "reth-auto-seal-consensus", + "reth-basic-payload-builder", + "reth-beacon-consensus", + "reth-chainspec", + "reth-e2e-test-utils", + "reth-ethereum-engine-primitives", + "reth-evm-ethereum", + "reth-network", + "reth-node-api", + "reth-node-builder", + "reth-node-ethereum", + "reth-payload-builder", + "reth-primitives 1.0.5", + "reth-provider", + "reth-rpc", + "reth-stages", + "reth-tracing", + "reth-transaction-pool", + "serde", + "serde_json", + "telos-consensus-client", + "testcontainers", + "tokio", + "tracing", + "tracing-subscriber", +] + [[package]] name = "reth-optimism-cli" version = "1.0.5" @@ -7929,13 +8896,13 @@ dependencies = [ "reth-node-core", "reth-node-events", "reth-optimism-primitives", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-prune", "reth-stages", "reth-stages-types", "reth-static-file", - "reth-static-file-types", + "reth-static-file-types 1.0.5", "serde_json", "shellexpand", "tempfile", @@ -7951,7 +8918,7 @@ dependencies = [ "reth-chainspec", "reth-consensus", "reth-consensus-common", - "reth-primitives", + "reth-primitives 1.0.5", "tracing", ] @@ -7968,10 +8935,10 @@ dependencies = [ "reth-execution-types", "reth-payload-builder", "reth-payload-primitives", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-revm", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-transaction-pool", "reth-trie", @@ -7998,13 +8965,13 @@ dependencies = [ "reth-evm-optimism", "reth-network-api", "reth-node-api", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-rpc", "reth-rpc-eth-api", "reth-rpc-eth-types", "reth-rpc-server-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-tasks", "reth-transaction-pool", "revm", @@ -8025,9 +8992,9 @@ dependencies = [ "reth-ethereum-engine-primitives", "reth-metrics", "reth-payload-primitives", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-transaction-pool", "revm", "thiserror", @@ -8043,8 +9010,8 @@ dependencies = [ "reth-chain-state", "reth-chainspec", "reth-errors", - "reth-primitives", - "reth-rpc-types", + "reth-primitives 1.0.5", + "reth-rpc-types 1.0.5", "reth-transaction-pool", "serde", "thiserror", @@ -8056,8 +9023,8 @@ name = "reth-payload-validator" version = "1.0.5" dependencies = [ "reth-chainspec", - "reth-primitives", - "reth-rpc-types", + "reth-primitives 1.0.5", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", ] @@ -8085,11 +9052,11 @@ dependencies = [ "rand 0.8.5", "rayon", "reth-chainspec", - "reth-codecs", - "reth-ethereum-forks", - "reth-primitives-traits", - "reth-static-file-types", - "reth-trie-common", + "reth-codecs 1.0.5", + "reth-ethereum-forks 1.0.5", + "reth-primitives-traits 1.0.5", + "reth-static-file-types 1.0.5", + "reth-trie-common 1.0.5", "revm-primitives", "secp256k1", "serde", @@ -8100,6 +9067,36 @@ dependencies = [ "zstd", ] +[[package]] +name = "reth-primitives" +version = "1.0.5" +source = "git+https://github.com/telosnetwork/telos-reth?branch=telos-main#15f441221100c585045cad7043b89c751ac9323f" +dependencies = [ + "alloy-eips", + "alloy-genesis", + "alloy-primitives", + "alloy-rlp", + "alloy-rpc-types", + "bytes", + "c-kzg", + "derive_more", + "k256", + "modular-bitfield", + "once_cell", + "rayon", + "reth-codecs 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "reth-ethereum-forks 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "reth-primitives-traits 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "reth-static-file-types 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "reth-trie-common 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "revm-primitives", + "secp256k1", + "serde", + "tempfile", + "thiserror", + "zstd", +] + [[package]] name = "reth-primitives-traits" version = "1.0.5" @@ -8118,12 +9115,33 @@ dependencies = [ "proptest", "proptest-arbitrary-interop", "rand 0.8.5", - "reth-codecs", + "reth-codecs 1.0.5", + "revm-primitives", + "roaring", + "serde", + "serde_json", + "test-fuzz", +] + +[[package]] +name = "reth-primitives-traits" +version = "1.0.5" +source = "git+https://github.com/telosnetwork/telos-reth?branch=telos-main#15f441221100c585045cad7043b89c751ac9323f" +dependencies = [ + "alloy-consensus", + "alloy-eips", + "alloy-genesis", + "alloy-primitives", + "alloy-rlp", + "alloy-rpc-types-eth", + "byteorder", + "bytes", + "derive_more", + "modular-bitfield", + "reth-codecs 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", "revm-primitives", "roaring", "serde", - "serde_json", - "test-fuzz", ] [[package]] @@ -8143,7 +9161,7 @@ dependencies = [ "reth-blockchain-tree-api", "reth-chain-state", "reth-chainspec", - "reth-codecs", + "reth-codecs 1.0.5", "reth-db", "reth-db-api", "reth-errors", @@ -8153,7 +9171,7 @@ dependencies = [ "reth-metrics", "reth-network-p2p", "reth-nippy-jar", - "reth-primitives", + "reth-primitives 1.0.5", "reth-prune-types", "reth-stages-types", "reth-storage-api", @@ -8187,7 +9205,7 @@ dependencies = [ "reth-provider", "reth-prune-types", "reth-stages", - "reth-static-file-types", + "reth-static-file-types 1.0.5", "reth-testing-utils", "reth-tokio-util", "reth-tracing", @@ -8209,7 +9227,7 @@ dependencies = [ "modular-bitfield", "proptest", "proptest-arbitrary-interop", - "reth-codecs", + "reth-codecs 1.0.5", "serde", "serde_json", "test-fuzz", @@ -8224,9 +9242,9 @@ dependencies = [ "alloy-eips", "reth-chainspec", "reth-consensus-common", - "reth-ethereum-forks", + "reth-ethereum-forks 1.0.5", "reth-execution-errors", - "reth-primitives", + "reth-primitives 1.0.5", "reth-prune-types", "reth-storage-api", "reth-storage-errors", @@ -8245,9 +9263,9 @@ dependencies = [ "async-trait", "derive_more", "futures", - "http", - "http-body", - "hyper", + "http 1.1.0", + "http-body 1.0.1", + "hyper 1.4.1", "jsonrpsee", "jsonrpsee-types", "jsonwebtoken", @@ -8263,7 +9281,7 @@ dependencies = [ "reth-network-peers", "reth-network-types", "reth-node-api", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-revm", "reth-rpc-api", @@ -8271,7 +9289,7 @@ dependencies = [ "reth-rpc-eth-api", "reth-rpc-eth-types", "reth-rpc-server-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-tasks", "reth-testing-utils", @@ -8298,9 +9316,9 @@ dependencies = [ "jsonrpsee", "reth-engine-primitives", "reth-network-peers", - "reth-primitives", + "reth-primitives 1.0.5", "reth-rpc-eth-api", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "serde_json", ] @@ -8310,10 +9328,10 @@ version = "1.0.5" dependencies = [ "futures", "jsonrpsee", - "reth-primitives", + "reth-primitives 1.0.5", "reth-rpc-api", "reth-rpc-eth-api", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "serde_json", "similar-asserts", "tokio", @@ -8324,7 +9342,7 @@ name = "reth-rpc-builder" version = "1.0.5" dependencies = [ "clap", - "http", + "http 1.1.0", "jsonrpsee", "metrics", "pin-project", @@ -8341,7 +9359,7 @@ dependencies = [ "reth-node-api", "reth-node-core", "reth-payload-builder", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-rpc", "reth-rpc-api", @@ -8350,7 +9368,7 @@ dependencies = [ "reth-rpc-eth-types", "reth-rpc-layer", "reth-rpc-server-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-tasks", "reth-tokio-util", @@ -8383,10 +9401,10 @@ dependencies = [ "reth-metrics", "reth-payload-builder", "reth-payload-primitives", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-rpc-api", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-storage-api", "reth-tasks", @@ -8415,12 +9433,12 @@ dependencies = [ "reth-evm", "reth-execution-types", "reth-network-api", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-revm", "reth-rpc-eth-types", "reth-rpc-server-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-tasks", "reth-transaction-pool", @@ -8448,10 +9466,10 @@ dependencies = [ "reth-evm", "reth-execution-types", "reth-metrics", - "reth-primitives", + "reth-primitives 1.0.5", "reth-revm", "reth-rpc-server-types", - "reth-rpc-types", + "reth-rpc-types 1.0.5", "reth-rpc-types-compat", "reth-storage-api", "reth-tasks", @@ -8474,11 +9492,11 @@ name = "reth-rpc-layer" version = "1.0.5" dependencies = [ "alloy-rpc-types-engine", - "http", + "http 1.1.0", "jsonrpsee", "jsonrpsee-http-client", "pin-project", - "reqwest", + "reqwest 0.12.5", "tokio", "tower", "tracing", @@ -8493,8 +9511,8 @@ dependencies = [ "jsonrpsee-types", "reth-errors", "reth-network-api", - "reth-primitives", - "reth-rpc-types", + "reth-primitives 1.0.5", + "reth-rpc-types 1.0.5", "serde", "strum", ] @@ -8518,15 +9536,33 @@ dependencies = [ "rand 0.8.5", ] +[[package]] +name = "reth-rpc-types" +version = "1.0.5" +source = "git+https://github.com/telosnetwork/telos-reth?branch=telos-main#15f441221100c585045cad7043b89c751ac9323f" +dependencies = [ + "alloy-primitives", + "alloy-rpc-types", + "alloy-rpc-types-admin", + "alloy-rpc-types-anvil", + "alloy-rpc-types-beacon", + "alloy-rpc-types-engine", + "alloy-rpc-types-mev", + "alloy-rpc-types-trace", + "alloy-rpc-types-txpool", + "alloy-serde", + "jsonrpsee-types", +] + [[package]] name = "reth-rpc-types-compat" version = "1.0.5" dependencies = [ "alloy-rlp", "alloy-rpc-types", - "reth-primitives", - "reth-rpc-types", - "reth-trie-common", + "reth-primitives 1.0.5", + "reth-rpc-types 1.0.5", + "reth-trie-common 1.0.5", "serde_json", ] @@ -8545,7 +9581,7 @@ dependencies = [ "rand 0.8.5", "rayon", "reth-chainspec", - "reth-codecs", + "reth-codecs 1.0.5", "reth-config", "reth-consensus", "reth-db", @@ -8559,8 +9595,8 @@ dependencies = [ "reth-exex", "reth-network-p2p", "reth-network-peers", - "reth-primitives", - "reth-primitives-traits", + "reth-primitives 1.0.5", + "reth-primitives-traits 1.0.5", "reth-provider", "reth-prune", "reth-prune-types", @@ -8593,12 +9629,12 @@ dependencies = [ "reth-errors", "reth-metrics", "reth-network-p2p", - "reth-primitives-traits", + "reth-primitives-traits 1.0.5", "reth-provider", "reth-prune", "reth-stages-types", "reth-static-file", - "reth-static-file-types", + "reth-static-file-types 1.0.5", "reth-testing-utils", "reth-tokio-util", "thiserror", @@ -8618,8 +9654,8 @@ dependencies = [ "proptest", "proptest-arbitrary-interop", "rand 0.8.5", - "reth-codecs", - "reth-trie-common", + "reth-codecs 1.0.5", + "reth-trie-common 1.0.5", "serde", "test-fuzz", ] @@ -8639,7 +9675,7 @@ dependencies = [ "reth-prune-types", "reth-stages", "reth-stages-types", - "reth-static-file-types", + "reth-static-file-types 1.0.5", "reth-storage-errors", "reth-testing-utils", "reth-tokio-util", @@ -8658,6 +9694,17 @@ dependencies = [ "strum", ] +[[package]] +name = "reth-static-file-types" +version = "1.0.5" +source = "git+https://github.com/telosnetwork/telos-reth?branch=telos-main#15f441221100c585045cad7043b89c751ac9323f" +dependencies = [ + "alloy-primitives", + "derive_more", + "serde", + "strum", +] + [[package]] name = "reth-storage-api" version = "1.0.5" @@ -8666,7 +9713,7 @@ dependencies = [ "reth-chainspec", "reth-db-api", "reth-execution-types", - "reth-primitives", + "reth-primitives 1.0.5", "reth-prune-types", "reth-stages-types", "reth-storage-errors", @@ -8680,7 +9727,7 @@ version = "1.0.5" dependencies = [ "alloy-rlp", "reth-fs-util", - "reth-primitives", + "reth-primitives 1.0.5", "thiserror-no-std", ] @@ -8701,13 +9748,24 @@ dependencies = [ "tracing-futures", ] +[[package]] +name = "reth-telos-rpc" +version = "1.0.5" +dependencies = [ + "antelope-client 0.2.1 (git+https://github.com/telosnetwork/antelope-rs?branch=finish_table_rows_params)", + "async-trait", + "reth-node-telos", + "reth-rpc-eth-api", + "reth-rpc-eth-types", +] + [[package]] name = "reth-testing-utils" version = "1.0.5" dependencies = [ "alloy-genesis", "rand 0.8.5", - "reth-primitives", + "reth-primitives 1.0.5", "secp256k1", ] @@ -8758,7 +9816,7 @@ dependencies = [ "reth-execution-types", "reth-fs-util", "reth-metrics", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-storage-api", "reth-tasks", @@ -8792,11 +9850,11 @@ dependencies = [ "reth-chainspec", "reth-execution-errors", "reth-metrics", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-stages-types", "reth-storage-errors", - "reth-trie-common", + "reth-trie-common 1.0.5", "revm", "serde", "serde_json", @@ -8825,14 +9883,34 @@ dependencies = [ "plain_hasher", "proptest", "proptest-arbitrary-interop", - "reth-codecs", - "reth-primitives-traits", + "reth-codecs 1.0.5", + "reth-primitives-traits 1.0.5", "revm-primitives", "serde", "test-fuzz", "toml", ] +[[package]] +name = "reth-trie-common" +version = "1.0.5" +source = "git+https://github.com/telosnetwork/telos-reth?branch=telos-main#15f441221100c585045cad7043b89c751ac9323f" +dependencies = [ + "alloy-consensus", + "alloy-genesis", + "alloy-primitives", + "alloy-rlp", + "alloy-trie", + "bytes", + "derive_more", + "itertools 0.13.0", + "nybbles", + "reth-codecs 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "reth-primitives-traits 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "revm-primitives", + "serde", +] + [[package]] name = "reth-trie-db" version = "1.0.5" @@ -8851,12 +9929,12 @@ dependencies = [ "reth-db-api", "reth-execution-errors", "reth-metrics", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-stages-types", "reth-storage-errors", "reth-trie", - "reth-trie-common", + "reth-trie-common 1.0.5", "revm", "serde", "serde_json", @@ -8884,7 +9962,7 @@ dependencies = [ "reth-db-api", "reth-execution-errors", "reth-metrics", - "reth-primitives", + "reth-primitives 1.0.5", "reth-provider", "reth-tasks", "reth-trie", @@ -9068,6 +10146,18 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "afab94fb28594581f62d981211a9a4d53cc8130bbcbbb89a0440d9b8e81a7746" +[[package]] +name = "ruint" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0430214a5bb015461c0628e93d07738af2866e77a3f3db71e8264c999dda03fc" +dependencies = [ + "itertools 0.10.5", + "ruint-macro 0.2.1", + "rustc_version 0.4.0", + "thiserror", +] + [[package]] name = "ruint" version = "1.12.3" @@ -9087,12 +10177,18 @@ dependencies = [ "proptest", "rand 0.8.5", "rlp", - "ruint-macro", + "ruint-macro 1.2.1", "serde", "valuable", "zeroize", ] +[[package]] +name = "ruint-macro" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c0f4dd8af87bc3b385595ce5f61887b5b8efd4def9eb1679ce4300ec4d89c308" + [[package]] name = "ruint-macro" version = "1.2.1" @@ -9160,6 +10256,7 @@ version = "0.23.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c58f8c84392efc0a126acce10fa59ff7b3d2ac06ab451a33f2741989b806b044" dependencies = [ + "aws-lc-rs", "log", "once_cell", "ring", @@ -9176,12 +10273,21 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a88d6d420651b496bdd98684116959239430022a115c1240e6c3993be0b15fba" dependencies = [ "openssl-probe", - "rustls-pemfile", + "rustls-pemfile 2.1.3", "rustls-pki-types", "schannel", "security-framework", ] +[[package]] +name = "rustls-pemfile" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" +dependencies = [ + "base64 0.21.7", +] + [[package]] name = "rustls-pemfile" version = "2.1.3" @@ -9231,6 +10337,7 @@ version = "0.102.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8e6b52d4fda176fd835fdc55a835d4a89b8499cad995885a21149d5ad62f852e" dependencies = [ + "aws-lc-rs", "ring", "rustls-pki-types", "untrusted", @@ -9433,6 +10540,15 @@ dependencies = [ "serde_derive", ] +[[package]] +name = "serde-big-array" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "11fc7cc2c76d73e0f27ee52abbd64eec84d46f370c88371120433196934e4b7f" +dependencies = [ + "serde", +] + [[package]] name = "serde_bytes" version = "0.11.15" @@ -9477,6 +10593,17 @@ dependencies = [ "thiserror", ] +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.72", +] + [[package]] name = "serde_spanned" version = "0.6.7" @@ -9783,7 +10910,7 @@ dependencies = [ "base64 0.22.1", "bytes", "futures", - "http", + "http 1.1.0", "httparse", "log", "rand 0.8.5", @@ -9846,6 +10973,29 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" +[[package]] +name = "structmeta" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2e1575d8d40908d70f6fd05537266b90ae71b15dbbe7a8b7dffa2b759306d329" +dependencies = [ + "proc-macro2", + "quote", + "structmeta-derive", + "syn 2.0.72", +] + +[[package]] +name = "structmeta-derive" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "152a0b65a590ff6c3da95cabe2353ee04e6167c896b28e3b14478c2636c922fc" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.72", +] + [[package]] name = "strum" version = "0.26.3" @@ -9954,6 +11104,12 @@ dependencies = [ "syn 2.0.72", ] +[[package]] +name = "sync_wrapper" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" + [[package]] name = "sync_wrapper" version = "1.0.1" @@ -9985,12 +11141,105 @@ dependencies = [ "windows 0.52.0", ] +[[package]] +name = "system-configuration" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "system-configuration-sys", +] + +[[package]] +name = "system-configuration-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "tagptr" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b2093cf4c8eb1e67749a6762251bc9cd836b6fc171623bd0a9d324d37af2417" + [[package]] name = "tap" version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" +[[package]] +name = "telos-consensus-client" +version = "0.1.0" +source = "git+https://github.com/telosnetwork/telos-consensus-client?branch=translator_integration#7c2580c40435ba97e34feaa47da99bc3f962a81b" +dependencies = [ + "alloy", + "alloy-consensus", + "alloy-rlp", + "antelope-client 0.2.1 (git+https://github.com/telosnetwork/antelope-rs?branch=serialization)", + "arrowbatch", + "base64 0.22.1", + "chrono", + "clap", + "csv", + "env_logger", + "eyre", + "futures", + "hex", + "jsonwebtoken", + "log", + "rand 0.8.5", + "reqwest 0.11.27", + "reth-primitives 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "reth-rpc-types 1.0.5 (git+https://github.com/telosnetwork/telos-reth?branch=telos-main)", + "serde", + "serde_json", + "telos-translator-rs", + "thiserror", + "tokio", + "toml", + "tracing", + "tracing-subscriber", + "zeroize", +] + +[[package]] +name = "telos-translator-rs" +version = "0.1.0" +source = "git+https://github.com/telosnetwork/telos-translator-rs.git?branch=final_block_struct#ad012af952d5454219dc9e5178d718064f53a40c" +dependencies = [ + "alloy", + "alloy-consensus", + "alloy-rlp", + "antelope-client 0.2.1 (git+https://github.com/telosnetwork/antelope-rs?branch=finish_table_rows_params)", + "bytes", + "clap", + "dashmap 5.5.3", + "eyre", + "futures-util", + "hex", + "k256", + "lazy_static", + "log", + "moka", + "num-bigint", + "rlp", + "ruint 0.3.0", + "serde", + "serde_json", + "tokio", + "tokio-tungstenite 0.23.1", + "toml", + "tracing", + "tracing-subscriber", +] + [[package]] name = "tempfile" version = "3.11.0" @@ -10070,6 +11319,34 @@ dependencies = [ "test-fuzz-internal", ] +[[package]] +name = "testcontainers" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f7d80fe0008971413157e67062150cbf508b92f0eb525b9f49de1aec4267f24" +dependencies = [ + "async-trait", + "bollard", + "bollard-stubs", + "bytes", + "dirs", + "docker_credential", + "either", + "futures", + "log", + "memchr", + "parse-display", + "pin-project-lite", + "serde", + "serde_json", + "serde_with", + "thiserror", + "tokio", + "tokio-stream", + "tokio-util", + "url", +] + [[package]] name = "thin-vec" version = "0.2.13" @@ -10273,6 +11550,16 @@ dependencies = [ "syn 2.0.72", ] +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + [[package]] name = "tokio-rustls" version = "0.26.0" @@ -10296,6 +11583,18 @@ dependencies = [ "tokio-util", ] +[[package]] +name = "tokio-tungstenite" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c83b561d025642014097b66e6c1bb422783339e0909e4429cde4749d1990bc38" +dependencies = [ + "futures-util", + "log", + "tokio", + "tungstenite 0.21.0", +] + [[package]] name = "tokio-tungstenite" version = "0.23.1" @@ -10308,7 +11607,7 @@ dependencies = [ "rustls-pki-types", "tokio", "tokio-rustls", - "tungstenite", + "tungstenite 0.23.0", "webpki-roots", ] @@ -10405,8 +11704,8 @@ dependencies = [ "bytes", "futures-core", "futures-util", - "http", - "http-body", + "http 1.1.0", + "http-body 1.0.1", "http-body-util", "http-range-header", "httpdate", @@ -10566,6 +11865,12 @@ dependencies = [ "rlp", ] +[[package]] +name = "triomphe" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "859eb650cfee7434994602c3a68b25d77ad9e68c8a6cd491616ef86661382eb3" + [[package]] name = "trust-dns-proto" version = "0.23.2" @@ -10632,6 +11937,25 @@ dependencies = [ "toml", ] +[[package]] +name = "tungstenite" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ef1a641ea34f399a848dea702823bbecfb4c486f911735368f1f137cb8257e1" +dependencies = [ + "byteorder", + "bytes", + "data-encoding", + "http 1.1.0", + "httparse", + "log", + "rand 0.8.5", + "sha1", + "thiserror", + "url", + "utf-8", +] + [[package]] name = "tungstenite" version = "0.23.0" @@ -10641,7 +11965,7 @@ dependencies = [ "byteorder", "bytes", "data-encoding", - "http", + "http 1.1.0", "httparse", "log", "rand 0.8.5", @@ -10827,6 +12151,12 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + [[package]] name = "vergen" version = "8.3.2" @@ -11007,6 +12337,18 @@ dependencies = [ "rustls-pki-types", ] +[[package]] +name = "which" +version = "4.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87ba24419a2078cd2b0f2ede2691b6c66d8e47836da3b6db8265ebad47afbfc7" +dependencies = [ + "either", + "home", + "once_cell", + "rustix", +] + [[package]] name = "widestring" version = "1.1.0" @@ -11461,9 +12803,9 @@ dependencies = [ [[package]] name = "zstd" -version = "0.13.2" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcf2b778a664581e31e389454a7072dab1647606d44f7feea22cd5abb9c9f3f9" +checksum = "bffb3309596d527cfcba7dfc6ed6052f1d39dfbd7c867aa2e865e4a449c10110" dependencies = [ "zstd-safe", ] diff --git a/Cargo.toml b/Cargo.toml index 047c8f83f7b7..2f6886a4c095 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -112,6 +112,8 @@ members = [ "crates/storage/provider/", "crates/storage/storage-api/", "crates/tasks/", + "crates/telos/node", + "crates/telos/rpc", "crates/tokio-util/", "crates/tracing/", "crates/transaction-pool/", @@ -540,3 +542,8 @@ serial_test = "3" similar-asserts = "1.5.0" tempfile = "3.8" test-fuzz = "5" + +# telos +reth-node-telos = { path = "crates/telos/node" } +reth-telos-rpc = { path = "crates/telos/rpc" } +antelope-client = { git = "https://github.com/telosnetwork/antelope-rs", branch = "finish_table_rows_params" } diff --git a/TELOS_README.md b/TELOS_README.md new file mode 100644 index 000000000000..b4e5a801e448 --- /dev/null +++ b/TELOS_README.md @@ -0,0 +1,11 @@ +# telos-reth + +## Rebase notes: +```bash +git checkout main +git fetch upstream +git rebase +git push +git checkout telos-main +git rebase main # this is where it might get tricky! :) +``` diff --git a/bin/reth/Cargo.toml b/bin/reth/Cargo.toml index 7bf7b965c51d..631a081ec38d 100644 --- a/bin/reth/Cargo.toml +++ b/bin/reth/Cargo.toml @@ -110,6 +110,10 @@ itertools.workspace = true # p2p discv5.workspace = true +# telos +reth-node-telos = { workspace = true, optional = true } +reth-telos-rpc = { workspace = true, optional = true } + [target.'cfg(unix)'.dependencies] tikv-jemallocator = { version = "0.5.0", optional = true } libc = "0.2" @@ -148,10 +152,14 @@ optimism = [ # no-op feature flag for switching between the `optimism` and default functionality in CI matrices ethereum = [] telos = [ + "dep:reth-node-telos", + "dep:reth-telos-rpc", + "reth-chainspec/telos", "reth-basic-payload-builder/telos", "reth-ethereum-payload-builder/telos", "reth-evm/telos", "reth-execution-types/telos", + "reth-node-core/telos", "reth-payload-builder/telos", "reth-provider/telos", "reth-revm/telos", @@ -176,3 +184,8 @@ path = "src/main.rs" name = "op-reth" path = "src/optimism.rs" required-features = ["optimism"] + +[[bin]] +name = "telos-reth" +path = "src/telos.rs" +required-features = ["telos"] diff --git a/bin/reth/src/cli/mod.rs b/bin/reth/src/cli/mod.rs index d6fc7d3c4df4..79d0cd04cb5b 100644 --- a/bin/reth/src/cli/mod.rs +++ b/bin/reth/src/cli/mod.rs @@ -271,6 +271,9 @@ mod tests { /// Tests that the log directory is parsed correctly. It's always tied to the specific chain's /// name #[test] + #[cfg(not(feature = "telos"))] + // NOTE: Test is disable since chan names are defined in the alloy, + // and telos chains fallbacks to the id, causing paths to end with 40 and 41 fn parse_logs_path() { let mut reth = Cli::try_parse_args_from(["reth", "node"]).unwrap(); reth.logs.log_file_directory = diff --git a/bin/reth/src/main.rs b/bin/reth/src/main.rs index 3476d81887a5..fee6493a9833 100644 --- a/bin/reth/src/main.rs +++ b/bin/reth/src/main.rs @@ -8,6 +8,7 @@ static ALLOC: tikv_jemallocator::Jemalloc = tikv_jemallocator::Jemalloc; #[cfg(all(feature = "optimism", not(test)))] compile_error!("Cannot build the `reth` binary with the `optimism` feature flag enabled. Did you mean to build `op-reth`?"); +#[cfg(not(feature = "optimism"))] /// clap [Args] for Engine related arguments. use clap::Args; diff --git a/bin/reth/src/optimism.rs b/bin/reth/src/optimism.rs index 312c2998d61d..7ef025a334bf 100644 --- a/bin/reth/src/optimism.rs +++ b/bin/reth/src/optimism.rs @@ -14,7 +14,7 @@ use std::sync::Arc; #[global_allocator] static ALLOC: tikv_jemallocator::Jemalloc = tikv_jemallocator::Jemalloc; -#[cfg(not(feature = "optimism"))] +#[cfg(all(not(feature = "optimism"), not(feature = "telos")))] compile_error!("Cannot build the `op-reth` binary with the `optimism` feature flag disabled. Did you mean to build `reth`?"); #[cfg(feature = "optimism")] diff --git a/bin/reth/src/telos.rs b/bin/reth/src/telos.rs new file mode 100644 index 000000000000..198d1c72b510 --- /dev/null +++ b/bin/reth/src/telos.rs @@ -0,0 +1,49 @@ +#![allow(missing_docs)] + +use std::sync::Arc; +use clap::Parser; +use reth_node_telos::TelosArgs; +use reth_node_telos::TelosNode; +use reth_telos_rpc::TelosClient; + +// We use jemalloc for performance reasons. +#[cfg(all(feature = "jemalloc", unix))] +#[global_allocator] +static ALLOC: tikv_jemallocator::Jemalloc = tikv_jemallocator::Jemalloc; + +#[cfg(all(feature = "optimism", not(test)))] +compile_error!("Cannot build the `telos-reth` binary with the `optimism` feature flag enabled. Did you mean to build `op-reth`?"); + +#[cfg(feature = "telos")] +fn main() { + use reth::cli::Cli; + + reth_cli_util::sigsegv_handler::install(); + + // Enable backtraces unless a RUST_BACKTRACE value has already been explicitly provided. + if std::env::var_os("RUST_BACKTRACE").is_none() { + std::env::set_var("RUST_BACKTRACE", "1"); + } + + if let Err(err) = Cli::::parse().run(|builder, telos_args| async move { + let handle = builder + .node(TelosNode::new(telos_args.clone())) + .extend_rpc_modules(move |ctx| { + // register sequencer tx forwarder + if telos_args.telos_endpoint.is_some() { + ctx.registry.set_eth_raw_transaction_forwarder(Arc::new(TelosClient::new( + telos_args, + ))); + } + + Ok(()) + }) + .launch() + .await?; + + handle.node_exit_future.await + }) { + eprintln!("Error: {err:?}"); + std::process::exit(1); + } +} diff --git a/crates/chainspec/Cargo.toml b/crates/chainspec/Cargo.toml index 41db578254f3..20bdfdb392ca 100644 --- a/crates/chainspec/Cargo.toml +++ b/crates/chainspec/Cargo.toml @@ -52,6 +52,7 @@ optimism = [ "serde", "dep:op-alloy-rpc-types", ] +telos = [] std = [] arbitrary = [ "alloy-chains/arbitrary" diff --git a/crates/chainspec/res/genesis/tevmmainnet.json b/crates/chainspec/res/genesis/tevmmainnet.json new file mode 100644 index 000000000000..341aaefa9a0a --- /dev/null +++ b/crates/chainspec/res/genesis/tevmmainnet.json @@ -0,0 +1,13 @@ +{ + "nonce": "0x0", + "timestamp": "0x5c114972", + "extraData": "0x00000024796a9998ec49fb788de51614c57276dc6151bd2328305dba5d018897", + "gasLimit": "0x7fffffff", + "difficulty": "0x0", + "mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "coinbase": "0x0000000000000000000000000000000000000000", + "stateRoot": "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "number": "0x0", + "gasUsed": "0x0", + "parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000" +} diff --git a/crates/chainspec/res/genesis/tevmmainnet_base.json b/crates/chainspec/res/genesis/tevmmainnet_base.json new file mode 100644 index 000000000000..c7b6bae4ea14 --- /dev/null +++ b/crates/chainspec/res/genesis/tevmmainnet_base.json @@ -0,0 +1,13 @@ +{ + "nonce": "0x0", + "timestamp": "0x61782354", + "extraData": "0x0ac53eebcfa1cf139272bf58540d6dc53f0d22785f9e3d74cb9bc333b597e1bf", + "gasLimit": "0x7fffffff", + "difficulty": "0x0", + "mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "coinbase": "0x0000000000000000000000000000000000000000", + "stateRoot": "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "number": "0xac53ec7", + "gasUsed": "0x0", + "parentHash": "0x87bb009caefe5447b3c4beafb6cc168d031a73eb9c6bb0718b5b5972448908c2" +} diff --git a/crates/chainspec/res/genesis/tevmtestnet.json b/crates/chainspec/res/genesis/tevmtestnet.json new file mode 100644 index 000000000000..fd6f1c747b2b --- /dev/null +++ b/crates/chainspec/res/genesis/tevmtestnet.json @@ -0,0 +1,13 @@ +{ + "nonce": "0x0", + "timestamp": "0x5d55db93", + "extraData": "0x000000397128c497668c241b27d1521c764156cea50bcac87892fc8916e23b24", + "gasLimit": "0x7fffffff", + "difficulty": "0x0", + "mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "coinbase": "0x0000000000000000000000000000000000000000", + "stateRoot": "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "number": "0x0", + "gasUsed": "0x0", + "parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000" +} diff --git a/crates/chainspec/res/genesis/tevmtestnet_base.json b/crates/chainspec/res/genesis/tevmtestnet_base.json new file mode 100644 index 000000000000..f8a04e3e7641 --- /dev/null +++ b/crates/chainspec/res/genesis/tevmtestnet_base.json @@ -0,0 +1,13 @@ +{ + "nonce": "0x0", + "timestamp": "0x6170fef7", + "extraData": "0x0821345567cd66541778157d3936896f62a5b3fa134bb34d9708aa52f0c8c713", + "gasLimit": "0x7fffffff", + "difficulty": "0x0", + "mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "coinbase": "0x0000000000000000000000000000000000000000", + "stateRoot": "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "number": "0x821341c", + "gasUsed": "0x0", + "parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000" +} diff --git a/crates/chainspec/src/lib.rs b/crates/chainspec/src/lib.rs index 24f050d6f641..8453a4af1fe2 100644 --- a/crates/chainspec/src/lib.rs +++ b/crates/chainspec/src/lib.rs @@ -18,6 +18,9 @@ pub use spec::{ #[cfg(feature = "optimism")] pub use spec::{BASE_MAINNET, BASE_SEPOLIA, OP_MAINNET, OP_SEPOLIA}; +#[cfg(feature = "telos")] +pub use spec::{TEVMMAINNET, TEVMTESTNET, TEVMMAINNET_BASE, TEVMTESTNET_BASE}; + #[cfg(not(feature = "std"))] extern crate alloc; diff --git a/crates/chainspec/src/spec.rs b/crates/chainspec/src/spec.rs index 5c96bfb80321..a56a096ecbb7 100644 --- a/crates/chainspec/src/spec.rs +++ b/crates/chainspec/src/spec.rs @@ -229,6 +229,139 @@ pub static BASE_MAINNET: Lazy> = Lazy::new(|| { .into() }); +#[cfg(feature = "telos")] +/// The Tevmmainnet spec +pub static TEVMMAINNET: Lazy> = Lazy::new(|| { + ChainSpec { + chain: Chain::from_id(40), + genesis: serde_json::from_str(include_str!("../res/genesis/tevmmainnet.json")) + .expect("Can't deserialize Tevmmainnet genesis json"), + genesis_hash: Some(b256!( + "36fe7024b760365e3970b7b403e161811c1e626edd68460272fcdfa276272563" + )), + hardforks: ChainHardforks::new( + vec![ + (EthereumHardfork::Frontier, ForkCondition::Block(0)), + (EthereumHardfork::Homestead, ForkCondition::Block(0)), + (EthereumHardfork::Dao, ForkCondition::Block(0)), + (EthereumHardfork::Tangerine, ForkCondition::Block(0)), + (EthereumHardfork::SpuriousDragon, ForkCondition::Block(0)), + (EthereumHardfork::Byzantium, ForkCondition::Block(0)), + (EthereumHardfork::Constantinople, ForkCondition::Block(0)), + (EthereumHardfork::Petersburg, ForkCondition::Block(0)), + (EthereumHardfork::Istanbul, ForkCondition::Block(0)), + (EthereumHardfork::MuirGlacier, ForkCondition::Block(0)), + (EthereumHardfork::Berlin, ForkCondition::Block(0)), + ] + .into_iter() + .map(|(a, b)| (a.boxed(), b)) + .collect(), + ), + ..Default::default() + } + .into() +}); + +#[cfg(feature = "telos")] +/// The Tevmtestnet spec +pub static TEVMTESTNET: Lazy> = Lazy::new(|| { + ChainSpec { + chain: Chain::from_id(41), + genesis: serde_json::from_str(include_str!("../res/genesis/tevmtestnet.json")) + .expect("Can't deserialize Tevmtestnet genesis json"), + genesis_hash: Some(b256!( + "b25034033c9ca7a40e879ddcc29cf69071a22df06688b5fe8cc2d68b4e0528f9" + )), + hardforks: ChainHardforks::new( + vec![ + (EthereumHardfork::Frontier, ForkCondition::Block(0)), + (EthereumHardfork::Homestead, ForkCondition::Block(0)), + (EthereumHardfork::Dao, ForkCondition::Block(0)), + (EthereumHardfork::Tangerine, ForkCondition::Block(0)), + (EthereumHardfork::SpuriousDragon, ForkCondition::Block(0)), + (EthereumHardfork::Byzantium, ForkCondition::Block(0)), + (EthereumHardfork::Constantinople, ForkCondition::Block(0)), + (EthereumHardfork::Petersburg, ForkCondition::Block(0)), + (EthereumHardfork::Istanbul, ForkCondition::Block(0)), + (EthereumHardfork::MuirGlacier, ForkCondition::Block(0)), + (EthereumHardfork::Berlin, ForkCondition::Block(0)), + ] + .into_iter() + .map(|(a, b)| (a.boxed(), b)) + .collect(), + ), + ..Default::default() + } + .into() +}); + +#[cfg(feature = "telos")] +/// The Tevmmainnet-base spec +pub static TEVMMAINNET_BASE: Lazy> = Lazy::new(|| { + ChainSpec { + chain: Chain::from_id(40), + genesis: serde_json::from_str(include_str!("../res/genesis/tevmmainnet_base.json")) + .expect("Can't deserialize Tevmmainnet-base genesis json"), + genesis_hash: Some(b256!( + "757720a8e51c63ef1d4f907d6569dacaa965e91c2661345902de18af11f81063" + )), + hardforks: ChainHardforks::new( + vec![ + (EthereumHardfork::Frontier, ForkCondition::Block(180698823)), + (EthereumHardfork::Homestead, ForkCondition::Block(180698823)), + (EthereumHardfork::Dao, ForkCondition::Block(180698823)), + (EthereumHardfork::Tangerine, ForkCondition::Block(180698823)), + (EthereumHardfork::SpuriousDragon, ForkCondition::Block(180698823)), + (EthereumHardfork::Byzantium, ForkCondition::Block(180698823)), + (EthereumHardfork::Constantinople, ForkCondition::Block(180698823)), + (EthereumHardfork::Petersburg, ForkCondition::Block(180698823)), + (EthereumHardfork::Istanbul, ForkCondition::Block(180698823)), + (EthereumHardfork::MuirGlacier, ForkCondition::Block(180698823)), + (EthereumHardfork::Berlin, ForkCondition::Block(180698823)), + ] + .into_iter() + .map(|(a, b)| (a.boxed(), b)) + .collect(), + ), + ..Default::default() + } + .into() +}); + +#[cfg(feature = "telos")] +/// The Tevmtestnet-base spec +/// TODO: Block hash not finalized yet, need to modify the parent hash +pub static TEVMTESTNET_BASE: Lazy> = Lazy::new(|| { + ChainSpec { + chain: Chain::from_id(41), + genesis: serde_json::from_str(include_str!("../res/genesis/tevmtestnet_base.json")) + .expect("Can't deserialize Tevmtestnet-base genesis json"), + genesis_hash: Some(b256!( + "a6da3143bdeab454a923ac47589700ebe75d734f26e1f9201caa9b7268045d02" + )), + hardforks: ChainHardforks::new( + vec![ + (EthereumHardfork::Frontier, ForkCondition::Block(136393756)), + (EthereumHardfork::Homestead, ForkCondition::Block(136393756)), + (EthereumHardfork::Dao, ForkCondition::Block(136393756)), + (EthereumHardfork::Tangerine, ForkCondition::Block(136393756)), + (EthereumHardfork::SpuriousDragon, ForkCondition::Block(136393756)), + (EthereumHardfork::Byzantium, ForkCondition::Block(136393756)), + (EthereumHardfork::Constantinople, ForkCondition::Block(136393756)), + (EthereumHardfork::Petersburg, ForkCondition::Block(136393756)), + (EthereumHardfork::Istanbul, ForkCondition::Block(136393756)), + (EthereumHardfork::MuirGlacier, ForkCondition::Block(136393756)), + (EthereumHardfork::Berlin, ForkCondition::Block(136393756)), + ] + .into_iter() + .map(|(a, b)| (a.boxed(), b)) + .collect(), + ), + ..Default::default() + } + .into() +}); + /// A wrapper around [`BaseFeeParams`] that allows for specifying constant or dynamic EIP-1559 /// parameters based on the active [Hardfork]. #[derive(Clone, Debug, PartialEq, Eq)] @@ -426,6 +559,10 @@ impl ChainSpec { blob_gas_used, excess_blob_gas, requests_root, + #[cfg(feature = "telos")] + number: self.genesis.number.unwrap_or_default(), + #[cfg(not(feature = "telos"))] + number: 0, ..Default::default() } } @@ -693,6 +830,7 @@ impl ChainSpec { C::Optimism => Some(op_nodes()), C::BaseGoerli | C::BaseSepolia => Some(base_testnet_nodes()), C::OptimismSepolia | C::OptimismGoerli | C::OptimismKovan => Some(op_testnet_nodes()), + _ => None, } } @@ -1145,6 +1283,9 @@ mod tests { #[cfg(feature = "optimism")] use reth_ethereum_forks::OptimismHardforks; + #[cfg(feature = "telos")] + use crate::{TEVMMAINNET, TEVMTESTNET, TEVMMAINNET_BASE, TEVMTESTNET_BASE}; + fn test_fork_ids(spec: &ChainSpec, cases: &[(Head, ForkId)]) { for (block, expected_id) in cases { let computed_id = spec.fork_id(block); @@ -1808,6 +1949,30 @@ Post-merge hard forks (timestamp based): ); } + #[test] + #[cfg(feature = "telos")] + fn tevmmainnet_forkids() { + test_fork_ids(&TEVMMAINNET, &[]); + } + + #[test] + #[cfg(feature = "telos")] + fn tevmtestnet_forkids() { + test_fork_ids(&TEVMTESTNET, &[]); + } + + #[test] + #[cfg(feature = "telos")] + fn tevmmainnet_base_forkids() { + test_fork_ids(&TEVMMAINNET_BASE, &[]); + } + + #[test] + #[cfg(feature = "telos")] + fn tevmtestnet_base_forkids() { + test_fork_ids(&TEVMTESTNET_BASE, &[]); + } + #[test] fn dev_forkids() { test_fork_ids( diff --git a/crates/net/network/Cargo.toml b/crates/net/network/Cargo.toml index 9c616c5ce01c..2357f822bf81 100644 --- a/crates/net/network/Cargo.toml +++ b/crates/net/network/Cargo.toml @@ -100,6 +100,7 @@ default = ["serde"] geth-tests = [] serde = ["dep:serde", "secp256k1/serde", "enr/serde", "reth-network-types/serde"] test-utils = ["dep:reth-provider", "reth-provider?/test-utils", "dep:tempfile", "reth-transaction-pool/test-utils", "reth-network-types/test-utils"] +telos = ["reth-network-peers/telos"] [[bench]] name = "bench" diff --git a/crates/net/peers/Cargo.toml b/crates/net/peers/Cargo.toml index 5ac24edea759..bf0ea57584cc 100644 --- a/crates/net/peers/Cargo.toml +++ b/crates/net/peers/Cargo.toml @@ -37,3 +37,4 @@ tokio = { workspace = true, features = ["net", "macros", "rt"] } [features] secp256k1 = ["dep:secp256k1", "enr/secp256k1"] net = ["dep:tokio", "tokio?/net"] +telos = [] \ No newline at end of file diff --git a/crates/net/peers/src/bootnodes/mod.rs b/crates/net/peers/src/bootnodes/mod.rs index 31c91e5d1cea..7d0be5a0a017 100644 --- a/crates/net/peers/src/bootnodes/mod.rs +++ b/crates/net/peers/src/bootnodes/mod.rs @@ -8,6 +8,11 @@ pub use ethereum::*; mod optimism; pub use optimism::*; +#[cfg(feature = "telos")] +mod telos; +#[cfg(feature = "telos")] +pub use telos::*; + /// Returns parsed mainnet nodes pub fn mainnet_nodes() -> Vec { parse_nodes(&MAINNET_BOOTNODES[..]) @@ -47,3 +52,15 @@ pub fn base_testnet_nodes() -> Vec { pub fn parse_nodes(nodes: impl IntoIterator>) -> Vec { nodes.into_iter().map(|s| s.as_ref().parse().unwrap()).collect() } + +#[cfg(feature = "telos")] +/// Returns parsed tevmmainnet nodes +pub fn tevmmainnet_nodes() -> Vec { + parse_nodes(&TEVMMAINNET_BOOTNODES[..]) +} + +#[cfg(feature = "telos")] +/// Returns parsed tevmtestnet nodes +pub fn tevmtestnet_nodes() -> Vec { + parse_nodes(&TEVMTESTNET_BOOTNODES[..]) +} diff --git a/crates/net/peers/src/bootnodes/telos.rs b/crates/net/peers/src/bootnodes/telos.rs new file mode 100644 index 000000000000..2dbb17c69fad --- /dev/null +++ b/crates/net/peers/src/bootnodes/telos.rs @@ -0,0 +1,7 @@ +//! Telos bootnodes + +/// Ethereum Foundation TEVMMAINNET BOOTNODES +pub static TEVMMAINNET_BOOTNODES: [&str; 0] = []; + +/// Ethereum Foundation TEVMTESTNET BOOTNODES +pub static TEVMTESTNET_BOOTNODES: [&str; 0] = []; diff --git a/crates/node/core/Cargo.toml b/crates/node/core/Cargo.toml index ef3bdd703f9a..492d5b086f5a 100644 --- a/crates/node/core/Cargo.toml +++ b/crates/node/core/Cargo.toml @@ -85,6 +85,8 @@ optimism = [ "reth-rpc-types-compat/optimism", "reth-rpc-eth-api/optimism", ] +telos = ["reth-chainspec/telos"] + # Features for vergen to generate correct env vars jemalloc = [] asm-keccak = [] diff --git a/crates/node/core/src/args/utils.rs b/crates/node/core/src/args/utils.rs index 064505ccb862..199e220cb341 100644 --- a/crates/node/core/src/args/utils.rs +++ b/crates/node/core/src/args/utils.rs @@ -10,15 +10,19 @@ use reth_chainspec::DEV; #[cfg(feature = "optimism")] use reth_chainspec::{BASE_MAINNET, BASE_SEPOLIA, OP_MAINNET, OP_SEPOLIA}; -#[cfg(not(feature = "optimism"))] +#[cfg(all(not(feature = "optimism"), not(feature = "telos")))] use reth_chainspec::{HOLESKY, MAINNET, SEPOLIA}; #[cfg(feature = "optimism")] /// Chains supported by op-reth. First value should be used as the default. pub const SUPPORTED_CHAINS: &[&str] = &["optimism", "optimism-sepolia", "base", "base-sepolia"]; -#[cfg(not(feature = "optimism"))] +#[cfg(all(not(feature = "optimism"), not(feature = "telos")))] /// Chains supported by reth. First value should be used as the default. pub const SUPPORTED_CHAINS: &[&str] = &["mainnet", "sepolia", "holesky", "dev"]; +#[cfg(feature = "telos")] +/// Chains supported by telos-reth +pub const SUPPORTED_CHAINS: &[&str] = + &["tevmmainnet", "tevmtestnet", "tevmmainnet-base", "tevmtestnet-base"]; /// The help info for the --chain flag pub fn chain_help() -> String { @@ -31,11 +35,11 @@ pub fn chain_help() -> String { /// to a json file, or a json formatted string in-memory. The json needs to be a Genesis struct. pub fn chain_value_parser(s: &str) -> eyre::Result, eyre::Error> { Ok(match s { - #[cfg(not(feature = "optimism"))] + #[cfg(all(not(feature = "optimism"), not(feature = "telos")))] "mainnet" => MAINNET.clone(), - #[cfg(not(feature = "optimism"))] + #[cfg(all(not(feature = "optimism"), not(feature = "telos")))] "sepolia" => SEPOLIA.clone(), - #[cfg(not(feature = "optimism"))] + #[cfg(all(not(feature = "optimism"), not(feature = "telos")))] "holesky" => HOLESKY.clone(), "dev" => DEV.clone(), #[cfg(feature = "optimism")] @@ -46,6 +50,14 @@ pub fn chain_value_parser(s: &str) -> eyre::Result, eyre::Error> "base" => BASE_MAINNET.clone(), #[cfg(feature = "optimism")] "base_sepolia" | "base-sepolia" => BASE_SEPOLIA.clone(), + #[cfg(feature = "telos")] + "tevmmainnet" => reth_chainspec::TEVMMAINNET.clone(), + #[cfg(feature = "telos")] + "tevmtestnet" => reth_chainspec::TEVMTESTNET.clone(), + #[cfg(feature = "telos")] + "tevmmainnet-base" => reth_chainspec::TEVMMAINNET_BASE.clone(), + #[cfg(feature = "telos")] + "tevmtestnet-base" => reth_chainspec::TEVMTESTNET_BASE.clone(), _ => { // try to read json from path first let raw = match fs::read_to_string(PathBuf::from(shellexpand::full(s)?.into_owned())) { diff --git a/crates/node/core/src/dirs.rs b/crates/node/core/src/dirs.rs index a43350c2890c..081cf521f8bc 100644 --- a/crates/node/core/src/dirs.rs +++ b/crates/node/core/src/dirs.rs @@ -379,6 +379,17 @@ mod tests { let path = MaybePlatformPath::::from_str("my/path/to/datadir").unwrap(); let path = path.unwrap_or_chain_default(Chain::mainnet(), DatadirArgs::default()); assert!(path.as_ref().ends_with("my/path/to/datadir"), "{path:?}"); + + #[cfg(feature = "telos")] + { + let path = MaybePlatformPath::::default(); + let path = path.unwrap_or_chain_default(Chain::from_id(40), DatadirArgs::default()); + assert!(path.as_ref().ends_with("reth/tevmmainnet"), "{:?}", path); + + let path = MaybePlatformPath::::default(); + let path = path.unwrap_or_chain_default(Chain::from_id(40), DatadirArgs::default()); + assert!(path.as_ref().ends_with("reth/tevmmainnet-base"), "{:?}", path); + } } #[test] @@ -389,6 +400,18 @@ mod tests { let path = MaybePlatformPath::::default(); let path = path.unwrap_or_chain_default(Chain::sepolia(), DatadirArgs::default()); + assert!(path.as_ref().ends_with("reth/sepolia"), "{path:?}"); + + #[cfg(feature = "telos")] + { + let path = MaybePlatformPath::::default(); + let path = path.unwrap_or_chain_default(Chain::from_id(41), DatadirArgs::default()); + assert!(path.as_ref().ends_with("reth/tevmtestnet"), "{:?}", path); + + let path = MaybePlatformPath::::default(); + let path = path.unwrap_or_chain_default(Chain::from_id(41), DatadirArgs::default()); + assert!(path.as_ref().ends_with("reth/tevmtestnet-base"), "{:?}", path); + } } } diff --git a/crates/primitives-traits/Cargo.toml b/crates/primitives-traits/Cargo.toml index ede1af20c487..06802d5adbd0 100644 --- a/crates/primitives-traits/Cargo.toml +++ b/crates/primitives-traits/Cargo.toml @@ -61,3 +61,4 @@ arbitrary = [ "dep:proptest-arbitrary-interop", ] alloy-compat = ["alloy-rpc-types-eth"] +telos = [] \ No newline at end of file diff --git a/crates/primitives-traits/src/constants/mod.rs b/crates/primitives-traits/src/constants/mod.rs index 34e286a3e1dd..6bbeb4451d1f 100644 --- a/crates/primitives-traits/src/constants/mod.rs +++ b/crates/primitives-traits/src/constants/mod.rs @@ -108,6 +108,27 @@ pub const MAINNET_GENESIS_HASH: B256 = pub const SEPOLIA_GENESIS_HASH: B256 = b256!("25a5cc106eea7138acab33231d7160d69cb777ee0c2c553fcddf5138993e6dd9"); +#[cfg(feature = "telos")] +/// Tevmmainnet genesis hash. +pub const TEVMMAINNET_GENESIS_HASH: B256 = + b256!("36fe7024b760365e3970b7b403e161811c1e626edd68460272fcdfa276272563"); + +#[cfg(feature = "telos")] +/// Tevmtestnet genesis hash. +pub const TEVMTESTNET_GENESIS_HASH: B256 = + b256!("b25034033c9ca7a40e879ddcc29cf69071a22df06688b5fe8cc2d68b4e0528f9"); + +#[cfg(feature = "telos")] +/// Tevmmainnet base genesis hash. +pub const TEVMMAINNET_BASE_GENESIS_HASH: B256 = + b256!("757720a8e51c63ef1d4f907d6569dacaa965e91c2661345902de18af11f81063"); + +#[cfg(feature = "telos")] +/// Tevmtestnet base genesis hash. +/// TODO: Block hash not finalized yet, need to modify the parent hash +pub const TEVMTESTNET_BASE_GENESIS_HASH: B256 = + b256!("a6da3143bdeab454a923ac47589700ebe75d734f26e1f9201caa9b7268045d02"); + /// Holesky genesis hash: `0xb5f7f912443c940f21fd611f12828d75b534364ed9e95ca4e307729a4661bde4` pub const HOLESKY_GENESIS_HASH: B256 = b256!("b5f7f912443c940f21fd611f12828d75b534364ed9e95ca4e307729a4661bde4"); diff --git a/crates/primitives/Cargo.toml b/crates/primitives/Cargo.toml index 8b69d1bce5dc..af93a992eb6e 100644 --- a/crates/primitives/Cargo.toml +++ b/crates/primitives/Cargo.toml @@ -103,6 +103,8 @@ optimism = [ alloy-compat = ["reth-primitives-traits/alloy-compat", "dep:alloy-rpc-types"] test-utils = ["reth-primitives-traits/test-utils"] telos = [ + "reth-chainspec/telos", + "reth-primitives-traits/telos", "revm-primitives/telos", ] diff --git a/crates/primitives/src/lib.rs b/crates/primitives/src/lib.rs index 0858d5901fe7..e7ed0a80c8db 100644 --- a/crates/primitives/src/lib.rs +++ b/crates/primitives/src/lib.rs @@ -119,3 +119,16 @@ mod optimism { #[cfg(feature = "optimism")] pub use optimism::*; + +/// Telos specific re-exports +#[cfg(feature = "telos")] +mod telos { + pub use reth_chainspec::{TEVMMAINNET, TEVMMAINNET_BASE, TEVMTESTNET, TEVMTESTNET_BASE}; + pub use reth_primitives_traits::constants::{ + TEVMMAINNET_BASE_GENESIS_HASH, TEVMMAINNET_GENESIS_HASH, TEVMTESTNET_BASE_GENESIS_HASH, + TEVMTESTNET_GENESIS_HASH, + }; +} + +#[cfg(feature = "telos")] +pub use telos::*; diff --git a/crates/primitives/src/proofs.rs b/crates/primitives/src/proofs.rs index ab57be8ffd1d..ac5cbc7dbb36 100644 --- a/crates/primitives/src/proofs.rs +++ b/crates/primitives/src/proofs.rs @@ -141,6 +141,8 @@ mod tests { use alloy_primitives::{b256, Address, LogData}; use alloy_rlp::Decodable; use reth_chainspec::{HOLESKY, MAINNET, SEPOLIA}; + #[cfg(feature = "telos")] + use reth_chainspec::{TEVMMAINNET, TEVMMAINNET_BASE, TEVMTESTNET, TEVMTESTNET_BASE}; use reth_trie_common::root::{state_root_ref_unhashed, state_root_unhashed}; use std::collections::HashMap; @@ -543,6 +545,54 @@ mod tests { "sepolia state root mismatch" ); + #[cfg(feature = "telos")] + { + let expected_tevmmainnet_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmmainnet_state_root = + state_root_ref_unhashed(&TEVMMAINNET.genesis.alloc); + assert_eq!( + expected_tevmmainnet_state_root, calculated_tevmmainnet_state_root, + "tevmmainnet state root mismatch" + ); + } + + #[cfg(feature = "telos")] + { + let expected_tevmmainnet_base_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmmainnet_base_state_root = + state_root_ref_unhashed(&TEVMMAINNET_BASE.genesis.alloc); + assert_eq!( + expected_tevmmainnet_base_state_root, calculated_tevmmainnet_base_state_root, + "tevmmainnet-base state root mismatch" + ); + } + + #[cfg(feature = "telos")] + { + let expected_tevmtestnet_base_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmtestnet_base_state_root = + state_root_ref_unhashed(&TEVMTESTNET_BASE.genesis.alloc); + assert_eq!( + expected_tevmtestnet_base_state_root, calculated_tevmtestnet_base_state_root, + "tevmtestnet-base state root mismatch" + ); + } + + #[cfg(feature = "telos")] + { + let expected_tevmtestnet_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmtestnet_state_root = + state_root_ref_unhashed(&TEVMTESTNET.genesis.alloc); + assert_eq!( + expected_tevmtestnet_state_root, calculated_tevmtestnet_state_root, + "tevmtestnet state root mismatch" + ); + } + let expected_holesky_state_root = b256!("69d8c9d72f6fa4ad42d4702b433707212f90db395eb54dc20bc85de253788783"); let calculated_holesky_state_root = state_root_ref_unhashed(&HOLESKY.genesis.alloc); @@ -550,5 +600,46 @@ mod tests { expected_holesky_state_root, calculated_holesky_state_root, "holesky state root mismatch" ); + + #[cfg(feature = "telos")] + { + use reth_chainspec::{TEVMMAINNET, TEVMMAINNET_BASE, TEVMTESTNET, TEVMTESTNET_BASE}; + + let expected_tevmmainnet_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmmainnet_state_root = + state_root_ref_unhashed(&TEVMMAINNET.genesis.alloc); + assert_eq!( + expected_tevmmainnet_state_root, calculated_tevmmainnet_state_root, + "tevmmainnet state root mismatch" + ); + + let expected_tevmmainnet_base_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmmainnet_base_state_root = + state_root_ref_unhashed(&TEVMMAINNET_BASE.genesis.alloc); + assert_eq!( + expected_tevmmainnet_base_state_root, calculated_tevmmainnet_base_state_root, + "tevmmainnet-base state root mismatch" + ); + + let expected_tevmtestnet_base_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmtestnet_base_state_root = + state_root_ref_unhashed(&TEVMTESTNET_BASE.genesis.alloc); + assert_eq!( + expected_tevmtestnet_base_state_root, calculated_tevmtestnet_base_state_root, + "tevmtestnet-base state root mismatch" + ); + + let expected_tevmtestnet_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmtestnet_state_root = + state_root_ref_unhashed(&TEVMTESTNET.genesis.alloc); + assert_eq!( + expected_tevmtestnet_state_root, calculated_tevmtestnet_state_root, + "tevmtestnet state root mismatch" + ); + } } } diff --git a/crates/storage/db-common/Cargo.toml b/crates/storage/db-common/Cargo.toml index 5c453df1cf67..2dc5c6561818 100644 --- a/crates/storage/db-common/Cargo.toml +++ b/crates/storage/db-common/Cargo.toml @@ -42,3 +42,6 @@ reth-primitives-traits.workspace = true [lints] workspace = true + +[features] +telos = ["reth-primitives/telos"] \ No newline at end of file diff --git a/crates/storage/db-common/src/init.rs b/crates/storage/db-common/src/init.rs index 95324cb6820d..eff09930df8d 100644 --- a/crates/storage/db-common/src/init.rs +++ b/crates/storage/db-common/src/init.rs @@ -121,6 +121,9 @@ pub fn init_genesis(factory: ProviderFactory) -> Result( Err(e) => return Err(e), } - provider.tx_ref().put::(block_hash, 0)?; - provider.tx_ref().put::(0, Default::default())?; + if cfg!(feature = "telos") { + provider.tx_ref().put::(block_hash, header.number)?; + provider.tx_ref().put::(header.number, Default::default())?; + return Ok(()) + } + + provider.tx_ref().put::(block_hash, 0)?; + provider.tx_ref().put::(0, Default::default())?; Ok(()) } @@ -538,6 +547,11 @@ mod tests { transaction::DbTx, }; use reth_primitives::{HOLESKY_GENESIS_HASH, MAINNET_GENESIS_HASH, SEPOLIA_GENESIS_HASH}; + #[cfg(feature = "telos")] + use reth_primitives::{ + TEVMMAINNET, TEVMMAINNET_BASE, TEVMMAINNET_BASE_GENESIS_HASH, TEVMMAINNET_GENESIS_HASH, + TEVMTESTNET, TEVMTESTNET_BASE, TEVMTESTNET_BASE_GENESIS_HASH, TEVMTESTNET_GENESIS_HASH, + }; use reth_primitives_traits::IntegerList; use reth_provider::test_utils::create_test_provider_factory_with_chain_spec; @@ -578,6 +592,50 @@ mod tests { assert_eq!(genesis_hash, HOLESKY_GENESIS_HASH); } + #[test] + #[cfg(feature = "telos")] + fn success_init_genesis_tevmmainnet() { + let genesis_hash = + init_genesis(create_test_provider_factory_with_chain_spec(TEVMMAINNET.clone())) + .unwrap(); + + // actual, expected + assert_eq!(genesis_hash, TEVMMAINNET_GENESIS_HASH); + } + + #[test] + #[cfg(feature = "telos")] + fn success_init_genesis_tevmtestnet() { + let genesis_hash = + init_genesis(create_test_provider_factory_with_chain_spec(TEVMTESTNET.clone())) + .unwrap(); + + // actual, expected + assert_eq!(genesis_hash, TEVMTESTNET_GENESIS_HASH); + } + + #[test] + #[cfg(feature = "telos")] + fn success_init_genesis_tevmmainnet_base() { + let genesis_hash = + init_genesis(create_test_provider_factory_with_chain_spec(TEVMMAINNET_BASE.clone())) + .unwrap(); + + // actual, expected + assert_eq!(genesis_hash, TEVMMAINNET_BASE_GENESIS_HASH); + } + + #[test] + #[cfg(feature = "telos")] + fn success_init_genesis_tevmtestnet_base() { + let genesis_hash = + init_genesis(create_test_provider_factory_with_chain_spec(TEVMTESTNET_BASE.clone())) + .unwrap(); + + // actual, expected + assert_eq!(genesis_hash, TEVMTESTNET_BASE_GENESIS_HASH); + } + #[test] fn fail_init_inconsistent_db() { let factory = create_test_provider_factory_with_chain_spec(SEPOLIA.clone()); diff --git a/crates/telos/node/Cargo.toml b/crates/telos/node/Cargo.toml new file mode 100644 index 000000000000..eba95e72ed90 --- /dev/null +++ b/crates/telos/node/Cargo.toml @@ -0,0 +1,59 @@ +[package] +name = "reth-node-telos" +version.workspace = true +edition.workspace = true +rust-version.workspace = true +license.workspace = true +homepage.workspace = true +repository.workspace = true + +[lints] +workspace = true + +[dependencies] +antelope-client.workspace = true +reth-primitives.workspace = true + +reth-auto-seal-consensus.workspace = true +reth-basic-payload-builder.workspace = true +reth-beacon-consensus.workspace = true +reth-ethereum-engine-primitives.workspace = true +reth-evm-ethereum.workspace = true +reth-network.workspace = true +reth-node-api.workspace = true +reth-node-builder.workspace = true +reth-node-ethereum.workspace = true +reth-payload-builder.workspace = true +reth-provider.workspace = true +reth-rpc.workspace = true +reth-stages.workspace = true +reth-tracing.workspace = true +reth-transaction-pool.workspace = true + +clap.workspace = true +serde = { workspace = true, features = ["derive"] } +serde_json = "1.0.122" +tokio = "1.39.2" +tracing = "0.1.40" +tracing-subscriber = "0.3.18" + +[features] +telos = [ + "reth-chainspec/telos", + "reth-basic-payload-builder/telos", + "reth-payload-builder/telos", + "reth-provider/telos", + "reth-rpc/telos", + "reth-stages/telos", + "reth-transaction-pool/telos", + "reth-primitives/telos", +] + +[dev-dependencies] +reth.workspace = true +reth-chainspec.workspace = true +reth-e2e-test-utils.workspace = true +eyre.workspace = true + +telos-consensus-client = { git = "https://github.com/telosnetwork/telos-consensus-client", branch = "translator_integration" } +testcontainers = "0.21.1" \ No newline at end of file diff --git a/crates/telos/node/src/args.rs b/crates/telos/node/src/args.rs new file mode 100644 index 000000000000..ce992b7af7b0 --- /dev/null +++ b/crates/telos/node/src/args.rs @@ -0,0 +1,46 @@ +//! clap [Args](clap::Args) for telos configuration + +#[derive(Debug, Clone, Default, PartialEq, Eq, clap::Args)] +#[clap(next_help_heading = "Telos")] +/// Telos arguments +pub struct TelosArgs { + /// TelosZero endpoint to use for API calls (send_transaction, get gas price from table) + #[arg(long = "telos.telos_endpoint", value_name = "HTTP_URL")] + pub telos_endpoint: Option, + + /// Signer account name + #[arg(long = "telos.signer_account")] + pub signer_account: Option, + + /// Signer permission name + #[arg(long = "telos.signer_permission")] + pub signer_permission: Option, + + /// Signer private key + #[arg(long = "telos.signer_key")] + pub signer_key: Option, + + /// Seconds to cache gas price + #[arg(long = "telos.gas_cache_seconds")] + pub gas_cache_seconds: Option, +} + +#[cfg(test)] +mod tests { + use super::*; + use clap::{Args, Parser}; + + /// A helper type to parse Args more easily + #[derive(Parser)] + struct CommandParser { + #[clap(flatten)] + args: T, + } + + #[test] + fn test_parse_database_args() { + let default_args = TelosArgs::default(); + let args = CommandParser::::parse_from(["reth"]).args; + assert_eq!(args, default_args); + } +} diff --git a/crates/telos/node/src/lib.rs b/crates/telos/node/src/lib.rs new file mode 100644 index 000000000000..2f709884ae07 --- /dev/null +++ b/crates/telos/node/src/lib.rs @@ -0,0 +1,16 @@ +//! Standalone crate for Telos-specific Reth configuration and builder types. + +#![doc( + html_logo_url = "https://raw.githubusercontent.com/paradigmxyz/reth/main/assets/reth-docs.png", + html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", + issue_tracker_base_url = "https://github.com/telosnetwork/telos-reth/issues/" +)] +#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] + +#![cfg(feature = "telos")] + +pub mod args; +pub mod node; + +pub use crate::args::TelosArgs; +pub use crate::node::TelosNode; diff --git a/crates/telos/node/src/node.rs b/crates/telos/node/src/node.rs new file mode 100644 index 000000000000..fa44cd76afa3 --- /dev/null +++ b/crates/telos/node/src/node.rs @@ -0,0 +1,80 @@ +//! Telos node implementation + +use crate::args::TelosArgs; +use reth_ethereum_engine_primitives::{ + EthBuiltPayload, EthEngineTypes, EthPayloadAttributes, EthPayloadBuilderAttributes, +}; +use reth_evm_ethereum::EthEvmConfig; +use reth_node_api::{FullNodeTypes, NodeTypes}; +use reth_node_builder::components::ComponentsBuilder; +use reth_node_builder::{Node, PayloadTypes}; +use reth_node_ethereum::node::{ + EthereumAddOns, EthereumConsensusBuilder, EthereumExecutorBuilder, EthereumNetworkBuilder, + EthereumPayloadBuilder, EthereumPoolBuilder, +}; + +/// Type configuration for a regular Telos node. +#[derive(Debug, Default, Clone)] +#[non_exhaustive] +pub struct TelosNode { + /// Additional Telos args + pub args: TelosArgs, +} + +impl TelosNode { + /// Creates a new instance of the Telos node type. + pub const fn new(args: TelosArgs) -> Self { + Self { args } + } + + /// Returns a [`ComponentsBuilder`] configured for a regular Ethereum node. + pub fn components() -> ComponentsBuilder< + Node, + EthereumPoolBuilder, + EthereumPayloadBuilder, + EthereumNetworkBuilder, + EthereumExecutorBuilder, + EthereumConsensusBuilder, + > + where + Node: FullNodeTypes, + ::Engine: PayloadTypes< + BuiltPayload = EthBuiltPayload, + PayloadAttributes = EthPayloadAttributes, + PayloadBuilderAttributes = EthPayloadBuilderAttributes, + >, + { + ComponentsBuilder::default() + .node_types::() + .pool(EthereumPoolBuilder::default()) + .payload(EthereumPayloadBuilder::new(EthEvmConfig::default())) + .network(EthereumNetworkBuilder::default()) + .executor(EthereumExecutorBuilder::default()) + .consensus(EthereumConsensusBuilder::default()) + } +} + +impl NodeTypes for TelosNode { + type Primitives = (); + type Engine = EthEngineTypes; +} + +impl Node for TelosNode +where + N: FullNodeTypes, +{ + type ComponentsBuilder = ComponentsBuilder< + N, + EthereumPoolBuilder, + EthereumPayloadBuilder, + EthereumNetworkBuilder, + EthereumExecutorBuilder, + EthereumConsensusBuilder, + >; + + type AddOns = EthereumAddOns; + + fn components_builder(&self) -> Self::ComponentsBuilder { + Self::components() + } +} diff --git a/crates/telos/node/tests/assets/jwt.hex b/crates/telos/node/tests/assets/jwt.hex new file mode 100644 index 000000000000..e7c9bf21b3bf --- /dev/null +++ b/crates/telos/node/tests/assets/jwt.hex @@ -0,0 +1 @@ +2d3d7e18cb183dd0ad72fecb94e549a7cbd7cac09cca408ba83143cbcd859b8a \ No newline at end of file diff --git a/crates/telos/node/tests/integration.rs b/crates/telos/node/tests/integration.rs new file mode 100644 index 000000000000..ff5e373abee1 --- /dev/null +++ b/crates/telos/node/tests/integration.rs @@ -0,0 +1,136 @@ +use antelope::api::client::{APIClient, DefaultProvider}; +use reth::{ + args::RpcServerArgs, + builder::{NodeBuilder, NodeConfig}, + tasks::{TaskManager}, +}; +use reth_chainspec::{ChainSpecBuilder, TEVMTESTNET}; +use reth_e2e_test_utils::node::NodeTestContext; +use reth_node_ethereum::EthereumNode; +use reth_primitives::{Genesis, B256}; +use std::fs; +use std::path::PathBuf; +use std::sync::Arc; +use telos_consensus_client::client::{ConsensusClient, Error}; +use telos_consensus_client::config::AppConfig; +use testcontainers::core::ContainerPort::Tcp; +use testcontainers::{runners::AsyncRunner, ContainerAsync, GenericImage}; +use tracing::info; + +struct TelosRethNodeHandle { + execution_port: u16, + jwt_secret: String, +} + +async fn start_ship() -> ContainerAsync { + // Change this container to a local image if using new ship data, + // then make sure to update the ship data in the testcontainer-nodeos-evm repo and build a new version + + // The tag for this image needs to come from the Github packages UI, under the "OS/Arch" tab + // and should be the tag for linux/amd64 + let container: ContainerAsync = GenericImage::new( + "ghcr.io/telosnetwork/testcontainer-nodeos-evm", + "v0.1.4@sha256:a8dc857e46404d74b286f8c8d8646354ca6674daaaf9eb6f972966052c95eb4a", + ) + .with_exposed_port(Tcp(8888)) + .with_exposed_port(Tcp(18999)) + .start() + .await + .unwrap(); + + let port_8888 = container.get_host_port_ipv4(8888).await.unwrap(); + + let api_base_url = format!("http://localhost:{port_8888}"); + let api_client = APIClient::::default_provider(api_base_url).unwrap(); + + let mut last_block = 0; + + loop { + let Ok(info) = api_client.v1_chain.get_info().await else { + println!("Waiting for telos node to produce blocks..."); + tokio::time::sleep(tokio::time::Duration::from_secs(1)).await; + continue; + }; + if last_block != 0 && info.head_block_num > last_block { + break; + } + last_block = info.head_block_num; + } + + container +} + +fn init_reth() -> eyre::Result<(NodeConfig, String)> { + // Chain spec with test allocs + let genesis: Genesis = + serde_json::from_str(include_str!("../../../ethereum/node/tests/assets/genesis.json")) + .unwrap(); + let chain_spec = Arc::new( + ChainSpecBuilder::default() + .chain(TEVMTESTNET.chain) + .genesis(genesis) + .cancun_activated() + .build(), + ); + + let mut rpc_config = RpcServerArgs::default().with_unused_ports().with_http(); + rpc_config.auth_jwtsecret = Some(PathBuf::from("tests/assets/jwt.hex")); + + //let _jwt = rpc_config.auth_server_config(JwtSecret::random()); + // Node setup + let node_config = NodeConfig::test().with_chain(chain_spec).with_rpc(rpc_config.clone()); + + let jwt = fs::read_to_string(node_config.rpc.auth_jwtsecret.clone().unwrap())?; + Ok((node_config, jwt)) +} + +async fn start_consensus(reth_handle: TelosRethNodeHandle, ship_port: u16, chain_port: u16) -> eyre::Result<(), Error> { + let config = AppConfig { + chain_id: 41, + execution_endpoint: format!("http://localhost:{}", reth_handle.execution_port), + jwt_secret: reth_handle.jwt_secret, + ship_endpoint: format!("ws://localhost:{ship_port}"), + chain_endpoint: format!("http://localhost:{chain_port}"), + batch_size: 5, + block_delta: None, + prev_hash: B256::ZERO.to_string(), + validate_hash: None, + start_block: 0, + stop_block: Some(60), + }; + + let mut client_under_test = ConsensusClient::new(config).await; + client_under_test.run().await +} + +#[tokio::test] +async fn testing_chain_sync() { + tracing_subscriber::fmt::init(); + + let container = start_ship().await; + let chain_port = container.get_host_port_ipv4(8888).await.unwrap(); + let ship_port = container.get_host_port_ipv4(18999).await.unwrap(); + + let (node_config, jwt_secret) = init_reth().unwrap(); + + let exec = TaskManager::current(); + let exec = exec.executor(); + + reth_tracing::init_test_tracing(); + + let node_handle = NodeBuilder::new(node_config.clone()) + .testing_node(exec) + .node(EthereumNode::default()) + .launch() + .await + .unwrap(); + + let execution_port = node_handle.node.auth_server_handle().local_addr().port(); + let reth_handle = TelosRethNodeHandle { execution_port, jwt_secret }; + _ = NodeTestContext::new(node_handle.node.clone()).await.unwrap(); + info!("Started Reth!"); + + if let Err(error) = start_consensus(reth_handle, ship_port, chain_port).await { + panic!("Error with consensus client: {error:?}"); + } +} diff --git a/crates/telos/rpc/Cargo.toml b/crates/telos/rpc/Cargo.toml new file mode 100644 index 000000000000..c838f9998781 --- /dev/null +++ b/crates/telos/rpc/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "reth-telos-rpc" +version.workspace = true +edition.workspace = true +rust-version.workspace = true +license.workspace = true +homepage.workspace = true +repository.workspace = true +exclude.workspace = true + +[dependencies] +async-trait.workspace = true + +reth-rpc-eth-api.workspace = true +reth-rpc-eth-types.workspace = true + +antelope-client.workspace = true +reth-node-telos = { workspace = true, features = ["telos"] } + +[lints] +workspace = true diff --git a/crates/telos/rpc/src/client.rs b/crates/telos/rpc/src/client.rs new file mode 100644 index 000000000000..fefbe70dbde5 --- /dev/null +++ b/crates/telos/rpc/src/client.rs @@ -0,0 +1,102 @@ +use std::sync::Arc; +use reth_rpc_eth_api::RawTransactionForwarder; +use reth_rpc_eth_types::error::{EthResult}; +use antelope::api::client::{APIClient, DefaultProvider}; +use antelope::chain::name::Name; +use antelope::chain::private_key::PrivateKey; +use antelope::{chain::{Packer, Encoder, Decoder}, name, StructPacker}; +use antelope::chain::action::{Action, PermissionLevel}; +use antelope::chain::checksum::Checksum160; +use antelope::chain::transaction::{SignedTransaction, Transaction}; +use reth_node_telos::TelosArgs; + +/// A client to interact with a Sequencer +#[derive(Debug, Clone)] +pub struct TelosClient { + inner: Arc, +} + +#[derive(Debug, Clone)] +struct TelosClientInner { + pub api_client: APIClient, + pub signer_account: Name, + pub signer_permission: Name, + pub signer_key: PrivateKey, +} + +#[derive(StructPacker)] +struct RawActionData { + pub ram_payer: Name, + pub tx: Vec, + pub estimate_gas: bool, + pub sender: Option, +} + +impl TelosClient { + /// Creates a new [`TelosClient`]. + pub fn new(telos_args: TelosArgs) -> Self { + if telos_args.telos_endpoint.is_none() || telos_args.signer_account.is_none() || telos_args.signer_permission.is_none() || telos_args.signer_key.is_none() { + panic!("Should not construct TelosClient without proper TelosArgs with telos_endpoint and signer args"); + } + let api_client = APIClient::::default_provider(telos_args.telos_endpoint.unwrap().into()).unwrap(); + let inner = TelosClientInner { + api_client, + signer_account: name!(&telos_args.signer_account.unwrap()), + signer_permission: name!(&telos_args.signer_permission.unwrap()), + signer_key: PrivateKey::from_str(&telos_args.signer_key.unwrap(), false).unwrap(), + }; + Self { inner: Arc::new(inner) } + } + + async fn send_to_telos(&self, tx: &[u8]) -> EthResult<()> { + let get_info = self.inner.api_client.v1_chain.get_info().await.unwrap(); + let trx_header = get_info.get_transaction_header(90); + let trx_header = trx_header.clone(); + let trx_bytes = tx.to_vec(); + + let raw_action_data = RawActionData { + ram_payer: name!("eosio.evm"), + tx: trx_bytes, + estimate_gas: false, + sender: None, + }; + + let action = Action::new_ex( + name!("eosio.evm"), + name!("raw"), + vec![PermissionLevel::new( + self.inner.signer_account, + self.inner.signer_permission, + )], + raw_action_data, + ); + + let transaction = Transaction { + header: trx_header, + context_free_actions: vec![], + actions: vec![action], + extension: vec![], + }; + + let signed_telos_transaction = SignedTransaction { + transaction: transaction.clone(), + signatures: vec![self.inner + .signer_key + .sign_message(&transaction.signing_data(&get_info.chain_id.data.to_vec()))], + context_free_data: vec![], + }; + + let result = self.inner.api_client.v1_chain.send_transaction(signed_telos_transaction); + + let _trx_id = result.await.unwrap().transaction_id; + Ok(()) + } +} + +#[async_trait::async_trait] +impl RawTransactionForwarder for TelosClient { + async fn forward_raw_transaction(&self, tx: &[u8]) -> EthResult<()> { + Self::send_to_telos(self, tx).await?; + Ok(()) + } +} \ No newline at end of file diff --git a/crates/telos/rpc/src/lib.rs b/crates/telos/rpc/src/lib.rs new file mode 100644 index 000000000000..4872c6fbf254 --- /dev/null +++ b/crates/telos/rpc/src/lib.rs @@ -0,0 +1,5 @@ +//! /// A Telos client to interact with a Sequencer + +mod client; + +pub use crate::client::TelosClient; \ No newline at end of file