From f09b7e08c04be624fdea4905154c17af510436a2 Mon Sep 17 00:00:00 2001 From: rain-zxn <206131521@qq.com> Date: Fri, 11 Nov 2022 11:13:17 +0800 Subject: [PATCH] add log with Compose dst chain tx --- wallet/eth.go | 2 +- wallet/wallet.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/wallet/eth.go b/wallet/eth.go index 0648eb8..96c0a49 100644 --- a/wallet/eth.go +++ b/wallet/eth.go @@ -98,7 +98,7 @@ func (w *EthWallet) SendWithAccount(account accounts.Account, addr common.Addres nonces.Update(false) return "", fmt.Errorf("Sign tx error %v", err) } - log.Info("Compose dst chain tx", "hash", tx.Hash(), "account", account.Address) + log.Info("Compose dst chain tx", "hash", tx.Hash(), "account", account.Address, "nonce", tx.Nonce(), "limit", tx.Gas(), "gasPrice", tx.GasPrice()) err = w.sdk.Node().SendTransaction(context.Background(), tx) //TODO: Check err here before update nonces nonces.Update(true) diff --git a/wallet/wallet.go b/wallet/wallet.go index 13d3b21..4adf302 100644 --- a/wallet/wallet.go +++ b/wallet/wallet.go @@ -233,7 +233,7 @@ func (w *Wallet) sendWithAccount(dry bool, account accounts.Account, addr common err = fmt.Errorf("Sign tx error %v", err) return } - log.Info("Compose dst chain tx", "hash", tx.Hash(), "account", account.Address) + log.Info("Compose dst chain tx", "hash", tx.Hash(), "account", account.Address, "nonce", tx.Nonce(), "limit", tx.Gas(), "gasPrice", tx.GasPrice()) err = w.sdk.Node().SendTransaction(context.Background(), tx) //TODO: Check err here before update nonces nonces.Update(true) @@ -363,7 +363,7 @@ func (w *Wallet) SendWithMaxLimit(chainId uint64, account accounts.Account, addr err = fmt.Errorf("Sign tx error %v", err) return } - log.Info("Compose dst chain tx", "hash", tx.Hash(), "account", account.Address) + log.Info("Compose dst chain tx", "hash", tx.Hash(), "account", account.Address, "nonce", tx.Nonce(), "limit", tx.Gas(), "gasPrice", tx.GasPrice()) err = w.sdk.Node().SendTransaction(context.Background(), tx) //TODO: Check err here before update nonces nonces.Update(true)