From 494cde2f23f93b64e310090de6fbd9c8c6fc1d02 Mon Sep 17 00:00:00 2001 From: Nikolay Nedkov Date: Thu, 3 Aug 2023 14:23:27 +0300 Subject: [PATCH] bugfix: attaching missing TxTracker.From to pending txs to store for forced batches. Signed-off-by: Nikolay Nedkov --- sequencer/finalizer.go | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/sequencer/finalizer.go b/sequencer/finalizer.go index 707fa2a4ec..d5a50b13d6 100644 --- a/sequencer/finalizer.go +++ b/sequencer/finalizer.go @@ -731,8 +731,16 @@ func (f *finalizer) handleForcedTxsProcessResp(ctx context.Context, request stat } } + from, err := state.GetSender(txResp.Tx) + if err != nil { + log.Errorf("handleForcedTxsProcessResp: failed to get sender: %s", err) + continue + } + processedTransaction := transactionToStore{ - txTracker: nil, + txTracker: &TxTracker{ + From: from, + }, response: txResp, batchResponse: result, batchNumber: request.BatchNumber, @@ -743,12 +751,6 @@ func (f *finalizer) handleForcedTxsProcessResp(ctx context.Context, request stat flushId: result.FlushID, } - from, err := state.GetSender(txResp.Tx) - if err != nil { - log.Errorf("handleForcedTxsProcessResp: failed to get sender: %s", err) - continue - } - f.pendingTxsToStoreMux.Lock() // global tracker f.pendingTxsToStoreWG.Add(1)