ethereum / ethereum/execution-specs

legacytests contain invalid pre Spurious Dragon state tests

Open
#1,967 3 comments 0 reactions 0 assignees View on GitHub
stale
Dominant language
Python
Stars
1.2k
Forks
505
Avg merge
2d 14h
Merged PRs (30d)
116

Description

The repo with legacy tests (https://github.com/ethereum/legacytests) contain some invalid state tests with invalid transactions in pre-Byzantium forks.

If a state test contains an invalid transaction and expects the EVM to report transaction validation exception the state should remain unchanged. However, legacytests contains some tests where this invariant is broken.
This happens because the EVM which is used to fill test tests incorrectly creates an empty COINBASE account in the state. Before Spurious Dragon such empty accounts are not automatically deleted after the transaction processing.

Example of such test: https://github.com/ethereum/legacytests/blob/master/Cancun/GeneralStateTests/stTransactionTest/HighGasPrice.json
The pre-state hash is `0x1751725d1aad5298768fbcf64069b2c1b85aeaffcc561146067d6beedd08052a`. It should be also the post-state hash for or forks, but pre Spurious Dragon forks report `0x7e18cda82e88b51f339192016b7f3e803051e1e115260efb25f8602b894226ec`.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.