-
Notifications
You must be signed in to change notification settings - Fork 2.6k
babe: introduce a request-answering mechanic #7833
Conversation
I'm not totally sure I need this, given #7789, but maybe it's useful? Cheaper than going to runtime for sure. And breaks our reliance on state pruning, but in my use-case we also do other state requests, so this isn't the only place. |
client/consensus/babe/src/lib.rs
Outdated
), | ||
|
||
#[doc(hidden)] | ||
__Nonexhaustive, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TIL
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Me too :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we might be able to use this for BABE's RPC module, rather than exposing SharedEpochChanges
.
) | ||
.map_err(|e| Error::<B>::ForkTree(Box::new(e)))? | ||
.ok_or_else(|| Error::<B>::FetchEpoch(parent_hash))?; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
client/consensus/babe/src/lib.rs
Outdated
), | ||
|
||
#[doc(hidden)] | ||
__Nonexhaustive, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TIL
any progress on this? |
@gnunicorn pretty sure it's ready |
* babe: introduce a request-answering mechanic * gromble * send method
* babe: introduce a request-answering mechanic * gromble * send method
For now, the only request type it answers is requesting the epoch that a child block will have.