Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
4277650
consolidate test scripts
cliff0412 Oct 14, 2025
fd6398c
refactor
cliff0412 Oct 14, 2025
340b652
Merge branch 'pre-release' into testnet_migration
cliff0412 Oct 14, 2025
e256231
resolve conflicts
cliff0412 Oct 14, 2025
2146987
fix build op contracts
cliff0412 Oct 14, 2025
d70b357
fix op_stack image build
cliff0412 Oct 14, 2025
33c4c1a
use dev for op-geth
cliff0412 Oct 14, 2025
68a0dea
fix setGasToken
cliff0412 Oct 14, 2025
dd072a2
remove SystemConfig UpdateType GAS_PAYING_TOKEN event
doutv Oct 14, 2025
b11f774
refactoring
cliff0412 Oct 14, 2025
d9f11cd
Merge remote-tracking branch 'origin/testnet_migration' into testnet_…
cliff0412 Oct 14, 2025
dffc9be
fix typo
doutv Oct 14, 2025
13cacd7
fix sysconfig
cliff0412 Oct 14, 2025
f6bfa4c
Merge branch 'testnet_migration' of github.com:okx/optimism into test…
cliff0412 Oct 14, 2025
41a74ba
refactoring
cliff0412 Oct 14, 2025
d24d6b9
add patch
cliff0412 Oct 14, 2025
a02942d
fix: build image sequence
Oct 15, 2025
2b7cd75
feat: add cdk image env
Oct 15, 2025
02c901f
feat: set ARCH to default value using docker cmd
Oct 15, 2025
e0c8eb3
update testnet genesisGasParameters and readme
cliff0412 Oct 15, 2025
ec6dca7
Merge branch 'testnet_migration' of github.com:okx/optimism into test…
cliff0412 Oct 15, 2025
ebc1fc2
use gopath for install go bin
cliff0412 Oct 15, 2025
9c5ba7c
add cgt_enable (#66)
cliff0412 Oct 15, 2025
874ee68
Update testnet readme steps
Vui-Chee Oct 16, 2025
c985a09
put migration into separate file
cliff0412 Oct 16, 2025
f2af80b
refactor l1-geth
cliff0412 Oct 16, 2025
d4625e1
merge dev
cliff0412 Oct 16, 2025
b4f8bec
Merge remote-tracking branch 'origin/pre-release' into testnet_migration
cliff0412 Oct 16, 2025
135fe9d
merge with pre-release
cliff0412 Oct 16, 2025
660538e
refactor
cliff0412 Oct 16, 2025
0c207e9
sync op-geth
cliff0412 Oct 16, 2025
5f14698
update testnet readme for regenesis
Vui-Chee Oct 16, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions Dockerfile-contracts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,13 @@ RUN --mount=type=cache,target=/root/.cache \
FROM debian:bookworm-slim
WORKDIR /app

# Update certificates
RUN apt-get update && apt-get install -y ca-certificates && update-ca-certificates

# Set environment variables for Go
ENV SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt
ENV SSL_CERT_DIR=/etc/ssl/certs

# Copy foundry tools for runtime use
COPY --from=contracts-builder /usr/local/bin/forge /usr/local/bin/cast /usr/local/bin/anvil /usr/local/bin/

Expand Down
6 changes: 0 additions & 6 deletions op-node/rollup/derive/system_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"bytes"
"errors"
"fmt"
"log/slog"

"github.com/hashicorp/go-multierror"

Expand All @@ -25,7 +24,6 @@ var (
SystemConfigUpdateEIP1559Params = common.Hash{31: 4}
SystemConfigUpdateOperatorFeeParams = common.Hash{31: 5}
SystemConfigUpdateMinBaseFee = common.Hash{31: 6}
SystemConfigUpdateGasPayingToken = common.Hash{31: 7}
)

var (
Expand Down Expand Up @@ -196,10 +194,6 @@ func ProcessSystemConfigUpdateLogEvent(destSysCfg *eth.SystemConfig, ev *types.L
}
destSysCfg.MinBaseFee = minBaseFee
return nil
case SystemConfigUpdateGasPayingToken:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why delete these code?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

after discussion with louis & jason.huang,this is one time event only and only can be OKB, so we delete. shall we add back? we can discuss

evBytes, _ := ev.MarshalJSON()
slog.Default().Info("ignoring L1 sysCfg update to gas-paying token", "txHash", ev.TxHash, "event", string(evBytes))
return nil
default:
return fmt.Errorf("unrecognized L1 sysCfg update type: %s", updateType)
}
Expand Down
6 changes: 1 addition & 5 deletions packages/contracts-bedrock/src/L1/SystemConfig.sol
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ contract SystemConfig is ProxyAdminOwnedBase, OwnableUpgradeable, Reinitializabl
UNSAFE_BLOCK_SIGNER,
EIP_1559_PARAMS,
OPERATOR_FEE_PARAMS,
MIN_BASE_FEE,
GAS_PAYING_TOKEN
MIN_BASE_FEE
}

/// @notice Struct representing the addresses of L1 system contracts. These should be the
Expand Down Expand Up @@ -618,8 +617,5 @@ contract SystemConfig is ProxyAdminOwnedBase, OwnableUpgradeable, Reinitializabl
/// @param _symbol The symbol of the gas paying token as a bytes32.
function _setGasPayingToken(address _token, uint8 _decimals, bytes32 _name, bytes32 _symbol) internal {
GasPayingToken.set(_token, _decimals, _name, _symbol);

bytes memory data = abi.encode(_token, _decimals, _name, _symbol);
emit ConfigUpdate(VERSION, UpdateType.GAS_PAYING_TOKEN, data);
}
}
13 changes: 13 additions & 0 deletions test-pp-op/0-all-local.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/bash
set -e

# ./build_images.sh --all # build all images. add --force if want to force rebuild
make clean
cp local.env .env
./1-start-erigon.sh
./2-deploy-op-contracts.sh
./3-stop-erigon.sh
./4-migrate-op.sh
./5-start-op.sh
./6-build-op-program.sh
./7-setup-fraud-proof.sh
60 changes: 60 additions & 0 deletions test-pp-op/1-start-erigon.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
#!/bin/bash
set -e
set -x

if ! [ -f .env ]; then
echo "need to provide .env file"
fi

source .env
source tools.sh

if [ "$ENV" = "local" ]; then
COMPOSE_FILE="docker-compose-local.yml"
else
COMPOSE_FILE="docker-compose.yml"
fi

DOCKER_COMPOSE=$(shell docker compose version >/dev/null 2>&1 && echo "docker compose" || echo "docker-compose")
DOCKER_COMPOSE_CMD="${DOCKER_COMPOSE} -f ${COMPOSE_FILE}"
echo ${DOCKER_COMPOSE_CMD}

# 1. setup l1
# 2. run & init erigon pp
start_local_xlayer_erigon() {
export ENV=local
make run_erigon
sleep 3
# Calculate addresses for all actors
OP_BATCHER_ADDR=$(cast wallet a $OP_BATCHER_PRIVATE_KEY)
OP_PROPOSER_ADDR=$(cast wallet a $OP_PROPOSER_PRIVATE_KEY)
OP_CHALLENGER_ADDR=$(cast wallet a $OP_CHALLENGER_PRIVATE_KEY)

# Wait for L1 node to finish syncing
while [[ "$(cast rpc eth_syncing --rpc-url $L1_RPC_URL)" != "false" ]]; do
echo "Waiting for node to finish syncing..."
sleep 1
done

# Fund all actor addresses
for addr in $OP_BATCHER_ADDR $OP_PROPOSER_ADDR $OP_CHALLENGER_ADDR; do
cast send --private-key $RICH_PRIVATE_KEY --value 100ether $addr --legacy --rpc-url $L1_RPC_URL
done
}

setup_xlayer_erigon() {
if [ "$ENV" = "local" ]; then
echo "Starting local environment setup..."
start_local_xlayer_erigon
elif [ "$ENV" = "testnet" ]; then
echo "Starting ${ENV} environment setup..."
echo "not implemented"
exit 1
else
echo "Starting ${ENV} environment setup..."
echo "not implemented"
exit 1
fi
}

setup_xlayer_erigon
Loading