Deep dive into FRAME V2 pallet macros | Substrate Seminar
In this seminar, Parity core developer Guillaume goes over the work he has done to improve the FRAME pallet developer experience with procedural macros which allows developers to focus on writing correct Rust code. FRAME is an opinionated framework for writing Substrate runtimes in Rust, commonly used to build blockchain logic for Polkadot-like blockchains.
#rustlang #rustmacros #substrate #blockchaindevelopment
⎼⎼⎼⎼⎼⎼⎼
0:00 - Intro
4:03 - About the presenter
10:32 - The FRAME V2 pallet declaration
11:45 - Useful links
12:10 - What does a FRAME pallet declare
15:29 - How is a FRAME pallet used (what it aggregates and implements)
22:23 - Comparing V1 to V2
25:00 - Recap on the differences between declarative and procedural Rust macros
28:50 - Q: Is the wrapping mod always necessary?
33:46 - Adding the procedural macro on a module
34:44 - Pallet configuration trait and placeholder
48:07 - Pallet hooks
49:48 - Pallet dispatchables
52:00 - Pallet errors and events
56:52 - Pallet storage
1:02:10 - Storage prefixes
1:04:30 - Pallet genesis configuration
1:05:22 - Pallet inherents and validate_unsigned
1:06:30 - Why storage prefix comes from pallet name in construct_runtime in FRAME V2
1:09:34 - Error message improvements
1:15:35 - Pallet V2 future improvements
1:17:00 - Questions
1:20:00 - Demo: how to migrate a FRAME V1 pallet to V2
⎼⎼⎼⎼⎼⎼⎼
→ For more videos on blockchain development and building Web 3.0,
subscribe to the channel: https://www.youtube.com/channel/UCSs5vZi0U7qHLkUjF3QnaWg?sub_confirmation=1
→ Website: https://www.parity.io/
→ To stay informed about Parity updates and events,
subscribe to the newsletter: https://www.parity.io/newsletter/
→ Follow us on Twitter (@ParityTech): https://twitter.com/ParityTech
→ Check our code on GitHub: https://github.com/paritytech/