diff --git a/benches/bank.rs b/benches/bank.rs index 85d3cebaa9..9ea15b771e 100644 --- a/benches/bank.rs +++ b/benches/bank.rs @@ -7,9 +7,9 @@ extern crate test; use solana::bank::*; use solana::mint::Mint; -use solana::signature::{Keypair, KeypairUtil}; use solana::system_transaction::SystemTransaction; use solana_sdk::hash::hash; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use test::Bencher; diff --git a/benches/banking_stage.rs b/benches/banking_stage.rs index 231c37ae15..4ba256bae0 100644 --- a/benches/banking_stage.rs +++ b/benches/banking_stage.rs @@ -13,10 +13,10 @@ use solana::banking_stage::{BankingStage, NUM_THREADS}; use solana::entry::Entry; use solana::mint::Mint; use solana::packet::to_packets_chunked; -use solana::signature::{KeypairUtil, Signature}; use solana::system_transaction::SystemTransaction; use solana_sdk::hash::hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{KeypairUtil, Signature}; use solana_sdk::transaction::Transaction; use std::iter; use std::sync::mpsc::{channel, Receiver}; diff --git a/benches/ledger.rs b/benches/ledger.rs index a01db80892..514b8e5529 100644 --- a/benches/ledger.rs +++ b/benches/ledger.rs @@ -5,9 +5,9 @@ extern crate test; use solana::entry::reconstruct_entries_from_blobs; use solana::ledger::{next_entries, Block}; -use solana::signature::{Keypair, KeypairUtil}; use solana::system_transaction::SystemTransaction; use solana_sdk::hash::{hash, Hash}; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use test::Bencher; diff --git a/benches/signature.rs b/benches/signature.rs index 3d8646d54f..21d50daab2 100644 --- a/benches/signature.rs +++ b/benches/signature.rs @@ -1,5 +1,6 @@ #![feature(test)] extern crate solana; +extern crate solana_sdk; extern crate test; use solana::signature::GenKeys; diff --git a/src/bank.rs b/src/bank.rs index b7a167d8f1..a0d600304b 100644 --- a/src/bank.rs +++ b/src/bank.rs @@ -23,11 +23,11 @@ use program::ProgramError; use rayon::prelude::*; use rpc::RpcSignatureStatus; use runtime::{self, RuntimeError}; -use signature::Keypair; -use signature::Signature; use solana_sdk::account::Account; use solana_sdk::hash::{hash, Hash}; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::Keypair; +use solana_sdk::signature::Signature; use solana_sdk::system_instruction::SystemInstruction; use solana_sdk::timing::{duration_as_us, timestamp}; use solana_sdk::transaction::Transaction; @@ -1369,9 +1369,10 @@ mod tests { use entry::Entry; use jsonrpc_macros::pubsub::{Subscriber, SubscriptionId}; use ledger; - use signature::Keypair; - use signature::{GenKeys, KeypairUtil}; + use signature::GenKeys; use solana_sdk::hash::hash; + use solana_sdk::signature::Keypair; + use solana_sdk::signature::KeypairUtil; use solana_sdk::transaction::Instruction; use std; use storage_program; diff --git a/src/banking_stage.rs b/src/banking_stage.rs index 84c0169c38..024b50843a 100644 --- a/src/banking_stage.rs +++ b/src/banking_stage.rs @@ -255,7 +255,7 @@ mod tests { use ledger::Block; use mint::Mint; use packet::to_packets; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::thread::sleep; use system_transaction::SystemTransaction; diff --git a/src/bin/bench-tps.rs b/src/bin/bench-tps.rs index 0d5769a844..7c846429dd 100644 --- a/src/bin/bench-tps.rs +++ b/src/bin/bench-tps.rs @@ -15,13 +15,14 @@ use solana::cluster_info::{ClusterInfo, NodeInfo}; use solana::logger; use solana::ncp::Ncp; use solana::service::Service; -use solana::signature::{read_keypair, GenKeys, Keypair, KeypairUtil}; +use solana::signature::GenKeys; use solana::system_transaction::SystemTransaction; use solana::thin_client::{poll_gossip_for_leader, ThinClient}; use solana::window::default_window; use solana_drone::drone::{request_airdrop_transaction, DRONE_PORT}; use solana_metrics::influxdb; use solana_sdk::hash::Hash; +use solana_sdk::signature::{read_keypair, Keypair, KeypairUtil}; use solana_sdk::timing::timestamp; use solana_sdk::timing::{duration_as_ms, duration_as_s}; use solana_sdk::transaction::Transaction; diff --git a/src/bin/fullnode-config.rs b/src/bin/fullnode-config.rs index 26ad46e352..a1d5aa9bf2 100644 --- a/src/bin/fullnode-config.rs +++ b/src/bin/fullnode-config.rs @@ -4,6 +4,7 @@ extern crate dirs; extern crate ring; extern crate serde_json; extern crate solana; +extern crate solana_sdk; use clap::{App, Arg}; use ring::rand::SystemRandom; @@ -12,7 +13,7 @@ use solana::cluster_info::FULLNODE_PORT_RANGE; use solana::fullnode::Config; use solana::logger; use solana::netutil::{get_ip_addr, get_public_ip_addr, parse_port_or_addr}; -use solana::signature::read_pkcs8; +use solana_sdk::signature::read_pkcs8; use std::io; use std::net::SocketAddr; diff --git a/src/bin/fullnode.rs b/src/bin/fullnode.rs index 254703b621..c5d68c1d66 100644 --- a/src/bin/fullnode.rs +++ b/src/bin/fullnode.rs @@ -7,6 +7,7 @@ extern crate serde_json; #[macro_use] extern crate solana; extern crate solana_metrics; +extern crate solana_sdk; use clap::{App, Arg}; use solana::client::mk_client; @@ -15,10 +16,10 @@ use solana::fullnode::{Config, Fullnode, FullnodeReturnType}; use solana::leader_scheduler::LeaderScheduler; use solana::logger; use solana::netutil::find_available_port_in_range; -use solana::signature::{Keypair, KeypairUtil}; use solana::thin_client::poll_gossip_for_leader; use solana::vote_program::VoteProgram; use solana::vote_transaction::VoteTransaction; +use solana_sdk::signature::{Keypair, KeypairUtil}; use std::fs::File; use std::net::{Ipv4Addr, SocketAddr}; use std::process::exit; diff --git a/src/bin/genesis.rs b/src/bin/genesis.rs index e299b94ae4..10ad7eafe3 100644 --- a/src/bin/genesis.rs +++ b/src/bin/genesis.rs @@ -5,13 +5,14 @@ extern crate atty; extern crate clap; extern crate serde_json; extern crate solana; +extern crate solana_sdk; extern crate untrusted; use clap::{App, Arg}; use solana::fullnode::Config; use solana::ledger::LedgerWriter; use solana::mint::Mint; -use solana::signature::KeypairUtil; +use solana_sdk::signature::KeypairUtil; use std::error; use std::fs::File; use std::path::Path; diff --git a/src/bin/replicator.rs b/src/bin/replicator.rs index f3b20f0058..ca4369ee12 100644 --- a/src/bin/replicator.rs +++ b/src/bin/replicator.rs @@ -15,9 +15,9 @@ use solana::fullnode::Config; use solana::ledger::LEDGER_DATA_FILE; use solana::logger; use solana::replicator::{sample_file, Replicator}; -use solana::signature::{Keypair, KeypairUtil}; use solana::storage_transaction::StorageTransaction; use solana_drone::drone::{request_airdrop_transaction, DRONE_PORT}; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::fs::File; use std::net::{Ipv4Addr, SocketAddr}; diff --git a/src/bin/wallet.rs b/src/bin/wallet.rs index 1d806fa8d6..0694e1f9de 100644 --- a/src/bin/wallet.rs +++ b/src/bin/wallet.rs @@ -3,11 +3,12 @@ extern crate clap; extern crate dirs; #[macro_use] extern crate solana; +extern crate solana_sdk; use clap::{App, Arg, ArgMatches, SubCommand}; use solana::logger; -use solana::signature::{read_keypair, KeypairUtil}; use solana::wallet::{gen_keypair_file, parse_command, process_command, WalletConfig, WalletError}; +use solana_sdk::signature::{read_keypair, KeypairUtil}; use std::error; use std::net::SocketAddr; diff --git a/src/budget_expr.rs b/src/budget_expr.rs index ef1a1fbebd..8d2b5ef194 100644 --- a/src/budget_expr.rs +++ b/src/budget_expr.rs @@ -141,7 +141,7 @@ impl BudgetExpr { #[cfg(test)] mod tests { use super::*; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; #[test] fn test_signature_satisfied() { diff --git a/src/budget_program.rs b/src/budget_program.rs index 499853a6ee..f9b375e62e 100644 --- a/src/budget_program.rs +++ b/src/budget_program.rs @@ -265,10 +265,11 @@ mod test { use bincode::serialize; use budget_transaction::BudgetTransaction; use chrono::prelude::{DateTime, NaiveDate, Utc}; - use signature::{GenKeys, Keypair, KeypairUtil}; + use signature::GenKeys; use solana_sdk::account::Account; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; fn process_transaction(tx: &Transaction, accounts: &mut [Account]) -> Result<(), BudgetError> { diff --git a/src/budget_transaction.rs b/src/budget_transaction.rs index 05be24fdf9..fa1aad100b 100644 --- a/src/budget_transaction.rs +++ b/src/budget_transaction.rs @@ -6,9 +6,9 @@ use budget_instruction::Instruction; use budget_program; use chrono::prelude::*; use payment_plan::Payment; -use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::system_instruction::{SystemInstruction, SYSTEM_PROGRAM_ID}; use solana_sdk::transaction::{self, Transaction}; @@ -227,7 +227,6 @@ impl BudgetTransaction for Transaction { mod tests { use super::*; use bincode::{deserialize, serialize}; - use signature::KeypairUtil; #[test] fn test_claim() { diff --git a/src/cluster_info.rs b/src/cluster_info.rs index 9ba5604bdc..1dfa0ea63f 100644 --- a/src/cluster_info.rs +++ b/src/cluster_info.rs @@ -28,9 +28,9 @@ use rand::{thread_rng, Rng}; use rayon::prelude::*; use result::Result; use rpc::RPC_PORT; -use signature::{Keypair, KeypairUtil, Signable, Signature}; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil, Signable, Signature}; use solana_sdk::timing::{duration_as_ms, timestamp}; use std::collections::HashMap; use std::io; @@ -1120,8 +1120,8 @@ mod tests { use logger; use packet::SharedBlob; use result::Error; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::{hash, Hash}; + use solana_sdk::signature::{Keypair, KeypairUtil}; use std::fs::remove_dir_all; use std::net::{IpAddr, Ipv4Addr, SocketAddr}; use std::sync::{Arc, RwLock}; diff --git a/src/compute_leader_finality_service.rs b/src/compute_leader_finality_service.rs index e378484b4e..7e335e512c 100644 --- a/src/compute_leader_finality_service.rs +++ b/src/compute_leader_finality_service.rs @@ -138,8 +138,8 @@ pub mod tests { use compute_leader_finality_service::ComputeLeaderFinalityService; use logger; use mint::Mint; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::sync::Arc; use std::thread::sleep; diff --git a/src/contact_info.rs b/src/contact_info.rs index 40aa333f18..c55d961bb9 100644 --- a/src/contact_info.rs +++ b/src/contact_info.rs @@ -1,7 +1,7 @@ use bincode::serialize; use rpc::RPC_PORT; -use signature::{Keypair, KeypairUtil, Signable, Signature}; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil, Signable, Signature}; use solana_sdk::timing::timestamp; use std::net::{IpAddr, Ipv4Addr, SocketAddr}; diff --git a/src/crds.rs b/src/crds.rs index 4257f7b5df..f61920c6d7 100644 --- a/src/crds.rs +++ b/src/crds.rs @@ -164,7 +164,7 @@ mod test { use super::*; use contact_info::ContactInfo; use crds_value::LeaderId; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; #[test] fn test_insert() { diff --git a/src/crds_gossip.rs b/src/crds_gossip.rs index 400cf3c61d..40a69700a2 100644 --- a/src/crds_gossip.rs +++ b/src/crds_gossip.rs @@ -162,8 +162,8 @@ mod test { use crds_gossip_push::CRDS_GOSSIP_PUSH_MSG_TIMEOUT_MS; use crds_value::CrdsValueLabel; use rayon::prelude::*; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::timing::timestamp; use std::collections::HashMap; use std::sync::{Arc, Mutex}; diff --git a/src/crds_gossip_pull.rs b/src/crds_gossip_pull.rs index 5f1f1a1e49..c291157280 100644 --- a/src/crds_gossip_pull.rs +++ b/src/crds_gossip_pull.rs @@ -196,7 +196,7 @@ mod test { use super::*; use contact_info::ContactInfo; use crds_value::LeaderId; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; #[test] fn test_new_pull_request() { diff --git a/src/crds_gossip_push.rs b/src/crds_gossip_push.rs index 078001dfd4..3d793c69f1 100644 --- a/src/crds_gossip_push.rs +++ b/src/crds_gossip_push.rs @@ -244,7 +244,7 @@ impl CrdsGossipPush { mod test { use super::*; use contact_info::ContactInfo; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; #[test] fn test_process_push() { let mut crds = Crds::default(); diff --git a/src/crds_value.rs b/src/crds_value.rs index 600933a33c..8b043f863c 100644 --- a/src/crds_value.rs +++ b/src/crds_value.rs @@ -1,7 +1,7 @@ use bincode::serialize; use contact_info::ContactInfo; -use signature::{Keypair, Signable, Signature}; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, Signable, Signature}; use solana_sdk::transaction::Transaction; use std::fmt; diff --git a/src/db_window.rs b/src/db_window.rs index 5538ab7dff..2804e7a50b 100644 --- a/src/db_window.rs +++ b/src/db_window.rs @@ -358,7 +358,7 @@ mod test { use ledger::{get_tmp_ledger_path, make_tiny_test_entries, Block}; use packet::{Blob, Packet, Packets, SharedBlob, PACKET_DATA_SIZE}; use rocksdb::{Options, DB}; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; use std::io; use std::io::Write; use std::net::UdpSocket; diff --git a/src/entry.rs b/src/entry.rs index b185c0474c..054686365e 100644 --- a/src/entry.rs +++ b/src/entry.rs @@ -275,8 +275,8 @@ mod tests { use budget_transaction::BudgetTransaction; use chrono::prelude::*; use entry::Entry; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use system_transaction::SystemTransaction; diff --git a/src/erasure.rs b/src/erasure.rs index bdd7f6381e..42f22ad4ae 100644 --- a/src/erasure.rs +++ b/src/erasure.rs @@ -598,8 +598,8 @@ mod test { use logger; use packet::{index_blobs, SharedBlob, BLOB_DATA_SIZE, BLOB_HEADER_SIZE, BLOB_SIZE}; use rand::{thread_rng, Rng}; - use signature::{Keypair, KeypairUtil}; use solana_sdk::pubkey::Pubkey; + use solana_sdk::signature::{Keypair, KeypairUtil}; // use std::sync::{Arc, RwLock}; use window::WindowSlot; diff --git a/src/fullnode.rs b/src/fullnode.rs index b6cc89632b..de06ec4ebc 100644 --- a/src/fullnode.rs +++ b/src/fullnode.rs @@ -10,8 +10,8 @@ use ncp::Ncp; use rpc::JsonRpcService; use rpc_pubsub::PubSubService; use service::Service; -use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::timing::timestamp; use std::net::UdpSocket; use std::net::{IpAddr, Ipv4Addr, SocketAddr}; @@ -656,7 +656,7 @@ mod tests { use ledger::{create_tmp_genesis, create_tmp_sample_ledger, tmp_copy_ledger, LedgerWriter}; use packet::make_consecutive_blobs; use service::Service; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; use std::cmp; use std::fs::remove_dir_all; use std::net::UdpSocket; diff --git a/src/leader_scheduler.rs b/src/leader_scheduler.rs index 54e57cdd29..c2d30d12c6 100644 --- a/src/leader_scheduler.rs +++ b/src/leader_scheduler.rs @@ -7,9 +7,9 @@ use bincode::serialize; use byteorder::{LittleEndian, ReadBytesExt}; use entry::Entry; use ledger::create_ticks; -use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::{hash, Hash}; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::collections::HashSet; use std::io::Cursor; @@ -511,9 +511,9 @@ mod tests { DEFAULT_LEADER_ROTATION_INTERVAL, DEFAULT_SEED_ROTATION_INTERVAL, }; use mint::Mint; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::collections::HashSet; use std::hash::Hash as StdHash; diff --git a/src/ledger.rs b/src/ledger.rs index db74eca840..b3145970af 100644 --- a/src/ledger.rs +++ b/src/ledger.rs @@ -10,9 +10,9 @@ use log::Level::Trace; use mint::Mint; use packet::{SharedBlob, BLOB_DATA_SIZE}; use rayon::prelude::*; -use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::{hash, Hash}; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::fs::{copy, create_dir_all, remove_dir_all, File, OpenOptions}; use std::io::prelude::*; @@ -704,8 +704,8 @@ mod tests { use budget_transaction::BudgetTransaction; use entry::{next_entry, reconstruct_entries_from_blobs, Entry}; use packet::{to_blobs, BLOB_DATA_SIZE, PACKET_DATA_SIZE}; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std; use std::net::{IpAddr, Ipv4Addr, SocketAddr}; diff --git a/src/loader_transaction.rs b/src/loader_transaction.rs index 03977e53be..6065fb5902 100644 --- a/src/loader_transaction.rs +++ b/src/loader_transaction.rs @@ -1,9 +1,9 @@ //! The `dynamic_transaction` module provides functionality for loading and calling a program -use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; use solana_sdk::loader_instruction::LoaderInstruction; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; pub trait LoaderTransaction { diff --git a/src/mint.rs b/src/mint.rs index 0b46109543..8d3f73f9c9 100644 --- a/src/mint.rs +++ b/src/mint.rs @@ -2,9 +2,9 @@ use entry::Entry; use ring::rand::SystemRandom; -use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::{hash, Hash}; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use system_transaction::SystemTransaction; use untrusted::Input; diff --git a/src/packet.rs b/src/packet.rs index ab56e184dc..a15869b6d0 100644 --- a/src/packet.rs +++ b/src/packet.rs @@ -467,8 +467,8 @@ mod tests { to_packets, Blob, Meta, Packet, Packets, SharedBlob, SharedPackets, NUM_PACKETS, PACKET_DATA_SIZE, }; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::io; use std::io::Write; diff --git a/src/replicate_stage.rs b/src/replicate_stage.rs index bccf44eef4..7478babe07 100644 --- a/src/replicate_stage.rs +++ b/src/replicate_stage.rs @@ -11,8 +11,8 @@ use log::Level; use packet::BlobError; use result::{Error, Result}; use service::Service; -use signature::{Keypair, KeypairUtil}; use solana_metrics::{influxdb, submit}; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::timing::duration_as_ms; use std::net::UdpSocket; use std::sync::atomic::{AtomicBool, AtomicUsize, Ordering}; @@ -253,8 +253,8 @@ mod test { use replicate_stage::{ReplicateStage, ReplicateStageReturnType}; use result::Error; use service::Service; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use std::fs::remove_dir_all; use std::sync::atomic::{AtomicBool, Ordering}; use std::sync::mpsc::channel; diff --git a/src/replicator.rs b/src/replicator.rs index e8dd5d49c6..f1f00ec65c 100644 --- a/src/replicator.rs +++ b/src/replicator.rs @@ -177,8 +177,8 @@ impl Replicator { mod tests { use logger; use replicator::sample_file; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use std::fs::File; use std::fs::{create_dir_all, remove_file}; use std::io::Write; diff --git a/src/rpc.rs b/src/rpc.rs index 672bca195d..8b44919f1d 100644 --- a/src/rpc.rs +++ b/src/rpc.rs @@ -8,10 +8,10 @@ use jsonrpc_core::*; use jsonrpc_http_server::*; use packet::PACKET_DATA_SIZE; use service::Service; -use signature::Signature; use solana_drone::drone::{request_airdrop_transaction, DRONE_PORT}; use solana_sdk::account::Account; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::Signature; use solana_sdk::transaction::Transaction; use std::mem; use std::net::{SocketAddr, UdpSocket}; @@ -372,8 +372,8 @@ mod tests { use mint::Mint; use reqwest; use reqwest::header::CONTENT_TYPE; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::{hash, Hash}; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::fs::remove_dir_all; use std::net::{IpAddr, Ipv4Addr, SocketAddr}; diff --git a/src/rpc_pubsub.rs b/src/rpc_pubsub.rs index 11d9eec236..195c8c029e 100644 --- a/src/rpc_pubsub.rs +++ b/src/rpc_pubsub.rs @@ -9,9 +9,9 @@ use jsonrpc_pubsub::{PubSubHandler, Session, SubscriptionId}; use jsonrpc_ws_server::{RequestContext, Sender, ServerBuilder}; use rpc::{JsonRpcRequestProcessor, RpcSignatureStatus}; use service::Service; -use signature::{Keypair, KeypairUtil, Signature}; use solana_sdk::account::Account; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil, Signature}; use std::collections::HashMap; use std::mem; use std::net::SocketAddr; @@ -250,7 +250,7 @@ mod tests { use budget_transaction::BudgetTransaction; use jsonrpc_core::futures::sync::mpsc; use mint::Mint; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::net::{IpAddr, Ipv4Addr}; use system_transaction::SystemTransaction; diff --git a/src/signature.rs b/src/signature.rs index fa283ff885..8cb5d3ca9b 100644 --- a/src/signature.rs +++ b/src/signature.rs @@ -2,10 +2,9 @@ use rand::{ChaChaRng, Rng, SeedableRng}; use rayon::prelude::*; +use solana_sdk::signature::Keypair; use untrusted::Input; -pub use solana_sdk::signature::*; - pub struct GenKeys { generator: ChaChaRng, } @@ -38,6 +37,7 @@ impl GenKeys { mod tests { use super::*; pub use solana_sdk::pubkey::Pubkey; + use solana_sdk::signature::KeypairUtil; use std::collections::HashSet; #[test] diff --git a/src/sigverify.rs b/src/sigverify.rs index 213a6bb78b..63637b954b 100644 --- a/src/sigverify.rs +++ b/src/sigverify.rs @@ -9,8 +9,8 @@ use counter::Counter; use log::Level; use packet::{Packet, SharedPackets}; use result::Result; -use signature::Signature; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::Signature; #[cfg(test)] use solana_sdk::transaction::Transaction; use std::io; @@ -70,8 +70,8 @@ pub fn init() { fn verify_packet(packet: &Packet) -> u8 { use ring::signature; - use signature::Signature; use solana_sdk::pubkey::Pubkey; + use solana_sdk::signature::Signature; use untrusted; let (sig_len, sig_start, msg_start, pubkey_start) = get_packet_offsets(packet, 0); @@ -325,9 +325,9 @@ mod tests { use bincode::serialize; use budget_program; use packet::{Packet, SharedPackets}; - use signature::{Keypair, KeypairUtil}; use sigverify; use solana_sdk::hash::Hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::system_instruction::SystemInstruction; use solana_sdk::transaction::{Instruction, Transaction}; use system_program; diff --git a/src/storage_program.rs b/src/storage_program.rs index 11a0d7b8be..24f15af57c 100644 --- a/src/storage_program.rs +++ b/src/storage_program.rs @@ -69,8 +69,7 @@ pub fn process( #[cfg(test)] mod test { use super::*; - use signature::Keypair; - use signature::KeypairUtil; + use solana_sdk::signature::{Keypair, KeypairUtil}; #[test] fn test_storage_tx() { diff --git a/src/storage_stage.rs b/src/storage_stage.rs index 03efe1abd3..2d98904f10 100644 --- a/src/storage_stage.rs +++ b/src/storage_stage.rs @@ -8,10 +8,10 @@ use entry::EntryReceiver; use rand::{ChaChaRng, Rng, SeedableRng}; use result::{Error, Result}; use service::Service; -use signature::Keypair; -use signature::Signature; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::Keypair; +use solana_sdk::signature::Signature; use std::mem::size_of; use std::sync::atomic::{AtomicBool, Ordering}; use std::sync::mpsc::RecvTimeoutError; @@ -265,8 +265,8 @@ mod tests { use logger; use rayon::prelude::*; use service::Service; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::cmp::{max, min}; use std::fs::remove_dir_all; diff --git a/src/storage_transaction.rs b/src/storage_transaction.rs index 33f4358aa1..a46974d128 100644 --- a/src/storage_transaction.rs +++ b/src/storage_transaction.rs @@ -1,5 +1,5 @@ -use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use storage_program::{self, StorageProgram}; diff --git a/src/system_program.rs b/src/system_program.rs index afccaabc32..6e487f4b2f 100644 --- a/src/system_program.rs +++ b/src/system_program.rs @@ -133,10 +133,10 @@ pub fn process( #[cfg(test)] mod test { use super::*; - use signature::{Keypair, KeypairUtil}; use solana_sdk::account::Account; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Instruction; use system_transaction::SystemTransaction; diff --git a/src/system_transaction.rs b/src/system_transaction.rs index 6e52dde871..8237b9699d 100644 --- a/src/system_transaction.rs +++ b/src/system_transaction.rs @@ -1,8 +1,8 @@ //! The `system_transaction` module provides functionality for creating system transactions. -use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::system_instruction::SystemInstruction; use solana_sdk::transaction::{Instruction, Transaction}; use system_program; diff --git a/src/thin_client.rs b/src/thin_client.rs index bc8039f1cc..25a63554ff 100644 --- a/src/thin_client.rs +++ b/src/thin_client.rs @@ -14,12 +14,12 @@ use reqwest; use result::{Error, Result}; use rpc_request::{RpcClient, RpcRequest}; use serde_json; -use signature::{Keypair, Signature}; use solana_metrics; use solana_metrics::influxdb; use solana_sdk::account::Account; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, Signature}; use solana_sdk::timing; use solana_sdk::transaction::Transaction; use std; @@ -464,7 +464,7 @@ mod tests { use ledger::create_tmp_ledger_with_mint; use logger; use mint::Mint; - use signature::{Keypair, KeypairUtil}; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::system_instruction::SystemInstruction; use std::fs::remove_dir_all; use vote_program::VoteProgram; diff --git a/src/tvu.rs b/src/tvu.rs index 11d3006e0e..8b42d8a3b1 100644 --- a/src/tvu.rs +++ b/src/tvu.rs @@ -18,8 +18,8 @@ use ledger_write_stage::LedgerWriteStage; use replicate_stage::{ReplicateStage, ReplicateStageReturnType}; use retransmit_stage::RetransmitStage; use service::Service; -use signature::Keypair; use solana_sdk::hash::Hash; +use solana_sdk::signature::Keypair; use std::net::UdpSocket; use std::sync::atomic::{AtomicBool, Ordering}; use std::sync::{Arc, RwLock}; @@ -177,8 +177,8 @@ pub mod tests { use packet::SharedBlob; use rocksdb::{Options, DB}; use service::Service; - use signature::{Keypair, KeypairUtil}; use solana_sdk::hash::Hash; + use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; use std::fs::remove_dir_all; use std::net::UdpSocket; diff --git a/src/vote_stage.rs b/src/vote_stage.rs index c7f8ad5266..a749b84fa8 100644 --- a/src/vote_stage.rs +++ b/src/vote_stage.rs @@ -7,8 +7,8 @@ use counter::Counter; use log::Level; use packet::SharedBlob; use result::{Error, Result}; -use signature::Keypair; use solana_sdk::hash::Hash; +use solana_sdk::signature::Keypair; use solana_sdk::transaction::Transaction; use std::net::SocketAddr; use std::sync::atomic::AtomicUsize; diff --git a/src/vote_transaction.rs b/src/vote_transaction.rs index 01bcb2ab79..f568f8f350 100644 --- a/src/vote_transaction.rs +++ b/src/vote_transaction.rs @@ -5,11 +5,11 @@ use bank::Bank; use bincode::deserialize; #[cfg(test)] use result::Result; -use signature::Keypair; -#[cfg(test)] -use signature::KeypairUtil; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::Keypair; +#[cfg(test)] +use solana_sdk::signature::KeypairUtil; use solana_sdk::system_instruction::SystemInstruction; use solana_sdk::transaction::{Instruction, Transaction}; use system_program; diff --git a/src/wallet.rs b/src/wallet.rs index 6413fdd3e5..67da04400d 100644 --- a/src/wallet.rs +++ b/src/wallet.rs @@ -13,10 +13,10 @@ use ring::signature::Ed25519KeyPair; use rpc::RpcSignatureStatus; use rpc_request::{RpcClient, RpcRequest}; use serde_json; -use signature::{Keypair, KeypairUtil, Signature}; use solana_drone::drone::{request_airdrop_transaction, DRONE_PORT}; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil, Signature}; use solana_sdk::transaction::Transaction; use std::fs::{self, File}; use std::io::Write; @@ -780,8 +780,8 @@ mod tests { use leader_scheduler::LeaderScheduler; use ledger::create_tmp_genesis; use serde_json::Value; - use signature::{read_keypair, read_pkcs8, Keypair, KeypairUtil}; use solana_drone::drone::run_local_drone; + use solana_sdk::signature::{read_keypair, read_pkcs8, Keypair, KeypairUtil}; use std::fs::remove_dir_all; use std::sync::mpsc::channel; use std::sync::{Arc, RwLock}; diff --git a/tests/data_replicator.rs b/tests/data_replicator.rs index 4bd7977ec0..5472491f25 100644 --- a/tests/data_replicator.rs +++ b/tests/data_replicator.rs @@ -11,7 +11,7 @@ use solana::ncp::Ncp; use solana::packet::{Blob, SharedBlob}; use solana::result; use solana::service::Service; -use solana::signature::{Keypair, KeypairUtil}; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::timing::timestamp; use std::net::UdpSocket; use std::sync::atomic::{AtomicBool, Ordering}; diff --git a/tests/multinode.rs b/tests/multinode.rs index e8217c6361..9e20075964 100644 --- a/tests/multinode.rs +++ b/tests/multinode.rs @@ -24,12 +24,12 @@ use solana::packet::SharedBlob; use solana::poh_service::NUM_TICKS_PER_SECOND; use solana::result; use solana::service::Service; -use solana::signature::{Keypair, KeypairUtil}; use solana::system_transaction::SystemTransaction; use solana::thin_client::{retry_get_balance, ThinClient}; use solana::window::default_window; use solana_sdk::hash::Hash; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::timing::{duration_as_ms, duration_as_s}; use solana_sdk::transaction::Transaction; use std::collections::{HashSet, VecDeque}; diff --git a/tests/programs.rs b/tests/programs.rs index f18701742a..3a43e8c259 100644 --- a/tests/programs.rs +++ b/tests/programs.rs @@ -11,9 +11,9 @@ use solana::loader_transaction::LoaderTransaction; use solana::logger; use solana::mint::Mint; use solana::native_loader; -use solana::signature::{Keypair, KeypairUtil}; use solana::system_transaction::SystemTransaction; use solana_sdk::pubkey::Pubkey; +use solana_sdk::signature::{Keypair, KeypairUtil}; use solana_sdk::transaction::Transaction; #[cfg(feature = "bpf_c")] use std::env; diff --git a/tests/replicator.rs b/tests/replicator.rs index 8d3f8eecea..936221bcc2 100644 --- a/tests/replicator.rs +++ b/tests/replicator.rs @@ -1,6 +1,7 @@ #[macro_use] extern crate log; extern crate solana; +extern crate solana_sdk; use solana::client::mk_client; use solana::cluster_info::Node; @@ -10,7 +11,7 @@ use solana::leader_scheduler::LeaderScheduler; use solana::ledger::{create_tmp_genesis, get_tmp_ledger_path, read_ledger}; use solana::logger; use solana::replicator::Replicator; -use solana::signature::{Keypair, KeypairUtil}; +use solana_sdk::signature::{Keypair, KeypairUtil}; use std::fs::remove_dir_all; use std::sync::atomic::{AtomicBool, Ordering}; use std::sync::Arc;