@@ -18,22 +18,22 @@ pub enum OpTransactionError {
18
18
/// was deprecated in the Regolith hardfork, and this error is thrown if a `Deposit` transaction
19
19
/// is found with this field set to `true` after the hardfork activation.
20
20
///
21
- /// In addition, this error is internal, and bubbles up into a [OpHaltReason::FailedDeposit][crate::OpHaltReason::FailedDeposit] error
21
+ /// In addition, this error is internal, and bubbles up into an [OpHaltReason::FailedDeposit][crate::OpHaltReason::FailedDeposit] error
22
22
/// in the `revm` handler for the consumer to easily handle. This is due to a state transition
23
23
/// rule on OP Stack chains where, if for any reason a deposit transaction fails, the transaction
24
24
/// must still be included in the block, the sender nonce is bumped, the `mint` value persists, and
25
25
/// special gas accounting rules are applied. Normally on L1, [EVMError::Transaction] errors
26
26
/// are cause for non-inclusion, so a special [OpHaltReason][crate::OpHaltReason] variant was introduced to handle this
27
27
/// case for failed deposit transactions.
28
28
DepositSystemTxPostRegolith ,
29
- /// Deposit transaction haults bubble up to the global main return handler, wiping state and
29
+ /// Deposit transaction halts bubble up to the global main return handler, wiping state and
30
30
/// only increasing the nonce + persisting the mint value.
31
31
///
32
- /// This is a catch-all error for any deposit transaction that is results in a [OpHaltReason][crate::OpHaltReason] error
32
+ /// This is a catch-all error for any deposit transaction that results in an [OpHaltReason][crate::OpHaltReason] error
33
33
/// post-regolith hardfork. This allows for a consumer to easily handle special cases where
34
34
/// a deposit transaction fails during validation, but must still be included in the block.
35
35
///
36
- /// In addition, this error is internal, and bubbles up into a [OpHaltReason::FailedDeposit][crate::OpHaltReason::FailedDeposit] error
36
+ /// In addition, this error is internal, and bubbles up into an [OpHaltReason::FailedDeposit][crate::OpHaltReason::FailedDeposit] error
37
37
/// in the `revm` handler for the consumer to easily handle. This is due to a state transition
38
38
/// rule on OP Stack chains where, if for any reason a deposit transaction fails, the transaction
39
39
/// must still be included in the block, the sender nonce is bumped, the `mint` value persists, and
@@ -86,6 +86,11 @@ mod test {
86
86
87
87
#[ test]
88
88
fn test_display_op_errors ( ) {
89
+ assert_eq ! (
90
+ OpTransactionError :: Base ( InvalidTransaction :: NonceTooHigh { tx: 2 , state: 1 } )
91
+ . to_string( ) ,
92
+ "nonce 2 too high, expected 1"
93
+ ) ;
89
94
assert_eq ! (
90
95
OpTransactionError :: DepositSystemTxPostRegolith . to_string( ) ,
91
96
"deposit system transactions post regolith hardfork are not supported"
0 commit comments