Merkle Mountain Range pallet improvements (#7891)

* Add stateless verification helper function.

* Split MMR primitives.

* Add RuntimeAPI

* RuntimeAPI with OpaqueLeaves

* Bump spec_version,.

* Move primitives back to frame.

* Fix OpaqueLeaf encoding.

* Add block number to frame_system implementation of LeafDataProvider.

* Relax leaf codec requirements and fix OpaqueLeaf

* Add root to debug line.

* Apply suggestions from code review

Co-authored-by: Hernando Castano <HCastano@users.noreply.github.com>

* Typo.

Co-authored-by: Hernando Castano <HCastano@users.noreply.github.com>
This commit is contained in:
Tomasz DrwięgaandHernando Castano authored and GitHub committed 2021-01-28 10:58:52 +00:00
1 parent fa23de2c03
commit 6c2dd28dfb
12 files changed
+373 -93

No files matched your search

@@ -16,12 +16,12 @@
// limitations under the License.
use crate::*;
use crate::primitives::{LeafDataProvider, Compact};
use codec::{Encode, Decode};
use frame_support::{
impl_outer_origin, parameter_types,
};
use pallet_mmr_primitives::{LeafDataProvider, Compact};
use sp_core::H256;
use sp_runtime::{
testing::Header,