'Adding Pallet-staking to frontier unresolved import `sc_rpc::Metadata`
I have used frontier-node-template from parity tech repo to setup a private evm supported network. The network is running fine, authoring blocks and connecting with Metamask wallet for all functions. The next goal is to add pallet-staking to the same.
To achieve so, I am adding pallet-staking into Cargo.toml using paritytech/substrate using the following line.
pallet-staking = { git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
Post adding this line it compiles upto a good bit but then throws errors in client/rpc module which has use sc_rpc:Metadata but is showing unresolved type Metadata. I can also see that it is available as struct in sc_rpc docs https://docs.rs/sc-rpc/latest/sc_rpc/struct.Metadata.html
I am using version 4.0.0-dev from https://github.com/paritytech/substrate master branch.
xxxx@ip-10-20-14-8:~/xxxx/frontier$ cargo check
Checking fc-rpc v2.0.0-dev (/home/xxxx/xxxx/frontier/client/rpc)
error[E0432]: unresolved import `sc_rpc::Metadata`
--> client/rpc/src/eth_pubsub.rs:38:5
|
38 | use sc_rpc::Metadata;
| ^^^^^^^^^^^^^^^^ no `Metadata` in the root
For more information about this error, try `rustc --explain E0432`.
error: could not compile `fc-rpc` due to previous error
Please help on this error as to me it seems a dependency compatibility issue. Also, if any one has any reference to point to where substrate staking pallet with EVM pallet is running fine.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|