@@ -2,6 +2,7 @@ package sweepbatcher
22
33import (
44 "context"
5+ "encoding/hex"
56 "errors"
67 "fmt"
78 "strings"
@@ -12,6 +13,7 @@ import (
1213 "github.com/btcsuite/btcd/btcutil"
1314 "github.com/btcsuite/btcd/chaincfg"
1415 "github.com/btcsuite/btcd/chaincfg/chainhash"
16+ "github.com/btcsuite/btcd/txscript"
1517 "github.com/btcsuite/btcd/wire"
1618 "github.com/btcsuite/btclog/v2"
1719 "github.com/btcsuite/btcwallet/chain"
@@ -698,7 +700,14 @@ func (b *Batcher) PresignSweepsGroup(ctx context.Context, inputs []Input,
698700 if err != nil {
699701 return fmt .Errorf ("failed to get nextBlockFeeRate: %w" , err )
700702 }
701- infof ("PresignSweepsGroup: nextBlockFeeRate is %v" , nextBlockFeeRate )
703+ destPkscript , err := txscript .PayToAddrScript (destAddress )
704+ if err != nil {
705+ return fmt .Errorf ("txscript.PayToAddrScript failed: %w" , err )
706+ }
707+ infof ("PresignSweepsGroup: nextBlockFeeRate is %v, inputs: %v, " +
708+ "destAddress: %v, destPkscript: %v sweepTimeout: %d" ,
709+ nextBlockFeeRate , inputs , destAddress ,
710+ hex .EncodeToString (destPkscript ), sweepTimeout )
702711
703712 sweeps := make ([]sweep , len (inputs ))
704713 for i , input := range inputs {
0 commit comments