From b64a496d54b4c6027a8604895c973149d239352a Mon Sep 17 00:00:00 2001 From: Julian Meyer Date: Mon, 9 Mar 2026 01:58:49 -0700 Subject: [PATCH 1/4] fix: remove --flashblocks.fixed --- runner/clients/builder/client.go | 1 - 1 file changed, 1 deletion(-) diff --git a/runner/clients/builder/client.go b/runner/clients/builder/client.go index eb07359..660b41a 100644 --- a/runner/clients/builder/client.go +++ b/runner/clients/builder/client.go @@ -49,7 +49,6 @@ func (r *BuilderClient) Run(ctx context.Context, cfg *types.RuntimeConfig) error cfg2 := *cfg cfg2.Args = append(cfg2.Args, "--flashblocks.port", fmt.Sprintf("%d", r.websocketPort)) - cfg2.Args = append(cfg2.Args, "--flashblocks.fixed") err := r.elClient.Run(ctx, &cfg2) if err != nil { return err From baf6a43be836109e0d001b32910ae4b1fe84ed82 Mon Sep 17 00:00:00 2001 From: Julian Meyer Date: Mon, 9 Mar 2026 03:33:26 -0700 Subject: [PATCH 2/4] refactor: consolidate builder build into base-reth-node job Build both base-reth-node and base-builder binaries from the same cargo build in build-base-reth-node.sh, removing the separate build-builder job and its associated build script, version inputs, and environment variables. --- .github/workflows/_build-binaries.yaml | 64 +++++----------------- .github/workflows/build.yaml | 1 - .github/workflows/examples.yaml | 1 - .github/workflows/public-benchmarks.yaml | 2 +- Makefile | 8 +-- clients/README.md | 31 ++++++----- clients/build-base-reth-node.sh | 23 +++++--- clients/build-builder.sh | 70 ------------------------ clients/versions.env | 4 -- 9 files changed, 51 insertions(+), 153 deletions(-) delete mode 100755 clients/build-builder.sh diff --git a/.github/workflows/_build-binaries.yaml b/.github/workflows/_build-binaries.yaml index 21ad22e..ba71d9a 100644 --- a/.github/workflows/_build-binaries.yaml +++ b/.github/workflows/_build-binaries.yaml @@ -1,5 +1,5 @@ # Reusable workflow for building all binaries -# This workflow is called by other workflows to build reth, geth, builder, op-program, and contracts +# This workflow is called by other workflows to build reth, geth, base-reth-node, base-builder, op-program, and contracts name: Build Binaries on: @@ -15,11 +15,6 @@ on: required: false type: string default: "6cbfcd5161083bcd4052edc3022d9f99c6fe40e0" - builder_version: - description: "Builder version to build" - required: false - type: string - default: "23f42c8e78ba3abb45a8840df7037a27e196e601" base_reth_node_version: description: "Base Reth Node version to build" required: false @@ -145,46 +140,6 @@ jobs: path: ~/bin/geth retention-days: 1 - build-builder: - runs-on: ubuntu-latest - permissions: - contents: read - actions: write # Required for artifact upload - steps: - - name: Harden the runner (Audit all outbound calls) - uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1 - with: - egress-policy: audit - - - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 - - - name: Set up Rust - uses: actions-rust-lang/setup-rust-toolchain@9399c7bb15d4c7d47b27263d024f0a4978346ba4 # v1.11.0 - - - name: Cache builder binary - uses: actions/cache@2f8e54208210a422b2efd51efaa6bd6d7ca8920f # v3.4.3 - id: cache-builder - with: - path: ~/bin/builder - key: ${{ runner.os }}-builder-${{ inputs.builder_version }} - - - name: Build builder - if: steps.cache-builder.outputs.cache-hit != 'true' - run: | - unset CI - mkdir -p ~/bin - cd clients - BUILDER_VERSION=${{ inputs.builder_version }} OUTPUT_DIR=~/bin ./build-builder.sh - # Rename op-rbuilder to builder for consistency - [ -f ~/bin/op-rbuilder ] && mv ~/bin/op-rbuilder ~/bin/builder || true - - - name: Upload builder artifact - uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0 - with: - name: builder - path: ~/bin/builder - retention-days: 1 - build-base-reth-node: runs-on: ubuntu-latest permissions: @@ -201,20 +156,24 @@ jobs: - name: Set up Rust uses: actions-rust-lang/setup-rust-toolchain@9399c7bb15d4c7d47b27263d024f0a4978346ba4 # v1.11.0 - - name: Cache base-reth-node binary + - name: Cache base-reth-node binaries uses: actions/cache@2f8e54208210a422b2efd51efaa6bd6d7ca8920f # v3.4.3 id: cache-base-reth-node with: - path: ~/bin/base-reth-node + path: | + ~/bin/base-reth-node + ~/bin/base-builder key: ${{ runner.os }}-base-reth-node-${{ inputs.base_reth_node_version }} - - name: Build base-reth-node + - name: Build base-reth-node and base-builder if: steps.cache-base-reth-node.outputs.cache-hit != 'true' run: | unset CI mkdir -p ~/bin cd clients BASE_RETH_NODE_VERSION=${{ inputs.base_reth_node_version }} OUTPUT_DIR=~/bin ./build-base-reth-node.sh + # Rename base-builder to builder for consistency + [ -f ~/bin/base-builder ] && mv ~/bin/base-builder ~/bin/builder || true - name: Upload base-reth-node artifact uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0 @@ -223,6 +182,13 @@ jobs: path: ~/bin/base-reth-node retention-days: 1 + - name: Upload builder artifact + uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0 + with: + name: builder + path: ~/bin/builder + retention-days: 1 + build-op-program: runs-on: ubuntu-latest permissions: diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index da0f226..560ad89 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -71,7 +71,6 @@ jobs: with: optimism_version: 3019251e80aa248e91743addd3e833190acb26f1 geth_version: 6cbfcd5161083bcd4052edc3022d9f99c6fe40e0 - builder_version: 23f42c8e78ba3abb45a8840df7037a27e196e601 base_reth_node_version: main basic-benchmarks: diff --git a/.github/workflows/examples.yaml b/.github/workflows/examples.yaml index d4faf5d..1a7c75e 100644 --- a/.github/workflows/examples.yaml +++ b/.github/workflows/examples.yaml @@ -18,7 +18,6 @@ jobs: with: optimism_version: 3019251e80aa248e91743addd3e833190acb26f1 geth_version: 6cbfcd5161083bcd4052edc3022d9f99c6fe40e0 - builder_version: 23f42c8e78ba3abb45a8840df7037a27e196e601 base_reth_node_version: main example-benchmarks: diff --git a/.github/workflows/public-benchmarks.yaml b/.github/workflows/public-benchmarks.yaml index 7b8f579..4038cfc 100644 --- a/.github/workflows/public-benchmarks.yaml +++ b/.github/workflows/public-benchmarks.yaml @@ -18,7 +18,7 @@ jobs: with: optimism_version: 3019251e80aa248e91743addd3e833190acb26f1 geth_version: 6cbfcd5161083bcd4052edc3022d9f99c6fe40e0 - builder_version: 23f42c8e78ba3abb45a8840df7037a27e196e601 + base_reth_node_version: main basic-benchmarks: runs-on: ubuntu-latest diff --git a/Makefile b/Makefile index 10b0a4b..7c19f89 100644 --- a/Makefile +++ b/Makefile @@ -47,12 +47,12 @@ build-reth: build-geth: cd clients && ./build-geth.sh -.PHONY: build-builder -build-builder: - cd clients && ./build-builder.sh +.PHONY: build-base-reth-node +build-base-reth-node: + cd clients && ./build-base-reth-node.sh .PHONY: build-binaries -build-binaries: build-reth build-geth build-builder +build-binaries: build-reth build-geth build-base-reth-node .PHONY: build-frontend build-frontend: diff --git a/clients/README.md b/clients/README.md index 9e24a83..04ef9cf 100644 --- a/clients/README.md +++ b/clients/README.md @@ -20,11 +20,11 @@ Builds the op-geth binary from the Ethereum Optimism op-geth repository using ju - Version: `optimism` - Build tool: `go run build/ci.go install` -### build-builder.sh -Builds the builder binary from the op-rbuilder repository using Cargo. +### build-base-reth-node.sh +Builds the base-reth-node and base-builder binaries from the base repository using Cargo. **Default Configuration:** -- Repository: `https://github.com/base/op-rbuilder` +- Repository: `https://github.com/base/base` - Version: `main` - Build tool: `cargo` @@ -42,8 +42,8 @@ make build-reth # Build only geth make build-geth -# Build only builder -make build-builder +# Build base-reth-node and base-builder +make build-base-reth-node ``` ### Direct Script Execution @@ -56,8 +56,8 @@ cd clients # Build geth with defaults ./build-geth.sh -# Build builder with defaults -./build-builder.sh +# Build base-reth-node and base-builder with defaults +./build-base-reth-node.sh ``` ## Version Management @@ -75,7 +75,7 @@ Modify the `versions.env` file to change defaults for all builds: # Edit versions.env to update default versions OPTIMISM_VERSION="v0.2.0-beta.5" GETH_VERSION="v1.13.0" -BUILDER_VERSION="your-commit-hash" +BASE_RETH_NODE_VERSION="your-commit-hash" ``` #### 2. Environment Variables @@ -88,8 +88,8 @@ OPTIMISM_REPO="https://github.com/ethereum-optimism/optimism/" OPTIMISM_VERSION= # Build geth from a fork GETH_REPO="https://github.com/your-fork/op-geth/" GETH_VERSION="your-branch" ./build-geth.sh -# Build builder from a different commit -BUILDER_VERSION="main" ./build-builder.sh +# Build base-reth-node and base-builder from a different commit +BASE_RETH_NODE_VERSION="your-commit-hash" ./build-base-reth-node.sh ``` ### Available Environment Variables @@ -106,9 +106,9 @@ BUILDER_VERSION="main" ./build-builder.sh - `BUILD_DIR`: Directory for source code (default: ./build) - `OUTPUT_DIR`: Directory for built binaries (default: ../bin) -#### For builder (build-builder.sh): -- `BUILDER_REPO`: Git repository URL (default: https://github.com/base/op-rbuilder) -- `BUILDER_VERSION`: Git branch, tag, or commit hash (default: main) +#### For base-reth-node (build-base-reth-node.sh): +- `BASE_RETH_NODE_REPO`: Git repository URL (default: https://github.com/base/base) +- `BASE_RETH_NODE_VERSION`: Git branch, tag, or commit hash (default: main) - `BUILD_DIR`: Directory for source code (default: ./build) - `OUTPUT_DIR`: Directory for built binaries (default: ../bin) @@ -122,7 +122,7 @@ BUILDER_VERSION="main" ./build-builder.sh - Go toolchain - Git -### For builder: +### For base-reth-node: - Rust and Cargo installed - Git @@ -131,4 +131,5 @@ BUILDER_VERSION="main" ./build-builder.sh Built binaries will be placed in the `bin/` directory at the project root: - `bin/reth` - The reth binary - `bin/geth` - The op-geth binary -- `bin/op-rbuilder` - The builder binary +- `bin/base-reth-node` - The base reth node binary +- `bin/base-builder` - The builder binary diff --git a/clients/build-base-reth-node.sh b/clients/build-base-reth-node.sh index 8ea4a40..98d030b 100755 --- a/clients/build-base-reth-node.sh +++ b/clients/build-base-reth-node.sh @@ -13,7 +13,7 @@ BASE_RETH_NODE_VERSION="${BASE_RETH_NODE_VERSION:-main}" BUILD_DIR="${BUILD_DIR:-./build}" OUTPUT_DIR="${OUTPUT_DIR:-../bin}" -echo "Building base-reth-node binary..." +echo "Building base-reth-node and base-builder binaries..." echo "Repository: $BASE_RETH_NODE_REPO" echo "Version/Commit: $BASE_RETH_NODE_VERSION" echo "Build directory: $BUILD_DIR" @@ -42,13 +42,13 @@ fi echo "Checking out version: $BASE_RETH_NODE_VERSION" git checkout -f "$BASE_RETH_NODE_VERSION" -# Build the binary using cargo -echo "Building base-reth-node with cargo..." +# Build the binaries using cargo +echo "Building base-reth-node and base-builder with cargo..." # Build with maxperf profile -cargo build --bin base-reth-node --profile maxperf +cargo build --bin base-reth-node --bin base-builder --profile maxperf -# Copy binary to output directory -echo "Copying binary to output directory..." +# Copy binaries to output directory +echo "Copying binaries to output directory..." # Handle absolute paths correctly if [[ "$OUTPUT_DIR" == /* ]]; then # Absolute path - use directly @@ -59,7 +59,7 @@ else fi mkdir -p "$FINAL_OUTPUT_DIR" -# Find the built binary and copy it +# Find the built binaries and copy them if [ -f "target/maxperf/base-reth-node" ]; then cp target/maxperf/base-reth-node "$FINAL_OUTPUT_DIR/" else @@ -67,4 +67,11 @@ else exit 1 fi -echo "base-reth-node binary built successfully and placed in $FINAL_OUTPUT_DIR/base-reth-node" +if [ -f "target/maxperf/base-builder" ]; then + cp target/maxperf/base-builder "$FINAL_OUTPUT_DIR/" +else + echo "No base-builder binary found" + exit 1 +fi + +echo "base-reth-node and base-builder binaries built successfully and placed in $FINAL_OUTPUT_DIR/" diff --git a/clients/build-builder.sh b/clients/build-builder.sh deleted file mode 100755 index ae73fa0..0000000 --- a/clients/build-builder.sh +++ /dev/null @@ -1,70 +0,0 @@ -#!/bin/bash - -set -e - -# Source versions if available, otherwise use defaults -if [ -f "versions.env" ]; then - source versions.env -fi - -# Default values -BUILDER_REPO="${BUILDER_REPO:-https://github.com/base/op-rbuilder}" -BUILDER_VERSION="${BUILDER_VERSION:-main}" -BUILD_DIR="${BUILD_DIR:-./build}" -OUTPUT_DIR="${OUTPUT_DIR:-../bin}" - -echo "Building builder binary..." -echo "Repository: $BUILDER_REPO" -echo "Version/Commit: $BUILDER_VERSION" -echo "Build directory: $BUILD_DIR" -echo "Output directory: $OUTPUT_DIR" - -# Create build directory if it doesn't exist -mkdir -p "$BUILD_DIR" -cd "$BUILD_DIR" - -# Clone or update repository -if [ -d "op-rbuilder" ]; then - echo "Updating existing op-rbuilder repository..." - cd op-rbuilder - - # ensure remote matches the repository - git remote set-url origin "$BUILDER_REPO" - git fetch origin -else - echo "Cloning op-rbuilder repository..." - git clone "$BUILDER_REPO" op-rbuilder - cd op-rbuilder -fi - -# Checkout specified version/commit -echo "Checking out version: $BUILDER_VERSION" -git checkout -f "$BUILDER_VERSION" - -# Build the binary using cargo -echo "Building op-rbuilder with cargo..." -cargo build -p op-rbuilder --bin op-rbuilder --release - -# Copy binary to output directory -echo "Copying binary to output directory..." -# Handle absolute paths correctly -if [[ "$OUTPUT_DIR" == /* ]]; then - # Absolute path - use directly - FINAL_OUTPUT_DIR="$OUTPUT_DIR" -else - # Relative path - resolve from current location (clients/build/op-rbuilder) - FINAL_OUTPUT_DIR="../../$OUTPUT_DIR" -fi -mkdir -p "$FINAL_OUTPUT_DIR" - -# Find the built binary and copy it -if [ -f "target/release/op-rbuilder" ]; then - cp target/release/op-rbuilder "$FINAL_OUTPUT_DIR/" -elif [ -f "target/release/rbuilder" ]; then - cp target/release/rbuilder "$FINAL_OUTPUT_DIR/op-rbuilder" -else - echo "No op-rbuilder binary found" - exit 1 -fi - -echo "Builder binary built successfully and placed in $FINAL_OUTPUT_DIR/op-rbuilder" diff --git a/clients/versions.env b/clients/versions.env index 53ed4b5..536ac9a 100644 --- a/clients/versions.env +++ b/clients/versions.env @@ -10,10 +10,6 @@ OPTIMISM_VERSION="3019251e80aa248e91743addd3e833190acb26f1" GETH_REPO="https://github.com/ethereum-optimism/op-geth/" GETH_VERSION="v1.101604.0" -# Builder Configuration -BUILDER_REPO="https://github.com/base/op-rbuilder" -BUILDER_VERSION="main" - # Base Reth Node Configuration BASE_RETH_NODE_REPO="https://github.com/base/base" BASE_RETH_NODE_VERSION="main" From 4dbfe5d31a9df6f4e195ea89d8092ddd3dd67a49 Mon Sep 17 00:00:00 2001 From: Julian Meyer Date: Mon, 9 Mar 2026 04:16:48 -0700 Subject: [PATCH 3/4] fix: add missing --txpool.max-account-slots to base-reth-node client The base-reth-node client was missing the --txpool.max-account-slots flag that the reth client has, causing 'txpool is full' errors after only a few transactions from the same account. --- runner/clients/baserethnode/client.go | 1 + 1 file changed, 1 insertion(+) diff --git a/runner/clients/baserethnode/client.go b/runner/clients/baserethnode/client.go index c93cf89..844d33b 100644 --- a/runner/clients/baserethnode/client.go +++ b/runner/clients/baserethnode/client.go @@ -88,6 +88,7 @@ func (r *BaseRethNodeClient) Run(ctx context.Context, cfg *types.RuntimeConfig) // increase mempool size args = append(args, "--txpool.pending-max-count", "100000000") args = append(args, "--txpool.queued-max-count", "100000000") + args = append(args, "--txpool.max-account-slots", "100000000") args = append(args, "--txpool.pending-max-size", "100") args = append(args, "--txpool.queued-max-size", "100") From a3db98f917e3f45b49021a9ab8536a48b6a9f173 Mon Sep 17 00:00:00 2001 From: Julian Meyer Date: Mon, 9 Mar 2026 04:38:17 -0700 Subject: [PATCH 4/4] fix: cache builder binary under renamed path and bust stale cache Cache ~/bin/builder (post-rename) instead of ~/bin/base-builder so the builder artifact is available on cache hit. Update the cache key to invalidate the old cache that only contained base-reth-node. --- .github/workflows/_build-binaries.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/_build-binaries.yaml b/.github/workflows/_build-binaries.yaml index ba71d9a..a7bf7e5 100644 --- a/.github/workflows/_build-binaries.yaml +++ b/.github/workflows/_build-binaries.yaml @@ -162,8 +162,8 @@ jobs: with: path: | ~/bin/base-reth-node - ~/bin/base-builder - key: ${{ runner.os }}-base-reth-node-${{ inputs.base_reth_node_version }} + ~/bin/builder + key: ${{ runner.os }}-base-reth-node-builder-${{ inputs.base_reth_node_version }} - name: Build base-reth-node and base-builder if: steps.cache-base-reth-node.outputs.cache-hit != 'true' @@ -172,7 +172,6 @@ jobs: mkdir -p ~/bin cd clients BASE_RETH_NODE_VERSION=${{ inputs.base_reth_node_version }} OUTPUT_DIR=~/bin ./build-base-reth-node.sh - # Rename base-builder to builder for consistency [ -f ~/bin/base-builder ] && mv ~/bin/base-builder ~/bin/builder || true - name: Upload base-reth-node artifact