Closed Inux131 closed 2 years ago
I think what you are doing is replacing the entire construct_runtime
with
/ {
327 | | /* --snip-- */
328 | | Balances: pallet_balances,
329 | |
330 | | /*** Add This Line ***/
331 | | Nicks: pallet_nicks,
332 | | }
You are just meant to add this line to it
Nicks: pallet_nicks,
So it should look like this:
construct_runtime!(
pub enum Runtime where
Block = Block,
NodeBlock = opaque::Block,
UncheckedExtrinsic = UncheckedExtrinsic
{
System: frame_system,
RandomnessCollectiveFlip: pallet_randomness_collective_flip,
Timestamp: pallet_timestamp,
Aura: pallet_aura,
Grandpa: pallet_grandpa,
Balances: pallet_balances,
Nick: pallet_nicks, <== Add this to it.
TransactionPayment: pallet_transaction_payment,
Sudo: pallet_sudo,
// Include the custom logic from the pallet-template in the runtime.
TemplateModule: pallet_template,
}
);
Hope this helps
Hey,
thank you very much, it helped. At first it showed another error. I closed the Terminal and reopened. Then the next Error was:
`~/substrate-node-template$ cargo check -p node-template-runtime Compiling node-template-runtime v4.0.0-dev (/home/robert/substrate-node-template/runtime) warning: unused doc comment --> runtime/src/lib.rs:251:1 | 251 | /// Add this code block to your template for Nicks: | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ rustdoc does not generate documentation for macro invocations |
---|
= note: `#[warn(unused_doc_comments)]` on by default
= help: to document an item produced by a macro, the macro must produce the documentation as part of its expansion
warning: node-template-runtime
(lib) generated 1 warning
Finished dev [unoptimized + debuginfo] target(s) in 9.47s
`
I changed the /// to // and now everything works fine.
Can you tell me why /// is a problem in rust?
I assume, that /// and // are comments and can be put at will.
Thanks so far for your help!
Thanks @Genysys for providing support.
Hi,
added dependencies & features in the Cargo.toml then: $ cargo build --release
how can I fix this?
A lot of errors are occurring:
and so on...