Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimism miner_setMaxDASize call should return bool type #13422

Closed
1 task done
SangyunOck opened this issue Dec 17, 2024 · 0 comments · Fixed by #13423
Closed
1 task done

Optimism miner_setMaxDASize call should return bool type #13422

SangyunOck opened this issue Dec 17, 2024 · 0 comments · Fixed by #13423
Labels
C-bug An unexpected or incorrect behavior S-needs-triage This issue needs to be labelled

Comments

@SangyunOck
Copy link
Contributor

Describe the bug

ref: alloy-rs/op-alloy#346

Motivation

While op-batcher tries to set SetMaxDASize by calling miner_setMaxDASize of op-reth, returns error
ERROR[12-17|18:17:23.568] Result of SetMaxDASize was false, retrying.

Original golang implementation of op-geth returns bool type, op-batcher expects true for the result, or treat as error for others, including null.

expects

{
  "jsonrpc": "2.0",
  "id": 0,
  "result": true
}

as-is

{
  "jsonrpc": "2.0",
  "id": 0,
  "result": null
}

Solution

Change set_max_da_size return type from RpcResult<()> to RpcResult<bool>
https://github.com/paradigmxyz/reth/blob/main/crates/optimism/rpc/src/miner.rs#L27

Steps to reproduce

  1. follow the guild of Optimism to set a private rollup network

  2. compile op-reth

make install-op
  1. run op-node
./bin/op-node \
  --l2=http://localhost:8551 \
  --l2.jwt-secret=./jwt.txt \
  --sequencer.enabled \
  --sequencer.l1-confs=5 \
  --verifier.l1-confs=4 \
  --rollup.config=./rollup.json \
  --rpc.addr=0.0.0.0 \
  --p2p.disable \
  --rpc.enable-admin \
  --p2p.sequencer.key=$GS_SEQUENCER_PRIVATE_KEY \
  --l1=$L1_RPC_URL \
  --l1.rpckind=$L1_RPC_KIND \
  --l2.enginekind=reth
  1. run op-reth
op-reth node \
  --datadir ./datadir \
  --disable-discovery \
  --chain ./genesis.json \
  --http \
  --http.corsdomain="*" \
  --http.addr=0.0.0.0 \
  --max-inbound-peers=0 \
  --http.api=web3,debug,eth,txpool,net,miner \
  --ws \
  --ws.addr=0.0.0.0 \
  --ws.port=8546 \
  --ws.origins="*" \
  --ws.api=debug,eth,txpool,net,miner \
  --authrpc.addr=0.0.0.0 \
  --authrpc.port=8551 \
  --authrpc.jwtsecret=./jwt.txt \
  --rollup.disable-tx-pool-gossip
  1. run op-batcher
./bin/op-batcher \
  --l2-eth-rpc=http://localhost:8545 \
  --rollup-rpc=http://localhost:9545 \
  --poll-interval=1s \
  --sub-safety-margin=6 \
  --num-confirmations=1 \
  --safe-abort-nonce-too-low-count=3 \
  --resubmission-timeout=30s \
  --rpc.addr=0.0.0.0 \
  --rpc.port=8548 \
  --rpc.enable-admin \
  --max-channel-duration=25 \
  --l1-eth-rpc=$L1_RPC_URL \
  --private-key=$GS_BATCHER_PRIVATE_KEY

watch logs says SetMaxDASize rpc failed, retrying.

Node logs


Platform(s)

Mac (Apple Silicon)

Container Type

Not running in a container

What version/commit are you on?

1.1.4

What database version are you on?

.

Which chain / network are you on?

private(genesis by getting start guide of Optimism docs)

What type of node are you running?

Archive (default)

What prune config do you use, if any?

No response

If you've built Reth from source, provide the full command you used

make install-op

Code of Conduct

  • I agree to follow the Code of Conduct
@SangyunOck SangyunOck added C-bug An unexpected or incorrect behavior S-needs-triage This issue needs to be labelled labels Dec 17, 2024
@github-project-automation github-project-automation bot moved this from Todo to Done in Reth Tracker Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug An unexpected or incorrect behavior S-needs-triage This issue needs to be labelled
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

1 participant