Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple client and runtime support #415

Merged
merged 49 commits into from
May 19, 2021
Merged
Show file tree
Hide file tree
Changes from 36 commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
80d32fd
Wip inmense refactor - checkpoint
tgmichel May 14, 2021
e43232a
Wip continue - it checks with-moonbase-runtime
tgmichel May 14, 2021
ba81f0c
Checks with-moobeam-runtime
tgmichel May 14, 2021
2d2b806
Clear warnings
tgmichel May 15, 2021
f374023
Add copyrights
tgmichel May 15, 2021
e692c6f
Add moonriver, checks, wip warnings
tgmichel May 15, 2021
b4db26f
Moonriver warnings
tgmichel May 16, 2021
f1e722b
fmt
tgmichel May 16, 2021
342d5ca
Remove runtime features
tgmichel May 17, 2021
f58dca1
Remove `cfg-if`
tgmichel May 17, 2021
a9307dc
fmt
tgmichel May 17, 2021
2629f4c
fill in load_spec function
JoshOrndorff May 17, 2021
2c63bec
staking-test-spec
tgmichel May 18, 2021
1cca839
Dedup chain_spec::Extensions
tgmichel May 18, 2021
4aa1aa2
Runtime spec and impl names
tgmichel May 18, 2021
8a86432
Dedup spec account generator
tgmichel May 18, 2021
18044e8
Move AccountIndex, DigestItem to primitives
tgmichel May 18, 2021
cc6700e
core-primitives
tgmichel May 18, 2021
ae2845c
gate staking spec
tgmichel May 18, 2021
b7a183c
Missing copyright
tgmichel May 18, 2021
04144e8
labels
tgmichel May 18, 2021
8563584
remove unused `cli` feature
tgmichel May 18, 2021
f9fd116
transaction converter + clear todos
tgmichel May 18, 2021
6fd79dc
remove feature const
tgmichel May 18, 2021
e02f8a9
fmt
tgmichel May 18, 2021
3a85ed3
add supertrait comment
tgmichel May 18, 2021
f72e39e
fix checker
tgmichel May 18, 2021
9430140
Fix dev node
tgmichel May 18, 2021
ac59347
Fix tests dep
tgmichel May 18, 2021
83425ba
WIP moonriver tests
tgmichel May 18, 2021
3931dd5
Restore moonriver
tgmichel May 18, 2021
493bd66
Fix tests
tgmichel May 18, 2021
7ba77f3
Add moonshadow
tgmichel May 18, 2021
1eb74ef
add new network names to type bundle
joelamouche May 18, 2021
6cd67a8
Merge branch 'master' into tgm-runtimes
May 18, 2021
9c74bcd
Updates to include master branch
May 19, 2021
cc7543f
Fixes specs/scripts for new runtime
May 19, 2021
471954b
Restore author provider for dev
May 19, 2021
1122d62
Proper alice for dev
May 19, 2021
3e642e1
Formatting
May 19, 2021
3f28f54
update tests README
tgmichel May 19, 2021
4e8d56e
doc for `TransactionConverters`
tgmichel May 19, 2021
90f8490
dev service collator flag comment
tgmichel May 19, 2021
fcd172e
handle all `TransactionConvertes` variants
tgmichel May 19, 2021
78e10dd
fmt
tgmichel May 19, 2021
d7a58f5
Adds support for commit trigger NO-CACHE
May 19, 2021
130aa40
Better cache check on the CI workflow
May 19, 2021
c745af0
Changing ci to use SCCACHE_RECACHE
May 19, 2021
b4e6817
Adds support in ci for NO-CACHE
May 19, 2021
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
398 changes: 333 additions & 65 deletions Cargo.lock

Large diffs are not rendered by default.

7 changes: 6 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
[workspace]
members = [
'runtime',
'runtime/moonbeam',
'runtime/moonriver',
'runtime/moonshadow',
'runtime/moonbase',
'node',
'node/cli',
'node/service',
]

[profile.release]
Expand Down
21 changes: 21 additions & 0 deletions core-primitives/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
[package]
authors = ['PureStake']
edition = '2018'
homepage = 'https://moonbeam.network'
license = 'GPL-3.0-only'
name = 'moonbeam-core-primitives'
repository = 'https://github.com/PureStake/moonbeam/'
version = '0.1.1'

[dependencies]
sp-core = { git = "https://github.com/paritytech/substrate", branch = "rococo-v1", default-features = false }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "rococo-v1", default-features = false }
account = { path = "../primitives/account", default-features = false }

[features]
default = [ "std" ]
std = [
"sp-core/std",
"sp-runtime/std",
"account/std",
]
49 changes: 49 additions & 0 deletions core-primitives/src/lib.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
// Copyright 2019-2021 PureStake Inc.
// This file is part of Moonbeam.

// Moonbeam is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.

// Moonbeam is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License
// along with Moonbeam. If not, see <http://www.gnu.org/licenses/>.

#![cfg_attr(not(feature = "std"), no_std)]

use account::EthereumSignature;
use sp_runtime::traits::BlakeTwo256;
pub use sp_runtime::OpaqueExtrinsic as UncheckedExtrinsic;
use sp_runtime::{
generic,
traits::{IdentifyAccount, Verify},
};

pub type Block = generic::Block<Header, UncheckedExtrinsic>;
/// Alias to 512-bit hash when used in the context of a transaction signature on the chain.
pub type Signature = EthereumSignature;
/// Some way of identifying an account on the chain. We intentionally make it equivalent
/// to the public key of our transaction signing scheme.
pub type AccountId = <<Signature as Verify>::Signer as IdentifyAccount>::AccountId;
/// Balance of an account.
pub type Balance = u128;
/// An index to a block.
pub type BlockNumber = u32;
/// A hash of some data used by the chain.
pub type Hash = sp_core::H256;
/// Block header type as expected by this runtime.
pub type Header = generic::Header<BlockNumber, BlakeTwo256>;
/// Index of a transaction in the chain.
pub type Index = u32;
/// The address format for describing accounts.
pub type Address = AccountId;
/// The type for looking up accounts. We don't expect more than 4 billion of them, but you
/// never know...
pub type AccountIndex = u32;
/// Digest item type.
pub type DigestItem = generic::DigestItem<Hash>;
3 changes: 3 additions & 0 deletions moonbeam-types-bundle/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -454,5 +454,8 @@ export const typesBundle = {
moonbeamDefinitions,
"moonbeam-standalone": moonbeamDefinitions,
"node-moonbeam": moonbeamDefinitions,
moonbase: moonbeamDefinitions,
moonriver: moonbeamDefinitions,
moonshadow: moonbeamDefinitions,
},
} as OverrideBundleType;
Loading