diff --git a/core/txpool/legacypool/legacypool.go b/core/txpool/legacypool/legacypool.go index 936124d7d0..dc4e223d50 100644 --- a/core/txpool/legacypool/legacypool.go +++ b/core/txpool/legacypool/legacypool.go @@ -19,7 +19,6 @@ package legacypool import ( "errors" - "fmt" "maps" "math" "math/big" @@ -978,7 +977,6 @@ func (pool *LegacyPool) Add(txs []*types.Transaction, sync bool) []error { pool.requestPromoteExecutables(req) if sync { <-req.done - fmt.Printf("added %x\n", txs[0].Hash()) } return errs } @@ -1205,7 +1203,6 @@ func (pool *LegacyPool) scheduleReorgLoop() { select { case req := <-pool.reqResetCh: - fmt.Printf("request reset to %d\n", req.newHead.Number) // Reset request: update head if request is already pending. if reset == nil { reset = req @@ -1214,10 +1211,8 @@ func (pool *LegacyPool) scheduleReorgLoop() { } nextDones = append(nextDones, req.done) launchNextRun = true - //pool.reorgDoneCh <- nextDone case req := <-pool.reqPromoteCh: - fmt.Println("request promote") // Promote request: update address set if request is already pending. if dirtyAccounts == nil { dirtyAccounts = req.set @@ -1226,7 +1221,6 @@ func (pool *LegacyPool) scheduleReorgLoop() { } nextDones = append(nextDones, req.done) launchNextRun = true - //pool.reorgDoneCh <- nextDone case tx := <-pool.queueTxEventCh: // Queue up the event, but don't schedule a reorg. It's up to the caller to @@ -1310,7 +1304,6 @@ func (pool *LegacyPool) runReorg(done chan struct{}, reset *txpoolResetRequest, for addr, list := range pool.pending { highestPending := list.LastElement() nonces[addr] = highestPending.Nonce() + 1 - fmt.Printf("set pending nonce %x <- %d\n", addr, highestPending.Nonce()+1) } pool.pendingNonces.setAll(nonces) } @@ -1467,11 +1460,8 @@ func (pool *LegacyPool) promoteExecutables(accounts []common.Address) []*types.T log.Trace("Removed unpayable queued transactions", "count", len(drops)) queuedNofundsMeter.Mark(int64(len(drops))) - fmt.Printf("pending nonce of %x is %d\n", addr, pool.pendingNonces.get(addr)) - fmt.Printf("in-state nonce of %x is %d\n", addr, pool.currentState.GetNonce(addr)) // Gather all executable transactions and promote them readies := list.Ready(pool.pendingNonces.get(addr)) - fmt.Println(len(readies)) for _, tx := range readies { hash := tx.Hash() @@ -1479,11 +1469,6 @@ func (pool *LegacyPool) promoteExecutables(accounts []common.Address) []*types.T promoted = append(promoted, tx) } } - fmt.Println(len(promoted)) - if len(promoted) > 0 { - fmt.Println(promoted[0].Hash()) - fmt.Println(promoted[0].Nonce()) - } log.Trace("Promoted queued transactions", "count", len(promoted)) queuedGauge.Dec(int64(len(readies))) diff --git a/core/txpool/txpool.go b/core/txpool/txpool.go index c1c8078094..47d83e03d4 100644 --- a/core/txpool/txpool.go +++ b/core/txpool/txpool.go @@ -361,7 +361,6 @@ func (p *TxPool) Add(txs []*types.Transaction, sync bool) []error { splits := make([]int, len(txs)) for i, tx := range txs { - fmt.Printf("txpool attempting to add %v\n", tx.Hash()) // Mark this transaction belonging to no-subpool splits[i] = -1 diff --git a/eth/catalyst/api_test.go b/eth/catalyst/api_test.go index 14474fae2e..e91e07d05d 100644 --- a/eth/catalyst/api_test.go +++ b/eth/catalyst/api_test.go @@ -119,7 +119,6 @@ func TestEth2AssembleBlock(t *testing.T) { t.Fatalf("error signing transaction, err=%v", err) } ethservice.TxPool().Add([]*types.Transaction{tx}, true) - fmt.Println("in test: added txs") blockParams := engine.PayloadAttributes{ Timestamp: blocks[9].Time() + 5, } @@ -139,7 +138,7 @@ func assembleWithTransactions(api *ConsensusAPI, parentHash common.Hash, params return nil, err } if have, want := len(execData.Transactions), want; have != want { - err = fmt.Errorf("block %d: invalid number of transactions, have %d want %d", execData.Number, have, want) + err = fmt.Errorf("invalid number of transactions, have %d want %d", have, want) continue } return execData, nil @@ -448,7 +447,6 @@ func startEthService(t *testing.T, genesis *core.Genesis, blocks []*types.Block) n.Close() t.Fatal("can't import test blocks:", err) } - time.Sleep(100 * time.Millisecond) ethservice.SetSynced() return n, ethservice