14037 Commits

Author SHA1 Message Date
Adrian Sutton
b9bbfdf372
ethapi: Omit isSystemTx: "false" from JSON-RPC responses (#60) 2023-03-03 17:08:47 -07:00
Joshua Gutow
13e42b01a4
Merge pull request #59 from ethereum-optimism/aj/fix-docker-build
ci: Fix docker build
2023-03-02 13:48:05 -08:00
Adrian Sutton
f12173d705
ci: Fix docker build 2023-03-03 07:14:19 +10:00
Joshua Gutow
8c8557b333
Multi-arch docker build (#58) 2023-03-02 09:25:22 -07:00
Adrian Sutton
c407b2a217 core: Schedule Regolith on Optimism Goerli at 1679079600 2023-03-02 09:23:22 +10:00
Adrian Sutton
88e99a8481 core: Log a warning when optimism enabled but regolith not scheduled 2023-02-28 10:07:51 +10:00
Adrian Sutton
0705cf1b7d ethapi,core/types: Include the actual nonce used when returning deposit tx from the JSON RPC API
Adds the EffectiveNonce method to Transaction which returns the actual nonce used when executing the transaction (if known).
2023-02-28 09:02:09 +10:00
Roman Krasiuk
626cc88c07
Fix Regolith test name typo (#56) 2023-02-27 11:05:22 -07:00
Adrian Sutton
7303e2be73 Reject system deposit transactions in Regolith 2023-02-24 09:35:37 +10:00
Adrian Sutton
7643709fe8 core: Report actual gas used for deposit transactions in Regolith 2023-02-24 09:20:01 +10:00
Adrian Sutton
bc0cca3223 feat(core/types,internal/ethapi): In regolith, record the actual nonce used for deposit transactions
The nonce is available as DepositNonce on the receipt and is used to calculate the correct ContractAddress.
2023-02-24 08:52:52 +10:00
Adrian Sutton
2864f90ac0
Include 0 values for v,r,s and gasPrice on deposit transactions (#48)
When serializing deposit transactions for RPC responses, provide 0 values for v, r, s and gasPrice instead of null to improve compatibility with existing parsing code.
2023-02-22 20:48:53 -07:00
Adrian Sutton
5ff481f95c
feat: Add support for Regolith in chain configuration (#50) 2023-02-22 20:47:55 -07:00
Adrian Sutton
aea040245e Remove unused variable to fix linter 2023-02-23 08:17:51 +10:00
protolambda
2703b41ad6
forkdiff: update fork-diff to generate post-v1.11.2 rebase diff (#47) 2023-02-22 14:32:24 -07:00
protolambda
12d2112465
miner: optimism block building fix - no extra data
Ensure extra-data can be set in L1 mode, but do not include any
extra-data when building a L2 optimism chain.

Co-authored-by: Adrian Sutton <adrian@oplabs.co>
2023-02-22 09:49:45 -06:00
protolambda
e9f8da9ca4
params/config: rename optimism test config 2023-02-22 09:49:45 -06:00
Adrian Sutton
4866fed4e5
Remove underscores from test names 2023-02-22 09:49:45 -06:00
Adrian Sutton
07514fc780
Use table test and further improve coverage 2023-02-22 09:49:44 -06:00
Adrian Sutton
d25f374756
Fix comparisons and update tests to cover both 0 and nil values 2023-02-22 09:49:44 -06:00
Adrian Sutton
e277a13fbd
Make deposit tx parsing more flexible
Allow either nil or 0 values for v, r, s and GasPrice.
Add a test to ensure deposit tx json can be round-tripped.
2023-02-22 09:49:44 -06:00
Adrian Sutton
b4d324ce9b
fix: Require gas field when unmarshalling deposit tx JSON (#43) 2023-02-22 09:49:44 -06:00
inphi
7e39eb5c5b
optimism: Add --rollup.historicalrpctimeout flag
This flag lets one configure the initial timeout of RPC requests to the
historical RPC service.

Fixes ENG-3294
2023-02-22 09:49:44 -06:00
Matthew Slipper
3518fe99f6
ethapi/api: updates to optimism daisy chain post-testing 2023-02-22 09:49:44 -06:00
Mark Tyneway
459d1342bb
op-geth: more daisychain routing
Adds the following RPC endpoints to the daisychain usage:

- `eth_getBalance`
- `eth_getProof`
- `eth_getCode`
- `eth_getStorageAt`
- `eth_getTransactionCount`
2023-02-22 09:49:43 -06:00
protolambda
8ba567f82b
optimism: minor goerli fixes - banner, clique config, networkid (#36) 2023-02-22 09:49:43 -06:00
protolambda
e2e6188144
fork.yaml: document op-geth changes with forkdiff (#35)
* fork.yaml: document op-geth changes

* forkdiff gh-pages action

Co-authored-by: Matthew Slipper <me@matthewslipper.com>
2023-02-22 09:49:43 -06:00
protolambda
ffcd75be7d
optimism: user can set pending block gas limit (#24) 2023-02-22 09:49:43 -06:00
Joshua Gutow
ac785740c5
Change fallback error 2023-02-22 09:49:43 -06:00
Joshua Gutow
d475ef4015
Remove debug_traceCall historical test 2023-02-22 09:49:43 -06:00
Joshua Gutow
e3dbaab7a9
eth/tracers: make unit tests work with historical backend 2023-02-22 09:49:43 -06:00
Joshua Gutow
7b0b80f0e6
Disable daisy chain for debug_traceCall 2023-02-22 09:49:42 -06:00
Joshua Gutow
76789ddaaf
Use chainconfig + add historical error
This routes historical errors based on the chain config.
2023-02-22 09:49:42 -06:00
Joshua Gutow
6b41815cb5
Add bedrock fork block & overrides (#31)
This enables two overrides: the bedrock fork block & the optimism config
being set. The optimism override uses the default EIP 1559 parameters.

These make it easy to setup a node in optimism mode & have a configurable
bedrock block.

All of the rules accessors are also helpful for checking which mode the
node is running in.
2023-02-22 09:49:42 -06:00
Mark Tyneway
ca8bbd6cf5
core/types: add legacy receipt deserialization (#28)
Receipts in `l2geth` are stored with L1 fee data to prevent
the need of having an archive node for historical L1 fee data.

91a80d2872/l2geth/core/types/receipt.go (L247)

This ports the deserialization of the legacy `l2geth` style
serialization to `op-geth`. This is required for nodes that upgrade
using the db migration tool.
2023-02-22 09:49:42 -06:00
Michael de Hoog
28c13bd98d
Fix panics in debug_TraceTransaction (#27)
* Make sure L1CostFunc is set on returned context

* Fix panic if HistoricalRPCService is not set

* Can we just return nil?

* Simplify
2023-02-22 09:49:42 -06:00
Joshua Gutow
c48b8aab5a
optimism: historical Bedrock geth rollup changes
This commit squashes the op-geth fork history into a more maintainable
diff for rebasing upon upstream geth.

reference-optimistic-geth changes (origins of op-geth in early Bedrock
development stage):
- Deposit TX Type
- Enable deposit tx in EVM/tx pool
- Change deposit nonce to not be the max nonce
- Extend PayloadAttributesV1 with a Transactions field
- Force deposits at the start of each L2 block
- Fix height check
- noTxPool flag, reproduce block in verifier mode without tx pool interference
- Fix RPC json marshalling (ref op-geth PR 4)
- Deposit txs block height check in block body validation (ref op-geth PR 5)
- core: do not try to reinject deposit txs into tx-pool (ref-op-geth PR 6)
- deposit source hash field instead of L2 block height and tx index combination
- Include invalid deposits, rewind state, but always persist mint (#10)
- Provide gas to Call/Create in deposit transactions (#12)
- Add docker builds (ref-op-geth PR 16, 17)
- Don't panic on deposit transaction signature values or chain ID (ref-op-geth PR 18)
- core: Add version to DepositTx (ref-op-geth PR 19)
- Enable Geth build/lint/test in CircleCI (ref-op-geth PR 23)
- core: Include guaranteed gas in the gas pool (ref-op-geth PR 21)
- core: handle base fee, l1 availability fee, tx fee (ref-op-geth PR 27)
- fix: deposit tx hash
- fix l1 fee cache, rpc, tracing and tx pool
- core: remove deposit-tx sub-type (a.k.a. deposit version byte)
- eth/catalyst: allow engine user to reorg own chain
- miner: restore ability to reorg deep as block builder
- params: print Optimism consensus type in banner
- core/types: remove unused protected() method, see upstream PR 23376
- core: do not mutate original balance value in tx pool l1 cost adjustment
- core: subtract deposit gas from pool, so other txs do not use the same gas. And fail tx processing if deposits reach gas limit
- core/types: deposits do not tip, avoid basefee subtraction
- Unmeter the L1 Attributes Transaction
- miner: handle force tx errors as critical, clean up diff
- ci: Switch branch
- eth,miner: return STATUS_INVALID when failing to process forced transactions in request (ref-op-geth PR 40)
- verifier: forward tx to sequencer based on flag
- txpool: add flag to disable tx gossip (ref-op-geth PR 42)
- Add op-geth version in addition to geth version (ref-op-geth PR 43)
- ci: CircleCI improvements (ref-op-geth PR 44)
- Rename to op-geth
- Build latest tag on optimism branch

op-geth changes:
- Expose cache config in simulated backend (#2)
- Add EIP-1559 parameters
- eth/catalyst: update payload id computation (#1)
- make eip1559 configurable (#4)
- post-merge network should not log warnings about missing transition information (#5)
- Make the simulator more configurable (#6)
- fix OPB-6 - IsDepositTx check instead of artificial nonce value check (#7)
- Simulated backend - enable proof of stake consensus type and fix performance issue (#8)
- accounts: simulated backend consensus engine option and immediate tx indexing
- consensus/beacon: recognize all blocks as reached TTD with 0 TTD in chain config
- Add --rollup.historicalhttp CLI flag and fix backend iface
- Flags and interfaces for historical RPC requests (#12)
- Redirect historical RPC requests (#13)
- Use the pre-existing ethereum.NotFound error (#18)
- Add historical endpoint to TraceBlockByNumber and TraceBlockByHash (#19)
- Add historical endpoint to TraceTransaction (#20)
- Add historical endpoint to TraceCall (#21)
- optimism: fee params from info txi, update l1 cost func GPO params read (#15)
- add hardcoded addresses for fee payouts (#23)
- dynamic gas limit via engine API (#22)

Co-authored-by: Matthew Slipper <me@matthewslipper.com>
Co-authored-by: Joshua Gutow <jgutow@oplabs.co>
Co-authored-by: protolambda <proto@protolambda.com>
Co-authored-by: Mark Tyneway <mark.tyneway@gmail.com>
Co-authored-by: Maurelian <maurelian@protonmail.ch>
2023-02-22 09:49:38 -06:00
Péter Szilágyi
73b01f40ce params: release Geth v1.11.2 2023-02-22 14:23:51 +02:00
Péter Szilágyi
f86f048646
common/math: allow HexOrDecimal to accept unquoted decimals too (#26758) 2023-02-22 13:55:09 +02:00
Yier
4034c675be
eth/filters: fix a breaking change and return rpctransaction (#26757)
* eth/filters: fix a breaking change and return rpctransaction

* eth/filters: fix test cases

---------

Co-authored-by: Catror <me@catror.com>
2023-02-22 13:06:43 +02:00
rjl493456442
fe01a2f63b
all: use unified emptyRootHash and emptyCodeHash (#26718)
The EmptyRootHash and EmptyCodeHash are defined everywhere in the codebase, this PR replaces all of them with unified one defined in core/types package, and also defines constants for TxRoot, WithdrawalsRoot and UncleRoot
2023-02-21 06:12:27 -05:00
Péter Szilágyi
2f20fd31ee
core/rawdb: expose chain freezer constructor without internals (#26748) 2023-02-21 13:10:01 +02:00
Martin Holst Swende
6d2d126100
core: fix accessor mismatch for genesis state (#26747) 2023-02-21 12:18:33 +02:00
Péter Szilágyi
90d25514af
core, eth: merge snap-sync chain download progress logs (#26676) 2023-02-21 12:17:34 +02:00
Sungwoo Kim
7d4db69607
cmd/geth: clarify dumpconfig options (#26729)
Clarifies the documentation around dumpconfi

Signed-off-by: Sungwoo Kim <git@sung-woo.kim>
2023-02-21 02:35:04 -05:00
rjl493456442
13ef21d467
Revert "core/trie: remove trie tracer (#26665)" (#26732)
This reverts commit 7c749c947a9d5181f5f2c1b3fdb5ea6b0e401e8e.
2023-02-20 09:54:52 -05:00
Péter Szilágyi
ba4267fcac build: enable Lunar Lobster PPA builds 2023-02-20 13:26:37 +02:00
Péter Szilágyi
41dee2623e build: fix Go 1.19.0 bootstrapper issues on 386 PPA 2023-02-20 12:36:46 +02:00
Péter Szilágyi
4519054816 build: fix (finaly?) the PPA env vars for Go bootstrapping 2023-02-20 11:31:19 +02:00
Péter Szilágyi
c02334be1e build: yet another weird PPA fix 2023-02-20 11:07:33 +02:00