Skip to content

Commit 3f1e943

Browse files
authored
fix(cast): include zero address as known system sender in cast run (#10608)
* fix(`cast`): include zero address as known system sender in cast run * docs
1 parent 12c1178 commit 3f1e943

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

crates/common/src/constants.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,14 +45,14 @@ pub const SYSTEM_TRANSACTION_TYPE: u8 = 126;
4545
/// Default user agent set as the header for requests that don't specify one.
4646
pub const DEFAULT_USER_AGENT: &str = concat!("foundry/", env!("CARGO_PKG_VERSION"));
4747

48-
/// Returns whether the sender is a known L2 system sender that is the first tx in every block.
48+
/// Returns whether the sender is a known system sender that is the first tx in every block.
4949
///
50-
/// Transactions from these senders usually don't have a any fee information.
50+
/// Transactions from these senders usually don't have a any fee information OR set absurdly high fees that exceed the gas limit (See: <https://github.com/foundry-rs/foundry/pull/10608>)
5151
///
52-
/// See: [ARBITRUM_SENDER], [OPTIMISM_SYSTEM_ADDRESS]
52+
/// See: [ARBITRUM_SENDER], [OPTIMISM_SYSTEM_ADDRESS] and [Address::ZERO]
5353
#[inline]
5454
pub fn is_known_system_sender(sender: Address) -> bool {
55-
[ARBITRUM_SENDER, OPTIMISM_SYSTEM_ADDRESS].contains(&sender)
55+
[ARBITRUM_SENDER, OPTIMISM_SYSTEM_ADDRESS, Address::ZERO].contains(&sender)
5656
}
5757

5858
pub fn is_impersonated_tx(tx: &AnyTxEnvelope) -> bool {

0 commit comments

Comments
 (0)