OpenZeppelin / polkadot-runtime-wrappers

GNU General Public License v3.0
0 stars 1 forks source link

Better dependency errors by including all required deps in this crate #8

Open 4meta5 opened 2 weeks ago

4meta5 commented 2 weeks ago

This is macro hygiene related to #4 ; the error message when a user does not include a dependency required in the macros can be improved through this issue.

The solution is to include all required dependencies in this crate. So instead of

// inside macro
construct_runtime!

it is better to include frame_support as a dependency in this crate's Cargo.toml and call it like this:

// inside macro
::frame_support::construct_runtime!

This is done in #1 for frame_support::construct_runtime and sp_api::iml_runtime_api macros but is not done for all the other pallet dependencies required. This issue exists to add all of those.