From bda20891ae174bfa7553d35ad5360a32b39d2a40 Mon Sep 17 00:00:00 2001 From: colin <102356659+colinlyguo@users.noreply.github.com> Date: Thu, 10 Apr 2025 16:16:03 +0800 Subject: [PATCH] fix(txpool): tracing txn executed status (#1168) * fix(txpool): tx journey executed status tracing * fix * bump version * tweak --- core/tx_pool.go | 12 +++++------- params/version.go | 2 +- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/core/tx_pool.go b/core/tx_pool.go index 0b27de7a08..bf36bf281a 100644 --- a/core/tx_pool.go +++ b/core/tx_pool.go @@ -434,6 +434,9 @@ func (pool *TxPool) loop() { if ev.Block != nil { pool.requestReset(head.Header(), ev.Block.Header()) head = ev.Block + for _, tx := range head.Transactions() { + log.Debug("TX is included in a block", "hash", tx.Hash().Hex()) + } } // System shutdown. @@ -1533,14 +1536,9 @@ func (pool *TxPool) reset(oldHead, newHead *types.Header) { } reinject = types.TxDifference(discarded, included) - for _, tx := range discarded { - log.Debug("TXPOOL_REORG: TX removed from old chain", "hash", tx.Hash().Hex()) + for _, tx := range reinject { + log.Debug("TX is removed from old chain due to reorg", "hash", tx.Hash().Hex()) } - - for _, tx := range included { - log.Debug("TXPOOL_REORG: TX added in the chain", "hash", tx.Hash().Hex()) - } - } } } diff --git a/params/version.go b/params/version.go index 23f6311392..94e8f3fe02 100644 --- a/params/version.go +++ b/params/version.go @@ -24,7 +24,7 @@ import ( const ( VersionMajor = 5 // Major version component of the current release VersionMinor = 8 // Minor version component of the current release - VersionPatch = 37 // Patch version component of the current release + VersionPatch = 38 // Patch version component of the current release VersionMeta = "mainnet" // Version metadata to append to the version string )