removed unused imports

This commit is contained in:
mfahampshire
2023-07-05 18:34:01 +02:00
parent 18de02a229
commit fbc106f8a5
2 changed files with 7 additions and 13 deletions
@@ -1,17 +1,15 @@
use cosmrs::bip32::secp256k1::elliptic_curve::generic_array::sequence;
use nym_sphinx_addressing::clients::Recipient;
use nym_validator_client::nyxd::CosmWasmClient;
use nym_validator_client::signing::direct_wallet::DirectSecp256k1HdWallet;
use nym_validator_client::signing::tx_signer::TxSigner;
use nym_validator_client::signing::SignerData;
use cosmrs::bank::MsgSend;
use cosmrs::rpc::{self, HttpClient};
use cosmrs::rpc::{HttpClient};
use cosmrs::tx::Msg;
use cosmrs::{tx, AccountId, Coin, Denom};
use bip39;
use bs58;
use nym_sdk::mixnet;
// use nymsphinx::addressing::Recipient;
pub async fn offline_sign(mnemonic: bip39::Mnemonic, to: AccountId) -> String {
@@ -84,10 +82,14 @@ pub async fn send_tx(base58_tx: String, sp_address: Recipient) -> Option<Vec<mix
// send message w sdk to broadcaster who will do:
/*
// decode the base58 tx to vec<u8>
// broadcast the tx
let res = rpc::Client::broadcast_tx_commit(&broadcaster, tx_bytes.into())
.await
.unwrap();
// send res back via SURBs
*/
client.send_str(sp_address, &base58_tx).await; // send as base58 encoded and it can be decoded by the SP
println!("\nWaiting for reply\n");
@@ -1,16 +1,8 @@
use std::str::FromStr;
use clap::{CommandFactory, Parser, Subcommand, Args};
use cosmrs::bip32::PublicKey;
use clap::{ Parser, Subcommand, Args};
use nym_sdk::mixnet::Recipient;
use nym_validator_client::nyxd::AccountId;
// use nym_cli_commands::context::{get_network_details, ClientArgs};
use nym_crypto::asymmetric::identity;
mod commands;
use nym_bin_common::logging::setup_logging;
use nym_sphinx_addressing;
// use common::nymsphinx::addressing;
#[derive(Debug, Parser)]
#[clap(name = "nym cosmos tx signer ")]
@@ -24,7 +16,7 @@ struct Cli {
// mnemonic: Option<bip39::Mnemonic>,
// TODO add SP address
#[clap(subcommand)]
command: Option<Commands>,
}