Skip to content

Commit ba5d7f7

Browse files
authored
feat: add tracing in scroll tx pool (#352)
1 parent 5edac54 commit ba5d7f7

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

Cargo.lock

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/scroll/txpool/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ scroll-alloy-consensus.workspace = true
4040
c-kzg.workspace = true
4141
derive_more.workspace = true
4242
parking_lot.workspace = true
43+
tracing.workspace = true
4344

4445
[dev-dependencies]
4546
reth-scroll-chainspec.workspace = true

crates/scroll/txpool/src/validator.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,9 @@ where
153153
}
154154

155155
let outcome = self.inner.validate_one(origin, transaction);
156+
if outcome.is_invalid() || outcome.is_error() {
157+
tracing::trace!(target: "scroll_txpool", ?outcome, "tx pool validation failed")
158+
}
156159

157160
if !self.requires_l1_data_gas_fee() {
158161
// no need to check L1 gas fee

0 commit comments

Comments
 (0)