Skip to content

Commit bdbda6a

Browse files
LukaszRozmejclaude
andcommitted
fix(stateless): wire chain tx-processor factory into witness BAL
The witness block-processing envs hand-built BlockAccessListManager with a null transactionProcessorFactory, so the block-access list fell back to the plain Ethereum factory. On AuRa the chain overrides ITransactionProcessorFactory, and its contract-based withdrawal system calls touch the system-sender account that the plain factory omits, so the witness-generated BAL diverged from the main pipeline's and newPayloadWithWitness returned INVALID. Pass the container's ITransactionProcessorFactory while deliberately leaving the parallel parent-reader factories out, so the BAL still runs sequentially and every access is recorded into the witness. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 36aca55 commit bdbda6a

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

src/Nethermind/Nethermind.Consensus/Stateless/WitnessCapturingBlockProcessingEnv.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
using Nethermind.Core.Specs;
1414
using Nethermind.Evm;
1515
using Nethermind.Evm.State;
16+
using Nethermind.Evm.TransactionProcessing;
1617
using Nethermind.Logging;
1718
using Nethermind.State;
1819
using Nethermind.Trie.Pruning;
@@ -91,7 +92,8 @@ private static Graph Build(
9192
ctx.Resolve<ILogManager>(),
9293
ctx.Resolve<IBlocksConfig>(),
9394
ctx.Resolve<IWithdrawalProcessorFactory>(),
94-
codeInfoRepositoryFactory: CodeInfoRepositoryFactories.Witness))
95+
codeInfoRepositoryFactory: CodeInfoRepositoryFactories.Witness,
96+
transactionProcessorFactory: ctx.Resolve<ITransactionProcessorFactory>()))
9597
// Validation tx executor; everything else is inherited from root and re-resolved against the overridden world state.
9698
.AddModule(validationModules));
9799

src/Nethermind/Nethermind.Consensus/Stateless/WitnessGeneratingBlockProcessingEnvFactory.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
using Nethermind.Db;
1818
using Nethermind.Evm;
1919
using Nethermind.Evm.State;
20+
using Nethermind.Evm.TransactionProcessing;
2021
using Nethermind.Logging;
2122
using Nethermind.State;
2223
using Nethermind.Trie.Pruning;
@@ -98,7 +99,8 @@ private PooledEntry BuildEntry()
9899
ctx.Resolve<ILogManager>(),
99100
ctx.Resolve<IBlocksConfig>(),
100101
ctx.Resolve<IWithdrawalProcessorFactory>(),
101-
codeInfoRepositoryFactory: CodeInfoRepositoryFactories.Witness))
102+
codeInfoRepositoryFactory: CodeInfoRepositoryFactories.Witness,
103+
transactionProcessorFactory: ctx.Resolve<ITransactionProcessorFactory>()))
102104
.AddModule(validationModules)
103105
.AddScoped<IWitnessGeneratingBlockProcessingEnv, WitnessGeneratingBlockProcessingEnv>());
104106

0 commit comments

Comments
 (0)