Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
8552090
Remove unneeded script
gavofyork Sep 11, 2018
5e80b1a
Rename Substrate Demo -> Substrate
gavofyork Sep 11, 2018
4aa94ec
Rename demo -> node
gavofyork Sep 11, 2018
eb5cc9d
Build wasm from last rename.
gavofyork Sep 11, 2018
4147286
Merge ed25519 into substrate-primitives
gavofyork Sep 11, 2018
0ac78f9
Minor tweak
gavofyork Sep 11, 2018
804ad47
Rename substrate -> core
gavofyork Sep 11, 2018
f637a58
Move substrate-runtime-support to core/runtime/support
gavofyork Sep 11, 2018
bcab227
Rename/move substrate-runtime-version
gavofyork Sep 11, 2018
54330e4
Move codec up a level
gavofyork Sep 11, 2018
6b02eb5
Rename substrate-codec -> parity-codec
gavofyork Sep 11, 2018
6412d02
Move environmental up a level
gavofyork Sep 11, 2018
750c7ee
Move pwasm-* up to top, ready for removal
gavofyork Sep 11, 2018
9a3cd9f
Remove requirement of s-r-support from s-r-primitives
gavofyork Sep 11, 2018
2f47756
Move core/runtime/primitives into core/runtime-primitives
gavofyork Sep 11, 2018
bc8265c
Remove s-r-support dep from s-r-version
gavofyork Sep 11, 2018
b25b789
Remove dep of s-r-support from bft
gavofyork Sep 11, 2018
0fb1e94
Remove dep of s-r-support from node/consensus
gavofyork Sep 11, 2018
c70f16a
Sever all other core deps from s-r-support
gavofyork Sep 12, 2018
24e37a9
Forgot the no_std directive
gavofyork Sep 12, 2018
5103a69
Rename non-SRML modules to sr-* to avoid match clashes
gavofyork Sep 12, 2018
0840e3f
Move runtime/* to srml/*
gavofyork Sep 12, 2018
2a919d1
Rename substrate-runtime-* -> srml-*
gavofyork Sep 12, 2018
f7195cf
Move srml to top-level
gavofyork Sep 12, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Merge ed25519 into substrate-primitives
  • Loading branch information
gavofyork committed Sep 11, 2018
commit 41472865b6f8a755f3c542b17be13319ce0b4cf4
33 changes: 6 additions & 27 deletions Cargo.lock

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

2 changes: 0 additions & 2 deletions doc/packages/substrate.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ include::../../substrate/client/README.adoc[]

include::../../substrate/codec/README.adoc[]

include::../../substrate/ed25519/README.adoc[]

include::../../substrate/environmental/README.adoc[]

include::../../substrate/executor/README.adoc[]
Expand Down
1 change: 0 additions & 1 deletion node/consensus/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ authors = ["Parity Technologies <[email protected]>"]
futures = "0.1.17"
parking_lot = "0.4"
tokio = "0.1.7"
ed25519 = { path = "../../substrate/ed25519" }
error-chain = "0.12"
log = "0.3"
exit-future = "0.1"
Expand Down
5 changes: 2 additions & 3 deletions node/consensus/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@

//! This service uses BFT consensus provided by the substrate.

extern crate ed25519;
extern crate parking_lot;
extern crate node_api;
extern crate node_transaction_pool as transaction_pool;
Expand Down Expand Up @@ -50,7 +49,7 @@ use std::time::{self, Duration, Instant};
use codec::{Decode, Encode};
use node_api::Api;
use node_primitives::{AccountId, Hash, Block, BlockId, BlockNumber, Header, Timestamp, SessionKey};
use primitives::AuthorityId;
use primitives::{AuthorityId, ed25519};
use transaction_pool::TransactionPool;
use tokio::runtime::TaskExecutor;
use tokio::timer::Delay;
Expand Down Expand Up @@ -427,7 +426,7 @@ impl<C> bft::Proposer<Block> for Proposer<C>
// alter the message based on whether we think the empty proposer was forced to skip the round.
// this is determined by checking if our local validator would have been forced to skip the round.
if !was_proposed {
let public = ::ed25519::Public::from_raw(primary_validator.0);
let public = ed25519::Public::from_raw(primary_validator.0);
info!(
"Potential Offline Validator: {} failed to propose during assigned slot: {}",
public,
Expand Down
1 change: 0 additions & 1 deletion node/executor/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ description = "Substrate node implementation in Rust."
[dependencies]
hex-literal = "0.1"
triehash = "0.2"
ed25519 = { path = "../../substrate/ed25519" }
substrate-codec = { path = "../../substrate/codec" }
substrate-runtime-io = { path = "../../substrate/runtime-io" }
substrate-runtime-support = { path = "../../substrate/runtime-support" }
Expand Down
4 changes: 1 addition & 3 deletions node/executor/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ extern crate substrate_state_machine as state_machine;
extern crate substrate_runtime_io as runtime_io;
extern crate substrate_primitives as primitives;
extern crate node_primitives;
extern crate ed25519;
extern crate triehash;

#[cfg(test)] extern crate substrate_keyring as keyring;
Expand All @@ -51,15 +50,14 @@ mod tests {
use keyring::Keyring;
use runtime_support::{Hashable, StorageValue, StorageMap};
use state_machine::{CodeExecutor, TestExternalities};
use primitives::{twox_128, Blake2Hasher};
use primitives::{twox_128, Blake2Hasher, ed25519::{Public, Pair}};
use node_primitives::{Hash, BlockNumber, AccountId};
use runtime_primitives::traits::Header as HeaderT;
use runtime_primitives::{ApplyOutcome, ApplyError, ApplyResult};
use {balances, staking, session, system, consensus, timestamp, treasury};
use system::{EventRecord, Phase};
use node_runtime::{Header, Block, UncheckedExtrinsic, CheckedExtrinsic, Call, Runtime, Balances,
BuildStorage, GenesisConfig, BalancesConfig, SessionConfig, StakingConfig, System, Event};
use ed25519::{Public, Pair};

const BLOATY_CODE: &[u8] = include_bytes!("../../runtime/wasm/target/wasm32-unknown-unknown/release/node_runtime.wasm");
const COMPACT_CODE: &[u8] = include_bytes!("../../runtime/wasm/target/wasm32-unknown-unknown/release/node_runtime.compact.wasm");
Expand Down
2 changes: 1 addition & 1 deletion node/network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ node-consensus = { path = "../consensus" }
node-primitives = { path = "../primitives" }
substrate-bft = { path = "../../substrate/bft" }
substrate-network = { path = "../../substrate/network" }
ed25519 = { path = "../../substrate/ed25519" }
substrate-primitives = { path = "../../substrate/primitives" }
futures = "0.1"
tokio = "0.1.7"
log = "0.4"
Expand Down
2 changes: 1 addition & 1 deletion node/network/src/consensus.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
//! each time consensus begins on a new chain head.

use bft;
use ed25519;
use substrate_primitives::ed25519;
use substrate_network::{self as net, generic_message as msg};
use substrate_network::consensus_gossip::ConsensusMessage;
use node_api::Api;
Expand Down
2 changes: 1 addition & 1 deletion node/network/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@

extern crate substrate_bft as bft;
extern crate substrate_network;
extern crate substrate_primitives;

extern crate node_api;
extern crate node_consensus;
extern crate node_primitives;

extern crate ed25519;
extern crate futures;
extern crate tokio;
extern crate rhododendron;
Expand Down
1 change: 0 additions & 1 deletion node/service/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ log = "0.3"
slog = "^2"
tokio = "0.1.7"
hex-literal = "0.1"
ed25519 = { path = "../../substrate/ed25519" }
node-api = { path = "../api" }
node-primitives = { path = "../primitives" }
node-runtime = { path = "../runtime" }
Expand Down
3 changes: 1 addition & 2 deletions node/service/src/chain_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@

//! Substrate chain configurations.

use ed25519;
use primitives::AuthorityId;
use primitives::{AuthorityId, ed25519};
use node_runtime::{GenesisConfig, ConsensusConfig, CouncilConfig, DemocracyConfig,
SessionConfig, StakingConfig, TimestampConfig, BalancesConfig, TreasuryConfig,
ContractConfig, Permill};
Expand Down
1 change: 0 additions & 1 deletion node/service/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@

//! Substrate service. Specialized wrapper over substrate service.

extern crate ed25519;
extern crate node_api;
extern crate node_primitives;
extern crate node_runtime;
Expand Down
1 change: 0 additions & 1 deletion node/transaction-pool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ substrate-keyring = { path = "../../substrate/keyring" }
substrate-extrinsic-pool = { path = "../../substrate/extrinsic-pool" }
substrate-primitives = { path = "../../substrate/primitives" }
substrate-runtime-primitives = { path = "../../substrate/runtime/primitives" }
ed25519 = { path = "../../substrate/ed25519" }
1 change: 0 additions & 1 deletion node/transaction-pool/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
// You should have received a copy of the GNU General Public License
// along with Substrate. If not, see <http://www.gnu.org/licenses/>.

extern crate ed25519;
extern crate substrate_client as client;
extern crate substrate_codec as codec;
extern crate substrate_extrinsic_pool as extrinsic_pool;
Expand Down
1 change: 0 additions & 1 deletion subkey/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ version = "0.1.0"
authors = ["Parity Technologies <[email protected]>"]

[dependencies]
ed25519 = { version = "*", path = "../substrate/ed25519" }
substrate-primitives = { version = "*", path = "../substrate/primitives" }
rand = "0.4"

Expand Down
4 changes: 1 addition & 3 deletions subkey/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
#![cfg_attr(feature = "bench", feature(test))]
#[cfg(feature = "bench")]
extern crate test;
extern crate ed25519;
extern crate substrate_primitives;
extern crate rand;

use rand::{OsRng, Rng};
use std::env::args;
use ed25519::Pair;
use substrate_primitives::hexdisplay::HexDisplay;
use substrate_primitives::{ed25519::Pair, hexdisplay::HexDisplay};
use std::cmp;

fn good_waypoint(done: u64) -> u64 {
Expand Down
1 change: 0 additions & 1 deletion substrate/bft/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ substrate-primitives = { path = "../primitives" }
substrate-runtime-support = { path = "../runtime-support" }
substrate-runtime-primitives = { path = "../runtime/primitives" }
substrate-runtime-version = { path = "../runtime/version" }
ed25519 = { path = "../ed25519" }
tokio = "0.1.7"
parking_lot = "0.4"
error-chain = "0.12"
Expand Down
3 changes: 2 additions & 1 deletion substrate/bft/src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

//! Error types in the BFT service.
use runtime_version::RuntimeVersion;
use primitives::ed25519;

error_chain! {
errors {
Expand Down Expand Up @@ -44,7 +45,7 @@ error_chain! {
}

/// Error checking signature
InvalidSignature(s: ::ed25519::Signature, a: ::primitives::AuthorityId) {
InvalidSignature(s: ed25519::Signature, a: ::primitives::AuthorityId) {
description("Message signature is invalid"),
display("Message signature {:?} by {:?} is invalid.", s, a),
}
Expand Down
5 changes: 2 additions & 3 deletions substrate/bft/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ extern crate substrate_primitives as primitives;
extern crate substrate_runtime_support as runtime_support;
extern crate substrate_runtime_primitives as runtime_primitives;
extern crate substrate_runtime_version as runtime_version;
extern crate ed25519;
extern crate tokio;
extern crate parking_lot;
extern crate rhododendron;
Expand All @@ -63,7 +62,7 @@ use ed25519::LocalizedSignature;
use runtime_primitives::generic::BlockId;
use runtime_primitives::traits::{Block, Header};
use runtime_primitives::bft::{Message as PrimitiveMessage, Action as PrimitiveAction, Justification as PrimitiveJustification};
use primitives::AuthorityId;
use primitives::{AuthorityId, ed25519};

use futures::{Async, Stream, Sink, Future, IntoFuture};
use futures::sync::oneshot;
Expand Down Expand Up @@ -316,7 +315,7 @@ impl<B: Block, P: Proposer<B>> rhododendron::Context for BftInstance<B, P>
use std::collections::HashSet;

let collect_pubkeys = |participants: HashSet<&Self::AuthorityId>| participants.into_iter()
.map(|p| ::ed25519::Public::from_raw(p.0))
.map(|p| ed25519::Public::from_raw(p.0))
.collect::<Vec<_>>();

let round_timeout = self.round_timeout_duration(next_round);
Expand Down
Loading