substrate-docs icon indicating copy to clipboard operation
substrate-docs copied to clipboard

Fix the outdate syntax of pallet-randomness-collective-flip crate (which prevent import pallet to runtime)

Open t41n4 opened this issue 1 year ago • 0 comments

Is there an existing issue?

  • [X] I have searched the existing issues

Experiencing problems? Have you tried our Stack Exchange first?

  • [X] This is not a support question.

Content request

Issue Report: Error encountered while following Collectibles Workshop tutorial

Environment

  • Substrate version: 4.0.0-dev
  • Rust version: 1.64.0
  • OS: Linux

Steps to Reproduce

  1. Follow the Collectibles Workshop tutorial up to Chapter 6.
  2. In Chapter 7, add the pallet-randomness-collective-flip crate to the project's Cargo.toml file.
  3. Compile the project.

Expected Behavior

The project should compile successfully.

Actual Behavior

The following errors are encountered:

Error 1:

image

Error 2:

image

Attempted Solutions

  • Added the pallet-randomness-collective-flip crate to the project's Cargo.toml file.
  • Implemented the pallet-randomness-collective-flip pallet from source.
  • Replaced all instances of T::BlockNumber with BlockNumberFor<T>.
  • Added impl pallet_randomness_collective_flip::Config for Runtime {} to the project's runtime/src/lib.rs file.

image

Additional Information

  • The issue appears to be related to the pallet-randomness-collective-flip crate.
  • The tutorial is outdated and does not reflect the latest changes to the Substrate framework.

References

Request

Please investigate this issue and update the tutorial to reflect the latest changes to the Substrate framework.

Additional Notes

  • The issue has been reported on GitHub: [đã xoá URL không hợp lệ]
  • The tutorial is being updated to address this issue.

Conclusion

The pallet-randomness-collective-flip crate is causing errors when following the Collectibles Workshop tutorial. The tutorial is outdated and needs to be updated to reflect the latest changes to the Substrate framework.

Are you willing to help with this request?

Yes!

t41n4 avatar Mar 03 '24 10:03 t41n4