Closed IvantheTricourne closed 4 years ago
Both Ethereum and Cosmos increment nonces by 1 for each transaction performed by a given account. Ethereum specifies that transaction nonces should be kept in order (i.e., 1 should always happen before 2, and 2 cannot exist without 1).
We want to be able to commit multiple semantically equivalent transactions (e.g. a transfer between the same 2 accounts for the same value). Currently, this fails during the
checkTx
phase with the error:To address this, we should propagate the nonce from the Auth module to transactions performed by respective account. This will probably take the shape of an AnteHandler check which happens before message routing and validation. This AnteHandler is responsible for validating that the appropriate nonce is updated for a given transaction.