From 690379ff71f8e3c8f49b7ee6e1f504bc2be0a039 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 8eeac59..f825f33 100644 --- a/wallet/wallet.go +++ b/wallet/wallet.go @@ -223,7 +223,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) @@ -344,7 +344,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)