copy layered worldstate fix for eth_call (#5179)

* copy layered worldstate fix for eth_call

Signed-off-by: garyschulte <garyschulte@gmail.com>
pull/5185/head
garyschulte 2 years ago committed by GitHub
parent d0de337d4d
commit da477e9ecc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      CHANGELOG.md
  2. 7
      ethereum/core/src/main/java/org/hyperledger/besu/ethereum/transaction/TransactionSimulator.java
  3. 1
      ethereum/core/src/test/java/org/hyperledger/besu/ethereum/transaction/TransactionSimulatorTest.java

@ -16,8 +16,9 @@ This update is required for the Goerli Shanghai/Capella upgrade and recommended
- Goerli configs for shapella [#5151](https://github.com/hyperledger/besu/pull/5151)
### Bug Fixes
- Fix engine_getPayloadV2 block value calculation https://github.com/hyperledger/besu/issues/5040
- Moves check for init code length before balance check https://github.com/hyperledger/besu/pull/5077
- Fix engine_getPayloadV2 block value calculation [#5040](https://github.com/hyperledger/besu/issues/5040)
- Moves check for init code length before balance check [#5077](https://github.com/hyperledger/besu/pull/5077)
- Address concurrency problems with eth_call [#5179](https://github.com/hyperledger/besu/pull/5179)
## 23.1.1-RC1
### Sepolia Shanghai Release aka Sepolia Shapella aka Shapolia

@ -166,6 +166,13 @@ public class TransactionSimulator {
private MutableWorldState getWorldState(final BlockHeader header) {
return worldStateArchive
.getMutable(header.getStateRoot(), header.getHash(), false)
.map(
ws -> {
if (!ws.isPersistable()) {
return ws.copy();
}
return ws;
})
.orElseThrow(
() ->
new IllegalArgumentException(

@ -89,6 +89,7 @@ public class TransactionSimulatorTest {
@Before
public void setUp() {
when(this.worldState.isPersistable()).thenReturn(true);
this.transactionSimulator =
new TransactionSimulator(blockchain, worldStateArchive, protocolSchedule);

Loading…
Cancel
Save