Hardhat Network automining and state transition timing
0 reputation · 18 Mar 2021, 09:07 UTC
The Hardhat Network includes an automining feature that triggers the creation of a new block immediately upon the receipt of a transaction. This behavior is intended to accelerate development by ensuring instant confirmation of state changes.
When transitioning from automining to manual mining via the evm_mine RPC method within a single session, the timing of state updates and transaction sequencing requires further clarification. Specifically, it is unclear how the network handles transactions that were received just as automining was disabled but before the first manual mine command was issued.
Does the network maintain a strict FIFO queue for these pending transactions regardless of the mining mode switch? How is the block height incremented when moving from an automated to a manual mining state?