substrate相关内容
我希望查询所有Polkadot帐户,以便我可以按余额对它们进行排序。我应该使用哪个Java脚本API?我不仅仅是在寻找有身份的账户。我正在寻找所有帐户,非常感谢 推荐答案 使用Polkadot JS:https://polkadot.js.org/docs/ 要查询所有账户,您需要查看system.account 的所有条目 let users = substrate.que
..
我在测试底层离链工人,我想做的是接收当前的块数,然后做一些计算,就像下面的代码if (get_block / 10 == 0),我得到了一些错误。如何将块编号转换为整数类型? 我的代码 use frame_support::{decl_storage, decl_module, dispatch::DispatchResult, debug}; use frame_system::{
..
我有一个要求,在那里我被传入了一些字节,并且我需要在Tablet 2.0中从它创建一个Account ID。 有没有办法在运行时(框架)中在AccountId32和::AccountId之间进行转换?或从字节创建::AccountId的实例? 谢谢 推荐答案 给定原始字节
..
当我想要使用基于基片的链中内置的方法和自定义类型时,我得到以下错误: 2020-04-13 21:03:01 RPC-CORE: submitAndWatchExtrinsic(extrinsic: Extrinsic): ExtrinsicStatus:: 1002: Verification Error: Execution(ApiError("Could not convert par
..
错误[E0282]:需要类型注释-->/Users/apple/.cargo/registry/src/github.com-1ecc6299db9ec823/sp-arithmetic-2.0.0/src/fixed_point.rs:541:9|第541话让精度 = P::ACCURACY.saturated_into();|^^^^^^^^ 考虑给 accuracy 一个类型 解决方案
..
Substrate使用许多宏来简化编写运行时模块的过程: construct_runtime! decl_module! decl_storage! decl_event! 等... 但是,很难理解这些宏的实际作用以及最终代码的外观.我该如何深入研究这些宏和扩展? 解决方案 对我来说,最舒适的解决方案是使用 cargo expand https://github.
..
使用Substrate区块链框架,如何在Substrate特定类型和Rust原语类型之间进行转换,反之亦然? 例如: 将时间(T::Moment)转换为u64 将u64转换为T::Balance 等... 解决方案 获取最新的Substrate master 基板已已删除As ,而赞成使用From/. 假定所有类型至少为u32. 根据特征SimpleArit
..
在使用Bonds库(oo7)的Substrate-UI中,它表明"Alice"在开发链上的资金为零.我还注意到有些帐户被标记为ed25519,另一些帐户被标记为sr25519. 我该如何修复并获得正确的爱丽丝的访问权限? 解决方案 最近,基质更改了从ed25519到sr25519的帐户和交易签名的默认密码. 根据所使用的软件组合(节点,UI等)以及所存储的本地存储项(例如UI中
..
在基板中实现运行时模块时,应提供以下存储空间 decl_storage! { trait Store for Module as CatAuction { Kitties get(kitties): map T::Hash => Kitty; KittyOwner get(owner_of): map T::H
..
按照将模块添加到您的运行时,我正在尝试实现 Parity Substrate paint-evm特性用于 Dothereum Runtime . EVM模块特征的定义如下: pub trait Trait: Trait + Trait { type FeeCalculator: FeeCalculator; type ConvertAccountId: ConvertAcc
..