diff --git a/common/txmgr/address_state.go b/common/txmgr/address_state.go index a9e5ebf0aac..d458952c178 100644 --- a/common/txmgr/address_state.go +++ b/common/txmgr/address_state.go @@ -40,6 +40,7 @@ type addressState[ fatalErroredTxs map[int64]*txmgrtypes.Tx[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE] } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // newAddressState returns a new addressState instance with initialized transaction state func newAddressState[ CHAIN_ID types.ID, @@ -127,16 +128,19 @@ func newAddressState[ return &as } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // countTransactionsByState returns the number of transactions that are in the given state func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) countTransactionsByState(txState txmgrtypes.TxState) int { return 0 } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // findTxWithIdempotencyKey returns the transaction with the given idempotency key. If no transaction is found, nil is returned. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) findTxWithIdempotencyKey(key string) *txmgrtypes.Tx[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE] { return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // applyToTxsByState calls the given function for each transaction in the given states. // If txIDs are provided, only the transactions with those IDs are considered. // If no txIDs are provided, all transactions in the given states are considered. @@ -148,6 +152,7 @@ func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) applyT ) { } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // findTxAttempts returns all attempts for the given transactions that match the given filters. // If txIDs are provided, only the transactions with those IDs are considered. // If no txIDs are provided, all transactions are considered. @@ -162,6 +167,7 @@ func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) findTx return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // findTxs returns all transactions that match the given filters. // If txIDs are provided, only the transactions with those IDs are considered. // If no txIDs are provided, all transactions are considered. @@ -174,29 +180,35 @@ func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) findTx return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // pruneUnstartedTxQueue removes the transactions with the given IDs from the unstarted transaction queue. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) pruneUnstartedTxQueue(ids []int64) { } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // deleteTxs removes the transactions with the given IDs from the address state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) deleteTxs(txs ...txmgrtypes.Tx[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE]) { } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // peekNextUnstartedTx returns the next unstarted transaction in the queue without removing it from the unstarted queue. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) peekNextUnstartedTx() (*txmgrtypes.Tx[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE], error) { return nil, nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // peekInProgressTx returns the in-progress transaction without removing it from the in-progress state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) peekInProgressTx() (*txmgrtypes.Tx[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE], error) { return nil, nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // addTxToUnstarted adds the given transaction to the unstarted queue. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) addTxToUnstarted(tx *txmgrtypes.Tx[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE]) error { return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // moveUnstartedToInProgress moves the next unstarted transaction to the in-progress state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveUnstartedToInProgress( etx *txmgrtypes.Tx[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE], @@ -205,6 +217,7 @@ func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveUn return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // moveConfirmedMissingReceiptToUnconfirmed moves the confirmed missing receipt transaction to the unconfirmed state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveConfirmedMissingReceiptToUnconfirmed( txID int64, @@ -212,6 +225,7 @@ func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveCo return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // moveInProgressToUnconfirmed moves the in-progress transaction to the unconfirmed state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveInProgressToUnconfirmed( etx txmgrtypes.Tx[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE], @@ -220,6 +234,7 @@ func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveIn return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // moveUnconfirmedToConfirmed moves the unconfirmed transaction to the confirmed state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveUnconfirmedToConfirmed( receipt txmgrtypes.ChainReceipt[TX_HASH, BLOCK_HASH], @@ -227,6 +242,7 @@ func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveUn return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // moveTxToFatalError moves a transaction to the fatal error state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveTxToFatalError( txID int64, txError null.String, @@ -234,16 +250,19 @@ func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveTx return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // moveUnconfirmedToConfirmedMissingReceipt moves the unconfirmed transaction to the confirmed missing receipt state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveUnconfirmedToConfirmedMissingReceipt(attempt txmgrtypes.TxAttempt[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE], broadcastAt time.Time) error { return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // moveInProgressToConfirmedMissingReceipt moves the in-progress transaction to the confirmed missing receipt state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveInProgressToConfirmedMissingReceipt(attempt txmgrtypes.TxAttempt[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE], broadcastAt time.Time) error { return nil } +//lint:ignore U1000 Ignore unused function temporarily while adding the framework // moveConfirmedToUnconfirmed moves the confirmed transaction to the unconfirmed state. func (as *addressState[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) moveConfirmedToUnconfirmed(attempt txmgrtypes.TxAttempt[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, SEQ, FEE]) error { return nil