-
Notifications
You must be signed in to change notification settings - Fork 290
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
At the moment events from ExtrinsicSuccess are encoded in the RuntimeEvents struct. The RuntimeEvents struct has no relation to the runtime types. It would be preferable to instead decode the events as the real event type obtained from the runtime. More concretely
pub struct ExtrinsicSuccess<T: System> {
// ...
events: srml_system::EventRecord<T::Event, T::Hash>
}
This would require us to add the associated Event type to the System trait.
With this implementation we could do away with the dynamic event parsing which suffers from a couple of issues.
- It needs to fetch the metadata
- It requires substantial manual decoding logic for events
- It requires registering type sizes for custom structs.
I’d be willing to give this a stab.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request