【发布时间】:2021-02-07 21:02:08
【问题描述】:
我需要帮助
我在创建第一个底层链时有两个主要错误(参见https://substrate.dev/docs/en/tutorials/create-your-first-substrate-chain/setup)
安装前端模板时出错
~/Bureau/ETH-BIT/substrate/substrate-front-end-template$ ls LICENSE package.json public README.md src yarn.lock pclf@ubuntu:~/Bureau/ETH-BIT/substrate/substrate-front-end-template$ 纱线安装 错误:[Errno 2] 没有这样的文件或目录:'安装'
编译 Substrate 时出错
cargo build --release 错误:无法为
node-template-runtime v2.0.0 (/home/pclf/Bureau/ETH-BIT/substrate/substrate-node-template/runtime)运行自定义构建命令原因:进程没有成功退出:
/home/pclf/Bureau/ETH-BIT/substrate/substrate-node-template/target/release/build/node-template-runtime-663c8dc25926c960/build-script-build(退出代码:1)---stdout 执行构建命令:“rustup”“run” “夜间”“货物”“rustc”“--target=wasm32-unknown-unknown” "--manifest-path=/home/pclf/Bureau/ETH-BIT/substrate/substrate-node-template/target/release/wbuild/node-template-runtime/Cargo.toml" "--color=always" " --发布”--- 标准错误 编译 wasm-build-runner-impl v1.0.0 (/home/pclf/Bureau/ETH-BIT/substrate/substrate-node-template/target/release/wbuild-runner/node-template-runtime4021631938540302808) 在 7.49 秒内完成发布 [优化] 目标 运行
/home/pclf/Bureau/ETH-BIT/substrate/substrate-node-template/target/release/wbuild-runner/node-template-runtime4021631938540302808/target/x86_64-unknown-linux-gnu/release/wasm-build-runner-impl编译 sp-arithmetic v2.0.0 编译 sp-io v2.0.0 编译 sp-inherents v2.0.0 编译框架元数据 v12.0.0 编译 sp-finality-tracker v2.0.0 错误[E0282]:需要类型注释 --> /home/pclf/.cargo/registry/src/github.com-1ecc6299db9ec823/sp-arithmetic-2.0.0/src/fixed_point.rs:541:9 |第541章让准确度 = P::ACCURACY.aturated_into(); | ^^^^^^^^ 考虑给accuracy一个类型... 1595 | /implement_fixed!( 1596 | | FixedI64,
第1597章| test_fixed_i64, 1598 | | i64, ... | 1601 | | "定点 64 位有符号,范围 = [-9223372036.854775808, 9223372036.854775807]", 1602 | | ); | |__- 在这个宏调用中 | = 注意:此错误源自宏(在 Nightly 构建中,使用 -Z 宏回溯运行以获取更多信息)错误[E0282]:需要类型注释 --> /home/pclf/.cargo/registry/src/github.com-1ecc6299db9ec823/sp-arithmetic-2.0.0/src/fixed_point.rs:541:9 |第541章让准确度 = P::ACCURACY.aturated_into(); | ^^^^^^^^ 考虑给
accuracy一个类型... 1604 | /implement_fixed!( 1605 | | FixedI128,
1606 | | test_fixed_i128, 1607 | | i128, ... | 1611 | | [-170141183460469231731.687303715884105728, 170141183460469231731.687303715884105727]_", 1612 | | ); | |__- 在这个宏调用中 | = 注意:此错误源自宏(在 Nightly 构建中,使用 -Z 宏回溯运行以获取更多信息)错误[E0282]:需要类型注释 --> /home/pclf/.cargo/registry/src/github.com-1ecc6299db9ec823/sp-arithmetic-2.0.0/src/fixed_point.rs:541:9 |第541章让准确度 = P::ACCURACY.aturated_into(); | ^^^^^^^^ 考虑给
accuracy一个类型... 1614 | /implement_fixed!( 1615 | | FixedU128,
1616 | | test_fixed_u128, 1617 | | u128, ... | 1621 | | [0.000000000000000000, 340282366920938463463.374607431768211455]_", 1622 | | ); | |__- 在这个宏调用中 | = 注意:此错误源自宏(在 Nightly 构建中,使用 -Z 宏回溯运行以获取更多信息)错误:由于之前的 3 个错误而中止
有关此错误的更多信息,请尝试
rustc --explain E0282。 错误:无法编译sp-arithmetic错误:构建失败
【问题讨论】:
标签: yarnpkg rust-cargo substrate polkadot