Péter Garamvölgyi
caec0c34fa
fix(worker): set default account fetch limit ( #756 )
2024-05-17 19:17:43 +02:00
Ömer Faruk Irmak
12871c7745
feat(worker): try to limit the number of txns miner has to deal with ( #745 )
...
to reduce the effect of having a huge backlog on performance
2024-05-13 09:20:55 +03:00
Péter Garamvölgyi
037781a187
feat(worker): disable enforceTips when fetching pending transactions ( #740 )
...
* Update worker.go
* chore: auto version bump [bot]
---------
Co-authored-by: Thegaram <Thegaram@users.noreply.github.com>
2024-05-06 10:04:16 +08:00
HAOYUatHZ
c5836a42d3
docs(miner): rename circuitCapacityReached to circuitCapacityOrBlockTimeReached ( #724 )
...
* docs(miner): rename `circuitCapacityReached` to `ccOrBtReached`
* minor
* rename `ccOrBtReached` to `circuitCapacityOrBlockTimeReached`
2024-04-28 16:27:52 +08:00
Nazarii Denha
3592139384
(feat)all: add EIP-1153 - transient storage ( #721 )
...
* all: implement EIP-1153 transient storage (#26003 )
Implements TSTORE and TLOAD as specified by the following EIP:
https://eips.ethereum.org/EIPS/eip-1153
https://ethereum-magicians.org/t/eip-1153-transient-storage-opcodes/553
Co-authored-by: Sara Reynolds <snreynolds2506@gmail.com>
Co-authored-by: Martin Holst Swende <martin@swende.se>
Co-authored-by: Gary Rong <garyrong0905@gmail.com>
* core/vm: move TSTORE,TLOAD to correct opcode nums (#27613 )
* core/vm: move TSTORE,TLOAD to correct opcode nums
* core/vm: cleanup
* fix tests, rename
* goimports
* enable 1153 at Curie
* bump version
* comment fix
* improve test
* version
* testchainconfig
* fix another test that affects newly added
* fix previous test to clenaup after
---------
Co-authored-by: Mark Tyneway <mark.tyneway@gmail.com>
Co-authored-by: Sara Reynolds <snreynolds2506@gmail.com>
Co-authored-by: Martin Holst Swende <martin@swende.se>
Co-authored-by: Gary Rong <garyrong0905@gmail.com>
Co-authored-by: Marius van der Wijden <m.vanderwijden@live.de>
2024-04-28 15:59:26 +08:00
Péter Garamvölgyi
62926d4649
feat(worker): seal block early if we're over target block time ( #706 )
...
* feat(worker): seal block early if we're over target block time
* use current.header.Time
* typo
* break instead of return
2024-04-18 10:44:59 +08:00
colin
d81a3308b1
feat(worker): add a commit tx failed metric ( #704 )
...
* feat(worker): add a commit tx failed metric
* bump version
* add number of L1 messages metric
2024-04-17 18:32:00 +08:00
georgehao
678a9fcb69
feat: add more state_transition, worker, and tracing metrics ( #700 )
...
* feat: add transactions len metrics of block processer
* feat: (worker): add metrics
* feat: add commitTransaction loops
* feat: add metrics to rollup tracing
* feat: add metrics to getTxResult
* feat: bump version
* add state revert metric timer
* feat: add commitNewWrok metrics
* feat: fix comments
* feat: remove the consume part metrics
* feat: update
* Apply suggestions from code review
Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
* feat: update
* feat: address comments
* chore: auto version bump [bot]
* feat: bump version
* add tests
* Revert "add tests"
This reverts commit 175d544a68fc964dcc062b46c1a010ed821a0996.
---------
Co-authored-by: Ömer Faruk Irmak <omerfirmak@gmail.com>
Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
Co-authored-by: georgehao <georgehao@users.noreply.github.com>
Co-authored-by: colinlyguo <colinlyguo@scroll.io>
2024-04-16 16:05:21 +08:00
Péter Garamvölgyi
0f0cd99f7a
feat: update upcoming fork names ( #680 )
...
* feat: update upcoming fork names
* bump version
* Apply suggestions from code review
Co-authored-by: Nazarii Denha <dengaaa2002@gmail.com>
* bump version
---------
Co-authored-by: Nazarii Denha <dengaaa2002@gmail.com>
2024-03-26 14:41:32 +00:00
Péter Garamvölgyi
ccec84ce63
feat: re-enable EIP-1559 in Banach hard fork ( #634 )
...
* feat: re-enable EIP-1559 in Banach hard fork
* enable BASEFEE opcode
* do not double gas limit on Banach fork block
* do not burn base fee
* update base fee calculation logic
* fix gas price oracle
* fix ethapi backend
* typo
* reorder worker code
* update genesis base fee
* add MaximumL2BaseFee
* add base fee metrics
* handle nil base fee
* revert state-transition change
* bump version
* remove TODO
* update test
* fix typo
* fix typo
* update traces
* fix test
* update london to banach
* handle error
* bump version
* bump version
2024-03-11 13:57:52 +00:00
HAOYUatHZ
88349c600d
feat: add mux tracer for native call tracer and native prestate tracers ( #615 )
...
* hack to use native tracers
* update
* fix
* add prestate
* fix marshal
* format
* draft
* move
* separate `MuxTracer`
* fix
* update miner/worker.go
* update api
* rename
* remove
* bump go version
* bump golangci
* goimports lint
* fix tests
* minor
* clean up
* fix tests
* sync error handling
* bump go version in Dockerfiles
* bump version
* lint: disable `goconst` & `goimports`
* bump version again
* add comments
---------
Co-authored-by: lightsing <light.tsing@gmail.com>
2024-01-18 14:58:27 +08:00
HAOYUatHZ
640b39161c
feat: remove instead of pop insufficient-funds tx ( #608 )
...
* feat: remove instead of pop insufficient-funds tx
* bump version
* update
* update
2023-12-26 00:47:39 +08:00
HAOYUatHZ
833f9041bb
feat: improve balance check ( #607 )
...
* feat: improve balance check
* clean up
2023-12-26 00:09:41 +08:00
Péter Garamvölgyi
3f9b23d33e
fix(worker): prioritize overflow tx as first tx in next block ( #563 )
...
* fix(worker): prioritize overflow tx as first tx in next block
* add tests
* bump version
2023-11-14 20:06:16 +01:00
vyzo
65a3a7fc23
Add metrics around block commit, block traces, and CCC ( #552 )
...
* Add metrics around block commit, block traces, and CCC
* add timer.Time wrapper
* more traces
* bump version
* bump version
---------
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
2023-11-09 14:24:00 +01:00
DongXi Huang
a8a9dc83cb
perf(miner): reduce rawdb calls for getting StartL1QueueIndex when inniting environment ( #550 )
...
Reduce rawdb calls
2023-11-08 14:40:20 +01:00
Steven
7cebee85a8
fix(libzkp): upgrade libzkp to v0.9.4 and add ccc SetLightMode ( #522 )
...
* Upgrade to prover `v0.9.4`, and add `SetLightMode` function.
* set ccc light_mode = false for validator
* fix
* bump version
---------
Co-authored-by: Zhang Zhuo <mycinbrin@gmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
2023-10-03 15:42:54 +02:00
Péter Garamvölgyi
93a9497d75
refactor(worker): order L1 messages by queue index ( #512 )
...
* refactor(worker): order L1 messages by queue index
* bump version
* bump version
2023-09-18 10:34:51 +02:00
Péter Garamvölgyi
530830a01c
fix(worker): check gas limit before running ccc ( #511 )
...
Co-authored-by: maskpp <maskpp266@gmail.com>
2023-09-13 16:19:14 +02:00
Steven
7d79f27e6f
fix (libzkp): check tx num when CCC ErrUnknown error occurred ( #505 )
...
* Check tx num for CCC ErrUnknown error.
* Update worker.go
* Small fix.
* Update
* Fix log.
* Update version.
* Update miner/worker.go
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* Update according to review.
* Fix to return 0 for uint64.
* Add `tcount` to mock CCC, and function `SetTxNum`.
* refactor
* fix
* add comments
---------
Co-authored-by: Zhang Zhuo <mycinbrin@gmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
Co-authored-by: HAOYUatHZ <haoyu@protonmail.com>
2023-09-08 13:17:02 +02:00
HAOYUatHZ
0b6c3be40d
feat(api/rawdb): allow storing traces for skipped txs ( #500 )
2023-09-05 11:03:15 +08:00
Xinran
24d856758b
feat(metrics): add skipped txs metrics for miner ( #494 )
2023-08-31 11:04:25 +08:00
HAOYUatHZ
ea3a3c9a5d
fix(miner): fix repeatedly processing dropped txs in a new block ( #491 )
...
* squash
* improve comments
* Remove tx (#493 )
* force drop
* minor
* store skipped L2 tx for `circuitcapacitychecker.ErrUnknown`
* Update miner/worker.go
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* add lock
* use mu
---------
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
2023-08-30 14:38:04 +08:00
HAOYUatHZ
f883dcdc21
docs(ccc): add more logs for skipping msg ( #490 )
...
* docs(ccc): add more logs for skipping msg
* bump version
* format codes
* improve
2023-08-29 08:05:27 +08:00
HAOYUatHZ
d650299a36
feat(miner): consider l1msg in txCount ( #486 )
...
* feat(miner): consider l1msg in txCount
* refactor
* tweak
* fix comments
* fix unit test
* set chainConfig.Scroll.MaxTxPerBlock in l1 message test
* add a skipped tx in TestAcceptableTxlimit
* add l1 skipped msg in test
* fix unit test
* fix unit test
* Update miner/worker.go
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* revert some test changes
* tweak
* bump version
---------
Co-authored-by: colinlyguo <colinlyguo@scroll.io>
Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
2023-08-27 00:08:04 +08:00
Péter Garamvölgyi
7de261b1be
feat: store skipped transactions in local db ( #467 )
...
* feat: store skipped txs in local db
* bump version
* bump version
* fix test
* include L2 txs in skipped index
* goimports
* rename more
* bump version
* fix missed renames
* fix the bug when calculating l2TxCount. (#479 )
* fix bug when calculate l2 tx count
* Update version
* fix: exclude L1 message from block payload size validation (#476 )
* fix: exclude L1 message from block payload size validation
* fix the bug when calculating l2TxCount. (#479 )
* fix bug when calculate l2 tx count
* Update version
* bump version
---------
Co-authored-by: maskpp <maskpp266@gmail.com>
* fix: update row estimation with scroll-prover `v0.7.2` (#475 )
* Fix row estimation.
* Update libzkp.
* more
* prepare
* finish
* upgrade
* bump version
* fix tests
* Update to scroll-prover `v0.7.2`.
* fix tests
* Update miner/worker.go
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* Update miner/worker.go
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* Reset ccc when skips first tx.
* do not unnecessarily skip L1 message
* fix ccc reset and improve code readability
* seal block on circuitcapacitychecker.ErrUnknown
---------
Co-authored-by: HAOYUatHZ <haoyu@protonmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* refactor: simplify ccc revert to snapshot (#480 )
* simplify ccc revert to snapshot
* Update version.go
---------
Co-authored-by: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com>
* feat: use --gcmode=archive and --cache.noprefetch=true by default (#482 )
* feat: use --gcmode=archive and --cache.noprefetch=true by default
* refuse to start with invalid config
* lint
* lint
* feat(sdk): support compressed response (#469 )
* enable use compression algorithm
* fix ci
* Just enable decode compressed content at ethclient
* fix comments
---------
Co-authored-by: Haichen Shen <shenhaichen@gmail.com>
* fix: disable pruning and prefetch if not flags are provided (#483 )
Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
* fix: update libzkp to use scroll-prover `v0.7.5` (#484 )
* Update libzkp to use scroll-prover `v0.7.5`.
* Update version.
* address comments
* bump version
* nit
---------
Co-authored-by: maskpp <maskpp266@gmail.com>
Co-authored-by: Steven <asongala@163.com>
Co-authored-by: HAOYUatHZ <haoyu@protonmail.com>
Co-authored-by: iczc <iczcalan@gmail.com>
Co-authored-by: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com>
Co-authored-by: Haichen Shen <shenhaichen@gmail.com>
Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
2023-08-25 15:41:05 +02:00
iczc
d02a410b36
refactor: simplify ccc revert to snapshot ( #480 )
...
* simplify ccc revert to snapshot
* Update version.go
---------
Co-authored-by: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com>
2023-08-24 10:30:00 +08:00
Steven
6992cfe8c5
fix: update row estimation with scroll-prover v0.7.2 ( #475 )
...
* Fix row estimation.
* Update libzkp.
* more
* prepare
* finish
* upgrade
* bump version
* fix tests
* Update to scroll-prover `v0.7.2`.
* fix tests
* Update miner/worker.go
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* Update miner/worker.go
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* Reset ccc when skips first tx.
* do not unnecessarily skip L1 message
* fix ccc reset and improve code readability
* seal block on circuitcapacitychecker.ErrUnknown
---------
Co-authored-by: HAOYUatHZ <haoyu@protonmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
2023-08-23 14:27:00 +02:00
Péter Garamvölgyi
727f88bc5f
fix: exclude L1 message from block payload size validation ( #476 )
...
* fix: exclude L1 message from block payload size validation
* fix the bug when calculating l2TxCount. (#479 )
* fix bug when calculate l2 tx count
* Update version
* bump version
---------
Co-authored-by: maskpp <maskpp266@gmail.com>
2023-08-23 14:06:06 +02:00
maskpp
b65f42b41a
fix the bug when calculating l2TxCount. ( #479 )
...
* fix bug when calculate l2 tx count
* Update version
2023-08-23 13:46:28 +02:00
Péter Garamvölgyi
d4597e369e
fix: enable worker but skip CCC on follower nodes ( #474 )
...
* fix: enable worker but skip CCC on follower nodes
* fix worker snapshot
* fix worker snapshot
2023-08-19 15:51:49 +02:00
Péter Garamvölgyi
ad4ddbf60f
fix: disable commitNewWork on follower nodes ( #472 )
...
fix: disable mining on follower nodes
2023-08-18 16:06:15 +02:00
Péter Garamvölgyi
81dc3649a8
fix: seal block if single tx overflows ( #468 )
2023-08-18 07:09:53 +02:00
Péter Garamvölgyi
626ae08ebf
fix: update worker nextL1MsgIndex for unknown errors ( #464 )
...
* fix: update worker nextL1MsgIndex for strange errors
* more tests
* bump version
* refactor: add more context to tracing failure (#466 )
* bump version
* bump version
2023-08-17 19:55:56 +02:00
Péter Garamvölgyi
25fe3ba69a
feat: add startL1QueueIndex field to traces ( #463 )
...
* feat: include startL1QueueIndex in traces
* fix
* update example
2023-08-12 11:07:36 +08:00
Péter Garamvölgyi
4175f65734
fix: skip payload size check for L1 messages ( #457 )
2023-08-08 05:50:45 +02:00
Péter Garamvölgyi
eda99eec35
fix: skip L1 message that leads to gas limit exceeded ( #455 )
...
* skip L1 message that leads to gas limit exceeded
* add test
* do not skip l1 messages from the same account
2023-08-08 01:59:11 +02:00
HAOYUatHZ
2a1788f7f3
doc: add more doc to commitStateAfterApply for tracing in miner ( #452 )
...
* WIP
* add more
* improve
* fix typos
2023-08-07 20:50:32 +08:00
HAOYUatHZ
b428fa1339
fix(trace): fix commit state when tracing ( #451 )
...
* fix(trace): fix commit state when tracing
* bump version
2023-08-07 14:15:21 +08:00
Péter Garamvölgyi
e70a07cc98
fix: Initialize nextL1MsgIndex before commit ( #444 )
...
* initialize nextL1MsgIndex before commit
* bump version
---------
Co-authored-by: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com>
2023-08-06 21:48:03 +08:00
Péter Garamvölgyi
69dd39afba
fix: do not overwrite correct L1 index on signer startup ( #443 )
...
* fix signer worker
* add logs
* bump version
* Fix
2023-08-06 14:22:02 +02:00
Péter Garamvölgyi
cf42026e58
fix: do not skip QueueIndex 0 in worker ( #439 )
...
fix: do not skip QueueIndex 0
2023-08-04 06:07:34 +02:00
Péter Garamvölgyi
26eeb40ea3
fix: use correct hash for ccc write in worker ( #438 )
2023-08-04 04:22:47 +02:00
Péter Garamvölgyi
5611b8296a
refactor: add more ccc logs ( #436 )
...
* refactor: add more ccc logs
* format hashes
* more logs
* more logs
2023-08-03 18:16:32 +02:00
Péter Garamvölgyi
f87eb3127a
fix: do not reuse same snapshot twice ( #435 )
...
fix: create new snapshot
2023-08-03 16:45:45 +02:00
HAOYUatHZ
5b0b08b104
fix(miner): fix trace for empty block ( #434 )
...
* fix(miner): fix trace for empty block
* update version
* try fix
* improve docs
2023-08-03 16:19:52 +02:00
HAOYUatHZ
ef67ff8bbb
fix(miner): fix acc_rows for empty block ( #431 )
...
* Revert "fix(worker): set row consumption for genesis and empty blocks (#428 )"
This reverts commit b51736fd3c .
* fix: fix accRows for empty block
* bump version
* remove log
* fix
* set default accRows as nil explicitly
* fix genesis block
* fix
2023-08-03 13:09:59 +02:00
Péter Garamvölgyi
b51736fd3c
fix(worker): set row consumption for genesis and empty blocks ( #428 )
...
* fix: initialize row consumption for genesis and empty blocks
* bump version
2023-08-03 09:48:03 +02:00
HAOYUatHZ
2f9edf73ca
feat(rollup): add circuits capacity checker ( #321 )
...
* add proof for predeployed storages
* reverse inneeded code
* update for mainbranch merging
* add pertx storage trace
* dummy tx proof
* add txstorage trace
* add coinbase storage as trace
* enable (sync) tracing by default
* basic
* init cgo framework
* fix break loop
* integrate the right zkevm version (#323 )
* finish rust codes
* use dylib (#325 )
* flip
* ?
* use cdylib
* revert
* fix
* apply_tx
* rename
* fixing types
fixing types
fixing types
* clean up
* ExecutionResults (#328 )
* filling
* filling
* more
* clean up
* filling
* coinbase
* add
* MPTWitness
* ExecutionResults WIP
* L1fee
L1fee
* sender
* to
* Failed & ReturnValue
* createdAcc & after
* remove MPTWitness
* txStorageTrace
* add FeeRecipient
* add StorageTrace
* fix FFI types
* better logger
* cargo fmt
* fix
* add build tags
* update Makefile
* fix library
* improve ld path
* correctly deal with circuit_capacity_checker returned result
* fix return value
* update cargo (#333 )
* update cargo
* update
* update go
* refactor
* raname `circuits capacity checker` to `circuit capacity checker`
* some refactorings
* [Fix] storage proof generation in capacity checker (#348 )
* make per-tx storage and deletion proof work
* format
* fix misplaced markdeletion
---------
Co-authored-by: HAOYUatHZ <haoyu@protonmail.com>
* docker (#363 )
* update Dockerfile
* build: update go version to 1.19
* update
* fix
* fix
* try
* simplify
* revert go version
update l2geth Dockerfiles
* fix
* fix coinbase
* fix (#369 )
* format
* Update version.go
* address comments
* Capacity refactor (#374 )
* init
* id
* support multiple instances
* fix id
* fix conflicts
* refactor to use same codes (#379 )
* re-init
* WIP
* WIP
* refactor
* go
* minor
* fix storage proof of l1gas price oracle
* move 1
* move 2
* move 3
* move 4
* move 5
move 5
* move 6
move 6
* move 7
* move 8
* move 9
* move 10
* clean up
clean up
---------
Co-authored-by: Ho Vei <noelwei@gmail.com>
* finish basic
* minor
* config capacity check in block_validator (#380 )
* init
* done
ref
* fix tests
fix tests
fix tests
fix tests
* add more comments
* apply_block
* improve logs
* cargo fmt
* Capacity big refactor (#383 )
* CreateTraceEnv
* WIP
* draft
more
fix
* for test
* fortet
* clean up
* add more comments
* goimports -local github.com/scroll-tech/go-ethereum -w .
* fix typos
* attempt 1
* attempt 2
* attempt 3
* gogogo
* clean up
* fix
* fix
* rename
* minor
* fix
* minor
* minor
* improve doc
* use dedicated `checkCircuitCapacity` flag (#394 )
* refactor
* fix
* add lock
* [feat] capacity checking: upgrade libzkp (#395 )
* upgrade
* upgrade libzkp
* write RowConsumption (#396 )
* write RowConsumption
* name alignments
* revert some formatting
* add lock to CircuitCapacityChecker in BlockValidator
* remove mutex pointer
* improve github workflow
* improve
* store row consumption in mining (#397 )
* prepare
* finish
* add more logs
* mark `ApplyBlock` as ready
* update libzkp (#401 )
* fix
* Capacity detail (#402 )
* fix(block-validation): consider skipping in ValidateL1Messages (#405 )
* fix(block-validation): consider skipping in ValidateL1Messages
* fix(block): consider skipping in L1MessageCount
* fix l1 validation tests
* fix NumL1Messages
* fix impl.go return types
fix
* better error handling (#407 )
* add
add
* add
* add
* add
* add
* cargo fmt
* add
* update
* add
* WIP
* minor
* gogogo
* gogogo
* fix
* fix
* fix
* cargo clippy
* improve
* improve
* creation lock (#408 )
* creation lock
* update
* Debug log (#409 )
* add more logs
* more
* more
* fix
* improve
* Update cmd/utils/flags.go
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* refactor worker.commit()
* avoid re-calculate
* txpool ccc err handling (#411 )
* more explicit error comments
* add more logs
* fix unnecessary commit
* add more logs
* fix `ineffassign`
* add more comments
* log id for `NewCircuitCapacityChecker` (#414 )
add log to `NewCircuitCapacityChecker`
* Persist skip info for block where all L1 msgs are skipped (#415 )
persist skip info for block where all L1 msgs are skipped
* Update version.go
---------
Co-authored-by: Ho Vei <noelwei@gmail.com>
Co-authored-by: Zhang Zhuo <mycinbrin@gmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
2023-08-01 13:52:31 +08:00
Péter Garamvölgyi
983d630244
feat: Sync and relay L1 messages ( #350 )
...
* add l1 config in genesis config (#249 )
* add l1 config in genesis config
* fix lint
* Update params/config.go
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
---------
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* extend node configuration (#251 )
* extend node configuration
* use block number instead of hash
* accept safe, finalized and numbers for L1Confirmations
* fix typos
---------
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* Fix/improve node config parsing (#260 )
* raise error on failed parsing
* default value
* add l1-message-type, transaction methods (#252 )
* add l1-message-type, transaction methods
* goimports
* Update core/types/transaction.go
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* txpool l1 check, pointer change, marhsal test
* draft: start implementing l1message gas behavior
* draft: start implementing l1message gas behavior
* change to gas usage
* error comment typo
Co-authored-by: Haichen Shen <shenhaichen@gmail.com>
* goimports
* update nonce, add hash test (fails), marshal test
* goimports
* target addr cant be nil
* change call msg
* comment out test
* lint
---------
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
Co-authored-by: Haichen Shen <shenhaichen@gmail.com>
* Add L1 message database (#255 )
* add l1-message-type, transaction methods
* goimports
* Update core/types/transaction.go
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* add L1 message store to rawdb
* remove comments
* rename to l1_message
* rename variables and add comments
* write l1 msgs in a batch
* add more comments
* update tests
* allow batched and non-batched writes
* rename to accessors_l1_message
* handle error
* add range check
* fix tests
* update comments
* nit
* support blocks with 0 l1 messages
---------
Co-authored-by: Max Wolff <maxcwolff@gmail.com>
Co-authored-by: Max Wolff <max@scroll.io>
* Fix L1Message Deep Copy, Complete Bridge Tx Hash test (#269 )
* deep copy value field, add tx hash test
comment
* typo
* Rename nonce to queueindex, increment sender nonce on L1 message execution (#271 )
* change nonce to queueindex, increment nonce on L1 message
* fix db acccessors
* Update core/types/transaction_marshalling.go
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
---------
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* Fix db inspect command (#276 )
fix db inspect command
* Add l1 sync service (#256 )
* extend node configuration
* add l1-message-type, transaction methods
* goimports
* Update core/types/transaction.go
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* use block number instead of hash
* accept safe, finalized and numbers for L1Confirmations
* add L1 message store to rawdb
* remove comments
* fix typos
* add L1 message sync service
* use l1 contract address and chain ID
* use L1DeploymentBlock
* add confirmation config
* move bridge client to separate file
* use uint64 block number
* fix bigint comparison
* rename constants
* add more logs
* rename to l1_message
* rename variables and add comments
* write l1 msgs in a batch
* add more comments
* update tests
* allow batched and non-batched writes
* rename to accessors_l1_message
* handle error
* check if config is provided
* improve sync service DB batched writes
* add range check
* fix tests
* update comments
* nit
* fix flush range and improve comments
* solve circular dependency
* update stress tests
* initialize l1 client for geth
* start sync service
* add more comments
* check nil correctly
* address comments
* fix merge
* fix genesis l1config deserialization
* add sync progress logs
* initial sync
* handle leveldb not found error
* use errors.Is
* address comments
* update DefaultPollInterval
---------
Co-authored-by: Nazarii Denha <dengaaa2002@gmail.com>
Co-authored-by: Max Wolff <maxcwolff@gmail.com>
Co-authored-by: Max Wolff <max@scroll.io>
* Add L1 message validation (#272 )
* add L1 message validation
* add comments and better error handling
* handle leveldb not found error
* update incorrect condition for genesis block
* typo
* change inclusion index logic
* disable L1 message check for legacy tests
* set NumL1MessagesPerBlock to 0 in tests
* update default genesis config
* Add L1 msg validation tests (#303 )
add L1 msg validation tests
* Update miner include l1 messages (#265 )
* add l1-message-type, transaction methods
* goimports
* Update core/types/transaction.go
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* add L1 message store to rawdb
* add L1 message sync service
* remove comments
* use l1 contract address and chain ID
* extend node configuration
* use block number instead of hash
* accept safe, finalized and numbers for L1Confirmations
* fix typos
* use L1DeploymentBlock
* add confirmation config
* move bridge client to separate file
* use uint64 block number
* fix bigint comparison
* rename constants
* add more logs
* Fix/improve node config parsing (#260 )
* raise error on failed parsing
* default value
* rename to l1_message
* rename variables and add comments
* write l1 msgs in a batch
* add more comments
* update tests
* allow batched and non-batched writes
* rename to accessors_l1_message
* handle error
* check if config is provided
* improve sync service DB batched writes
* include l1 messages in blocks: part 1
* add l1-message-type, transaction methods (#252 )
* add l1-message-type, transaction methods
* goimports
* Update core/types/transaction.go
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* txpool l1 check, pointer change, marhsal test
* draft: start implementing l1message gas behavior
* draft: start implementing l1message gas behavior
* change to gas usage
* error comment typo
Co-authored-by: Haichen Shen <shenhaichen@gmail.com>
* goimports
* update nonce, add hash test (fails), marshal test
* goimports
* target addr cant be nil
* change call msg
* comment out test
* lint
---------
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
Co-authored-by: Haichen Shen <shenhaichen@gmail.com>
* Add L1 message database (#255 )
* add l1-message-type, transaction methods
* goimports
* Update core/types/transaction.go
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* add L1 message store to rawdb
* remove comments
* rename to l1_message
* rename variables and add comments
* write l1 msgs in a batch
* add more comments
* update tests
* allow batched and non-batched writes
* rename to accessors_l1_message
* handle error
* add range check
* fix tests
* update comments
* nit
* support blocks with 0 l1 messages
---------
Co-authored-by: Max Wolff <maxcwolff@gmail.com>
Co-authored-by: Max Wolff <max@scroll.io>
* build(docker): auto docker push when pushing git tags (#258 )
* build(docker): update docker trigger tag prefix (#259 )
* Fix L1Message Deep Copy, Complete Bridge Tx Hash test (#269 )
* deep copy value field, add tx hash test
comment
* typo
* commitl1messages
* lint
* Revert "add L1 message sync service"
This reverts commit 5305e8a5de14766ed249e1a7d64042c7a72cf5c2.
* Revert "move bridge client to separate file"
This reverts commit 0b220bee37de93c3250545e23430db2c401a2f90.
* update branch
* use commitMessages for l1Txs
* little fix
* fix config
* fix test
* comment fixes
* fix
* fix config check
---------
Co-authored-by: Max Wolff <maxcwolff@gmail.com>
Co-authored-by: Max Wolff <max@scroll.io>
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
Co-authored-by: Haichen Shen <shenhaichen@gmail.com>
Co-authored-by: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com>
* Add ErrUnknownAncestor tests (#305 )
add ErrUnknownAncestor tests
* worker test include l1 msgs (#306 )
* worker test include l1 msgs
* move L1 message index update next to block insertion
---------
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* exclude l1 messages from transaction count limit in block (#307 )
* exclude l1 messages from transaction count limit in block
* fix comments
* trigger ci
* nit
---------
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
Co-authored-by: Péter Garamvölgyi <peter@scroll.io>
* Expose queueIndex on Transaction (#316 )
expose queueIndex on Transaction
* test that l1msg doesn't count in maxTxPerBlock limit (#312 )
* test that l1msg doesn't count in maxTxPerBlock limit
* fix, comment
* retrigger ci
* change order inside test
---------
Co-authored-by: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com>
Co-authored-by: Péter Garamvölgyi <th307q@gmail.com>
* reuse trace nonce field for queueIndex
* expose scroll APIs on the geth console
* add L1 message query APIs
* Trigger new block on new l1 messages (#343 )
* trigger new block on new l1 messages
* typo
* initialize l1MsgCh
* fix worker l1msg tests (#345 )
---------
Co-authored-by: Nazarii Denha <dengaaa2002@gmail.com>
* test(worker): ensure that l1 messages are included in the correct order (#346 )
test that l1msgs added in correct order
* rename enqueueIndex --> queueIndex
* move QueueIndex into transaction
* improve l1 db interface
* formatting
* bump version
* print l1config
* add API to query latest included message queue index
* clean up tx limit logic
* add clarifying comments and todos to ValidateL1Messages
* improve db comments and logs
* clean up L1MessageTx type handling
* format
* format
* improve L1 message block check
* fix missing L1 event handling
* fix TestL1MessageValidationFailure
* simplify sync height resume logic
* make l1Config.l1MessageQueueAddress non-pointer
* improve command line flags
* remove todo
* use abigen tools for log filtering
* cache block L1 message count
* nit: fix variable name case
* improve logs
* flush pending writes to DB before shutdown
---------
Co-authored-by: Nazarii Denha <dengaaa2002@gmail.com>
Co-authored-by: Max Wolff <max@scroll.io>
Co-authored-by: Haichen Shen <shenhaichen@gmail.com>
Co-authored-by: Max Wolff <maxcwolff@gmail.com>
Co-authored-by: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com>
Co-authored-by: HAOYUatHZ <haoyu@protonmail.com>
2023-06-07 07:24:19 -07:00