Separate migrations from util (#6690)

* separate migration from util and make its dependencies into libs:

* snappy
* kvdb
* error
* common

* renamed common -> macros

* util error does not depend on snappy module

* ethsync does not depend on util nor ethcore_error

* nibbleslice and nibblevec merged with patricia_trie crate

* removed unused dependencies from util

* util journaldb traits does not need to be public

* util_error

* fixed ethcore compile error

* ignore .swo files

* Update chain.rs
This commit is contained in:
Marek Kotewicz
2017-10-10 20:01:27 +02:00
committed by GitHub
parent 4e8853c9f7
commit 6279ff32f5
86 changed files with 322 additions and 170 deletions

View File

@@ -57,12 +57,14 @@ rlp = { path = "../util/rlp" }
stats = { path = "../util/stats" }
vm = { path = "../ethcore/vm" }
hash = { path = "../util/hash" }
kvdb = { path = "../util/kvdb" }
hardware-wallet = { path = "../hw" }
clippy = { version = "0.0.103", optional = true}
pretty_assertions = "0.1"
[dev-dependencies]
macros = { path = "../util/macros" }
ethcore-network = { path = "../util/network" }
[features]

View File

@@ -50,6 +50,7 @@ extern crate ethcore_devtools as devtools;
extern crate ethcore_io as io;
extern crate ethcore_ipc;
extern crate ethcore_light as light;
extern crate ethcore_util as util;
extern crate ethcrypto as crypto;
extern crate ethkey;
extern crate ethstore;
@@ -64,11 +65,10 @@ extern crate rlp;
extern crate stats;
extern crate hash;
extern crate hardware_wallet;
extern crate kvdb;
#[macro_use]
extern crate log;
#[cfg_attr(test, macro_use)]
extern crate ethcore_util as util;
#[macro_use]
extern crate jsonrpc_macros;
#[macro_use]
@@ -81,6 +81,10 @@ extern crate ethjson;
#[macro_use]
extern crate pretty_assertions;
#[cfg(test)]
#[macro_use]
extern crate macros;
pub extern crate jsonrpc_ws_server as ws;
mod authcodes;

View File

@@ -33,6 +33,7 @@ use io::IoChannel;
use bigint::prelude::U256;
use bigint::hash::H256;
use util::Address;
use kvdb::in_memory;
use jsonrpc_core::IoHandler;
use v1::impls::{EthClient, SigningUnsafeClient};
@@ -130,7 +131,7 @@ impl EthTester {
let client = Client::new(
ClientConfig::default(),
&spec,
Arc::new(::util::kvdb::in_memory(::ethcore::db::NUM_COLUMNS.unwrap_or(0))),
Arc::new(in_memory(::ethcore::db::NUM_COLUMNS.unwrap_or(0))),
miner_service.clone(),
IoChannel::disconnected(),
).unwrap();