Mise à jour de GitLab prévue ce samedi 23 octobre 2021 à partir de 9h00 CET

Commit 04fab32a authored by Éloïs's avatar Éloïs
Browse files

deps: upgrade substrate to monthly-2021-08

parent 57241fb4
This diff is collapsed.
......@@ -3,8 +3,7 @@ runtime-benchmarks = ['gdev-runtime/runtime-benchmarks']
[build-dependencies.substrate-build-script-utils]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[package]
authors = ['Axiom-Team Developers <https://axiom-team.fr>']
......@@ -34,190 +33,158 @@ structopt = '0.3.8'
[dependencies.frame-benchmarking]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.1.0'
tag = 'monthly-2021-08'
[dependencies.frame-benchmarking-cli]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.pallet-grandpa]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.pallet-transaction-payment-rpc]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.pallet-transaction-payment-rpc-runtime-api]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sc-basic-authorship]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-chain-spec]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sc-cli]
features = ['wasmtime']
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-client-api]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sc-consensus]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-consensus-aura]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-consensus-manual-seal]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-executor]
features = ['wasmtime']
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-finality-grandpa]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-keystore]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sc-rpc]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sc-rpc-api]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-service]
features = ['wasmtime']
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sc-telemetry]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sc-transaction-pool]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sc-transaction-pool-api]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-08'
[dependencies.serde_json]
version = '1.0.64'
[dependencies.sp-api]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-block-builder]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-blockchain]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-consensus]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sp-consensus-aura]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '0.9.0'
tag = 'monthly-2021-08'
[dependencies.sp-core]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-finality-grandpa]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-offchain]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-inherents]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-runtime]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-session]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-storage]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-timestamp]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-transaction-pool]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.sp-trie]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[dependencies.substrate-frame-rpc-system]
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
version = '3.0.0'
tag = 'monthly-2021-08'
[[bin]]
name = 'lc-core'
......@@ -26,10 +26,10 @@ pub use sc_rpc_api::DenyUnsafe;
use common_runtime::Block;
use common_runtime::{AccountId, Balance, Index};
use sc_consensus_manual_seal::rpc::{ManualSeal, ManualSealApi};
use sc_transaction_pool_api::TransactionPool;
use sp_api::ProvideRuntimeApi;
use sp_block_builder::BlockBuilder;
use sp_blockchain::{Error as BlockChainError, HeaderBackend, HeaderMetadata};
use sp_transaction_pool::TransactionPool;
use std::sync::Arc;
/// Full client dependencies.
......
......@@ -95,7 +95,7 @@ pub fn new_chain_ops(
(
Arc<Client>,
Arc<FullBackend>,
sp_consensus::import_queue::BasicQueue<Block, sp_trie::PrefixedMemoryDB<BlakeTwo256>>,
sc_consensus::BasicQueue<Block, sp_trie::PrefixedMemoryDB<BlakeTwo256>>,
TaskManager,
),
ServiceError,
......@@ -144,7 +144,7 @@ pub fn new_partial<RuntimeApi, Executor>(
FullClient<RuntimeApi, Executor>,
FullBackend,
FullSelectChain,
sp_consensus::DefaultImportQueue<Block, FullClient<RuntimeApi, Executor>>,
sc_consensus::DefaultImportQueue<Block, FullClient<RuntimeApi, Executor>>,
sc_transaction_pool::FullPool<Block, FullClient<RuntimeApi, Executor>>,
(
sc_finality_grandpa::GrandpaBlockImport<
......@@ -386,7 +386,7 @@ where
block_import,
env: proposer_factory,
client: client.clone(),
pool: transaction_pool.pool().clone(),
pool: transaction_pool.clone(),
commands_stream,
select_chain,
consensus_data_provider: None,
......
......@@ -199,6 +199,23 @@ impl sc_client_api::StorageProvider<Block, super::FullBackend> for Client {
}
}
fn child_storage_keys_iter<'a>(
&self,
id: &BlockId<Block>,
child_info: ChildInfo,
prefix: Option<&'a StorageKey>,
start_key: Option<&StorageKey>,
) -> sp_blockchain::Result<
KeyIterator<'a, <super::FullBackend as sc_client_api::Backend<Block>>::State, Block>,
> {
match self {
Self::GTest(client) => {
client.child_storage_keys_iter(id, child_info, prefix, start_key)
}
Self::GDev(client) => client.child_storage_keys_iter(id, child_info, prefix, start_key),
}
}
fn child_storage_hash(
&self,
id: &BlockId<Block>,
......
......@@ -6,7 +6,7 @@ homepage = 'https://substrate.dev'
license = 'AGPL-3.0'
name = 'pallet-certification'
readme = 'README.md'
repository = 'https://git.duniter.org/nodes/rust/lc-core-substrate'
repository = 'https://git.duniter.org/nodes/rust/lc-core-substrate'
version = '3.0.0'
[features]
......@@ -28,23 +28,23 @@ try-runtime = ['frame-support/try-runtime']
default-features = false
features = ['derive']
package = 'parity-scale-codec'
version = '2.1.0'
version = '2.2.0'
[dependencies.frame-benchmarking]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
optional = true
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.frame-support]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.frame-system]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.serde]
version = "1.0.101"
......@@ -54,17 +54,17 @@ features = ["derive"]
[dependencies.sp-core]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.sp-runtime]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.sp-std]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
### DOC ###
......@@ -81,4 +81,4 @@ version = '1.0.2'
[dev-dependencies.sp-io]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
......@@ -17,7 +17,7 @@
use crate::{self as pallet_certification};
use frame_support::{
parameter_types,
traits::{OnFinalize, OnInitialize},
traits::{AllowAll, OnFinalize, OnInitialize},
};
use frame_system as system;
use sp_core::H256;
......@@ -51,7 +51,7 @@ parameter_types! {
}
impl system::Config for Test {
type BaseCallFilter = ();
type BaseCallFilter = AllowAll;
type BlockWeights = ();
type BlockLength = ();
type DbWeight = ();
......
......@@ -28,23 +28,23 @@ try-runtime = ['frame-support/try-runtime']
default-features = false
features = ['derive']
package = 'parity-scale-codec'
version = '2.1.0'
version = '2.2.0'
[dependencies.frame-benchmarking]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
optional = true
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.frame-support]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.frame-system]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.serde]
version = "1.0.101"
......@@ -54,17 +54,17 @@ features = ["derive"]
[dependencies.sp-core]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.sp-runtime]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
[dependencies.sp-std]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
### DOC ###
......@@ -78,4 +78,4 @@ version = '1.0.119'
[dev-dependencies.sp-io]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
tag = 'monthly-2021-07'
tag = 'monthly-2021-08'
......@@ -19,7 +19,7 @@ use crate::{self as pallet_identity};
use frame_support::{
codec::{Decode, Encode},
parameter_types,
traits::{OnFinalize, OnInitialize},
traits::{AllowAll, OnFinalize, OnInitialize},
RuntimeDebug,
};
use frame_system as system;
......@@ -74,7 +74,7 @@ parameter_types! {
}
impl system::Config for Test {
type BaseCallFilter = ();
type BaseCallFilter = AllowAll;
type BlockWeights = ();
type BlockLength = ();
type DbWeight = ();
......
[package]
authors = ['Substrate DevHub <https://github.com/substrate-developer-hub>', 'tuxmain <tuxmain@zettascript.org>']
description = 'FRAME pallet template for defining custom runtime logic.'
edition = '2018'
homepage = 'https://substrate.dev'
license = 'AGPL v3'
name = 'pallet-template'
readme = 'README.md'
repository = 'https://forge.tedomum.net/axiom-team/substrate-libre-currency'
version = '3.0.0'
[package.metadata.docs.rs]
targets = ['x86_64-unknown-linux-gnu']
[dependencies]
# external dependencies
codec = {default-features = false, features = ['derive'], package = 'parity-scale-codec', version = '2.0.0'}
# Substrate dependencies
frame-benchmarking = {default-features = false, optional = true, version = '3.1.0', git = 'https://github.com/paritytech/substrate.git', tag = 'monthly-2021-05'}
frame-support = {default-features = false, version = '3.0.0', git = 'https://github.com/paritytech/substrate.git', tag = 'monthly-2021-05'}
frame-system = {default-features = false, version = '3.0.0', git = 'https://github.com/paritytech/substrate.git', tag = 'monthly-2021-05'}
[dev-dependencies]
serde = '1.0.119'
sp-core = {default-features = false, version = '3.0.0', git = 'https://github.com/paritytech/substrate.git', tag = 'monthly-2021-05'}
sp-io = {default-features = false, version = '3.0.0', git = 'https://github.com/paritytech/substrate.git', tag = 'monthly-2021-05'}
sp-runtime = {default-features = false, version = '3.0.0', git = 'https://github.com/paritytech/substrate.git', tag = 'monthly-2021-05'}
[features]
default = ['std']
runtime-benchmarks = ['frame-benchmarking']
std = [
'codec/std',
'frame-support/std',
'frame-system/std',
'frame-benchmarking/std',
]
try-runtime = ['frame-support/try-runtime']
License: GNU AGPL v3
\ No newline at end of file
// Copyright 2021 Axiom-Team
//
// This file is part of Substrate-Libre-Currency.
//
// Substrate-Libre-Currency is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as published by
// the Free Software Foundation, version 3 of the License.
//
// Substrate-Libre-Currency 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 Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with Substrate-Libre-Currency. If not, see <https://www.gnu.org/licenses/>.
//! Benchmarking setup for pallet-template
use super::*;
#[allow(unused)]
use crate::Pallet as Template;
use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller};
use frame_system::RawOrigin;
benchmarks! {
do_something {
let s in 0 .. 100;
let caller: T::AccountId = whitelisted_caller();
}: _(RawOrigin::Signed(caller), s)
verify {
assert_eq!(Something::<T>::get(), Some(s));
}
}
impl_benchmark_test_suite!(Template, crate::mock::new_test_ext(), crate::mock::Test,);
// Copyright 2021 Axiom-Team
//
// This file is part of Substrate-Libre-Currency.
//
// Substrate-Libre-Currency is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as published by
// the Free Software Foundation, version 3 of the License.
//
// Substrate-Libre-Currency 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 Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with Substrate-Libre-Currency. If not, see <https://www.gnu.org/licenses/>.
#![cfg_attr(not(feature = "std"), no_std)]
/// Edit this file to define custom logic or remove it if it is not needed.
/// Learn more about FRAME and the core library of Substrate FRAME pallets:
/// <https://substrate.dev/docs/en/knowledgebase/runtime/frame>
pub use pallet::*;
#[cfg(test)]
mod mock;
#[cfg(test)]
mod tests;
#[cfg(feature = "runtime-benchmarks")]
mod benchmarking;
#[frame_support::pallet]
pub mod pallet {
use frame_support::{dispatch::DispatchResult, pallet_prelude::*};
use frame_system::pallet_prelude::*;
/// Configure the pallet by specifying the parameters and types on which it depends.
#[pallet::config]
pub trait Config: frame_system::Config {
/// Because this pallet emits events, it depends on the runtime's definition of an event.
type Event: From<Event<Self>> + IsType<<Self as frame_system::Config>::Event>;
}
#[pallet::pallet]
#[pallet::generate_store(pub(super) trait Store)]
pub struct Pallet<T>(_);
// The pallet's runtime storage items.
// https://substrate.dev/docs/en/knowledgebase/runtime/storage
#[pallet::storage]
#[pallet::getter(fn something)]
// Learn more about declaring storage items:
// https://substrate.dev/docs/en/knowledgebase/runtime/storage#declaring-storage-items
pub type Something<T> = StorageValue<_, u32>;
// Pallets use events to inform users when important changes are made.
// https://substrate.dev/docs/en/knowledgebase/runtime/events
#[pallet::event]
#[pallet::metadata(T::AccountId = "AccountId")]
#[pallet::generate_deposit(pub(super) fn deposit_event)]
pub enum Event<T: Config> {
/// Event documentation should end with an array that provides descriptive names for event
/// parameters. [something, who]
SomethingStored(u32, T::AccountId),
}
// Errors inform users that something went wrong.
#[pallet::error]
pub enum Error<T> {
/// Error names should be descriptive.
NoneValue,
/// Errors should have helpful documentation associated with them.
StorageOverflow,
}
#[pallet::hooks]
impl<T: Config> Hooks<BlockNumberFor<T>> for Pallet<T> {}
// Dispatchable functions allows users to interact with the pallet and invoke state changes.
// These functions materialize as "extrinsics", which are often compared to transactions.
// Dispatchable functions must be annotated with a weight and must return a DispatchResult.
#[pallet::call]
impl<T: Config> Pallet<T> {
/// An example dispatchable that takes a singles value as a parameter, writes the value to