diff --git a/sequencer/sequencer.go b/sequencer/sequencer.go index b6ce44661e..dcabff3aa8 100644 --- a/sequencer/sequencer.go +++ b/sequencer/sequencer.go @@ -231,7 +231,8 @@ func (s *Sequencer) addTxToWorker(ctx context.Context, tx pool.Transaction) erro _, l2gp := s.pool.GetL1AndL2GasPrice() defaultGp := new(big.Int).SetUint64(l2gp) baseGp := s.worker.getBaseClaimGp(defaultGp) - txTracker.GasPrice = baseGp.Mul(baseGp, new(big.Int).SetUint64(uint64(getGasPriceMultiple(s.cfg.GasPriceMultiple)))) + copyBaseGp := new(big.Int).Set(baseGp) + txTracker.GasPrice = copyBaseGp.Mul(copyBaseGp, new(big.Int).SetUint64(uint64(getGasPriceMultiple(s.cfg.GasPriceMultiple)))) } replacedTx, dropReason := s.worker.AddTxTracker(ctx, txTracker) diff --git a/sequencer/txsorted_list.go b/sequencer/txsorted_list.go index c1de2e2147..2ee3e5b3f7 100644 --- a/sequencer/txsorted_list.go +++ b/sequencer/txsorted_list.go @@ -58,7 +58,8 @@ func (e *txSortedList) delete(tx *TxTracker) bool { if (e.sorted[i].GasPrice.Cmp(tx.GasPrice)) != 0 { // we have a tx with different (lower) GasPrice than the tx we are looking for, therefore we haven't found the tx - log.Warnf("error deleting tx %s from txSortedList, not found in the list of txs with same gasPrice: %s", tx.HashStr) + log.Warnf("error deleting tx %s from txSortedList %s, not found in the list of txs with same gasPrice: %s - %s", + tx.HashStr, e.sorted[i].HashStr, tx.GasPrice.String(), e.sorted[i].GasPrice.String()) return false } diff --git a/sequencer/worker.go b/sequencer/worker.go index ad65b25c82..9b502b09fb 100644 --- a/sequencer/worker.go +++ b/sequencer/worker.go @@ -33,6 +33,7 @@ func NewWorker(state stateInterface, constraints state.BatchConstraintsCfg, read state: state, batchConstraints: constraints, readyTxsCond: readyTxsCond, + claimGp: new(big.Int), } return &w