Skip to content

Commit

Permalink
Cleaning up dependencies (paritytech#125)
Browse files Browse the repository at this point in the history
* cargo update
* Update to latest ctrlc crate
* Update vergen
* Update to latest pretty_assertions
* Update log
* Update parking_lot
* Update hex-rustc
  • Loading branch information
gnunicorn committed Feb 8, 2019
1 parent 69937fd commit 98b9b4b
Show file tree
Hide file tree
Showing 16 changed files with 122 additions and 117 deletions.
181 changes: 97 additions & 84 deletions Cargo.lock

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ build = "build.rs"
error-chain = "0.12"
polkadot-cli = { path = "cli" }
futures = "0.1"
ctrlc = { git = "https://github.com/paritytech/rust-ctrlc.git" }
ctrlc = { version = "3.0", features = ["termination"] }

[build-dependencies]
vergen = "0.1"
vergen = "3"

[workspace]
members = [
Expand Down
4 changes: 2 additions & 2 deletions availability-store/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ authors = ["Parity Technologies <[email protected]>"]

[dependencies]
polkadot-primitives = { path = "../primitives" }
parking_lot = "0.4"
log = "0.3"
parking_lot = "0.7.1"
log = "0.4.6"
parity-codec = "3.0"
substrate-primitives = { git = "https://github.com/paritytech/substrate" }
kvdb = { git = "https://github.com/paritytech/parity-common", rev="616b40150ded71f57f650067fcbc5c99d7c343e6" }
Expand Down
4 changes: 2 additions & 2 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@

extern crate vergen;

use vergen::{vergen, OutputFns};
use vergen::{ConstantsFlags, generate_cargo_keys};

const ERROR_MSG: &'static str = "Failed to generate metadata files";

fn main() {
vergen(OutputFns::all()).expect(ERROR_MSG);
generate_cargo_keys(ConstantsFlags::all()).expect(ERROR_MSG);
println!("cargo:rerun-if-changed=.git/HEAD");
}
2 changes: 1 addition & 1 deletion cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ authors = ["Parity Technologies <[email protected]>"]
description = "Polkadot node implementation in Rust."

[dependencies]
log = "0.3"
log = "0.4.6"
tokio = "0.1.7"
futures = "0.1.17"
exit-future = "0.1"
Expand Down
4 changes: 2 additions & 2 deletions consensus/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ authors = ["Parity Technologies <[email protected]>"]

[dependencies]
futures = "0.1.17"
parking_lot = "0.4"
parking_lot = "0.7.1"
tokio = "0.1.7"
error-chain = "0.12"
log = "0.3"
log = "0.4.6"
exit-future = "0.1"
parity-codec = "3.0"
polkadot-availability-store = { path = "../availability-store" }
Expand Down
2 changes: 1 addition & 1 deletion network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ description = "Polkadot-specific networking protocol"

[dependencies]
arrayvec = "0.4"
parking_lot = "0.4"
parking_lot = "0.7.1"
polkadot-availability-store = { path = "../availability-store" }
polkadot-consensus = { path = "../consensus" }
polkadot-primitives = { path = "../primitives" }
Expand Down
2 changes: 1 addition & 1 deletion primitives/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ sr-primitives = { git = "https://github.com/paritytech/substrate", default-featu

[dev-dependencies]
substrate-serializer = { git = "https://github.com/paritytech/substrate" }
pretty_assertions = "0.4"
pretty_assertions = "0.5.1"

[features]
default = ["std"]
Expand Down
3 changes: 2 additions & 1 deletion runtime/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ authors = ["Parity Technologies <[email protected]>"]

[dependencies]
bitvec = { version = "0.8", default-features = false, features = ["alloc"] }
rustc-hex = "1.0"
rustc-hex = { version = "2.0.1", default-features = false }
log = { version = "0.3", optional = true }
serde = { version = "1.0", default-features = false }
serde_derive = { version = "1.0", optional = true }
Expand Down Expand Up @@ -50,6 +50,7 @@ default = ["std"]
std = [
"bitvec/std",
"polkadot-primitives/std",
"rustc-hex/std",
"parity-codec/std",
"parity-codec-derive/std",
"substrate-primitives/std",
Expand Down
10 changes: 3 additions & 7 deletions runtime/wasm/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions service/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ version = "0.3.0"
authors = ["Parity Technologies <[email protected]>"]

[dependencies]
parking_lot = "0.4"
parking_lot = "0.7.1"
error-chain = "0.12"
lazy_static = "1.0"
log = "0.3"
log = "0.4.6"
slog = "^2"
tokio = "0.1.7"
hex-literal = "0.1"
Expand Down
11 changes: 3 additions & 8 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,6 @@ use futures::{future, Future};

use std::cell::RefCell;

mod vergen {
#![allow(unused)]
include!(concat!(env!("OUT_DIR"), "/version.rs"));
}

// the regular polkadot worker simply does nothing until ctrl-c
struct Worker;
impl cli::IntoExit for Worker {
Expand All @@ -45,11 +40,11 @@ impl cli::IntoExit for Worker {
let (exit_send, exit) = oneshot::channel();

let exit_send_cell = RefCell::new(Some(exit_send));
ctrlc::CtrlC::set_handler(move || {
ctrlc::set_handler(move || {
if let Some(exit_send) = exit_send_cell.try_borrow_mut().expect("signal handler not reentrant; qed").take() {
exit_send.send(()).expect("Error sending exit notification");
}
});
}).expect("Error setting Ctrl-C handler");

exit.map_err(drop)
}
Expand All @@ -68,7 +63,7 @@ quick_main!(run);
fn run() -> cli::error::Result<()> {
let version = VersionInfo {
name: "Parity Polkadot",
commit: vergen::short_sha(),
commit: env!("VERGEN_SHA_SHORT"),
version: env!("CARGO_PKG_VERSION"),
executable_name: "polkadot",
author: "Parity Team <[email protected]>",
Expand Down
4 changes: 2 additions & 2 deletions test-parachains/adder/collator/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ polkadot-parachain = { path = "../../../parachain" }
polkadot-collator = { path = "../../../collator" }
polkadot-primitives = { path = "../../../primitives" }
substrate-primitives = { git = "https://github.com/paritytech/substrate" }
parking_lot = "0.4"
ctrlc = { git = "https://github.com/paritytech/rust-ctrlc.git" }
parking_lot = "0.7.1"
ctrlc = { version = "3.0", features = ["termination"] }
futures = "0.1"
exit-future = "0.1.2"
4 changes: 2 additions & 2 deletions test-parachains/adder/collator/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,11 @@ fn main() {
let (exit_send, exit) = exit_future::signal();

let exit_send_cell = RefCell::new(Some(exit_send));
ctrlc::CtrlC::set_handler(move || {
ctrlc::set_handler(move || {
if let Some(exit_send) = exit_send_cell.try_borrow_mut().expect("signal handler not reentrant; qed").take() {
exit_send.fire();
}
});
}).expect("Errror setting up ctrl-c handler");

let context = AdderContext {
db: Arc::new(Mutex::new(HashMap::new())),
Expand Down

0 comments on commit 98b9b4b

Please sign in to comment.