Optimism plugin#6146
Conversation
# Conflicts: # src/Nethermind/Nethermind.Merge.Plugin/EngineRpcModule.Paris.cs
This reverts commit 0c8c091.
LukaszRozmej
left a comment
There was a problem hiding this comment.
Further TODO things - I would like them to be captured to issues and linked with this PR:
- Refactoring of Transactions (and TxDecoder and TransactionsForRpc) to be infectible by plugins
- Refactoring of chain spec specific parts to be injectable by plugins
|
|
||
| IEnumerable<Transaction> txs = _payloadAttrsTxSource.GetTransactions(parent, attrs.GasLimit, attrs); | ||
|
|
||
| Block block = new(blockHeader, txs, Array.Empty<BlockHeader>(), payloadAttributes?.Withdrawals); |
There was a problem hiding this comment.
Compiler can't understand that and fails with warning as error
|
|
||
| public Task InitNetworkProtocol() => Task.CompletedTask; | ||
|
|
||
| public Task InitSynchronization() |
There was a problem hiding this comment.
WHy do we have to init synchronization?
There was a problem hiding this comment.
we would initialize syncronization anyways in the default InitializeNetwork, at least this one would work if p2p was enabled in Optimism.
| if (!WorldState.AccountExists(tx.SenderAddress!)) | ||
| { | ||
| WorldState.CreateAccount(tx.SenderAddress!, 0, 1); | ||
| } | ||
| else | ||
| { | ||
| WorldState.IncrementNonce(tx.SenderAddress!); | ||
| } |
There was a problem hiding this comment.
A bit of hack that Validate mutates the state
There was a problem hiding this comment.
I would love to push it to the next pr. Will require refactoring
There was a problem hiding this comment.
let's also capture this in an issue
|
I created three issues. |
Fixes Closes Resolves #
Nethermind optimism plugin
Changes
DisableGcOnNewPayload. During sync disabling gc causes memory leakstateUnavailable. Op-mainnet and op-goerli don't have state for block number zero.Types of changes
What types of changes does your code introduce?
Testing
Requires testing
If yes, did you write tests?
Documentation
Requires documentation update
Requires explanation in Release Notes