You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, we don't check message validity. To see if a message is valid, its estimate should be justified.
For some protocols, checking that an estimate is valid requires walking from some previous block (or set of outputs) in the past. For example, this is the last_finalized_block in TGF. However, this is not currently included in messages.
Proposed Implementation
Add last_finalized_block to blocks (and a similar field anywhere else this is needed), and have this be specified for a block when created.
This is an issue b/c messages are currently created by a single validator class, and we should not be specifying any last-finalized-anything for protocols that don't require a walk and are simply based off latest messages (e.g. binary).
One option might be having a sub-class of validators where message creation is specific to protocol type (or maybe protocol class...). E.g. there's one for binary, integer, order, and a different validator class for blockchain and concurrent rewrite.
The text was updated successfully, but these errors were encountered:
Another (better) solution is to reintroduce the Justification data structure. Here, we two options. We can have multiple Justification's - one that just stores latest_messages, and one that also has last_finalized_estimate, or we can have a single Justification that has both fields, but last_finalized_estimate defaults to None.
Also, the Justification data structure can have a function get_new_messages(self, latest_message) where it returns a dict that just contains the difference between the latest_messages and the justification. This will be useful for computing the minimal justification.
Issue
Currently, we don't check message validity. To see if a message is valid, its estimate should be justified.
For some protocols, checking that an estimate is valid requires walking from some previous block (or set of outputs) in the past. For example, this is the last_finalized_block in TGF. However, this is not currently included in messages.
Proposed Implementation
Add last_finalized_block to blocks (and a similar field anywhere else this is needed), and have this be specified for a block when created.
This is an issue b/c messages are currently created by a single validator class, and we should not be specifying any last-finalized-anything for protocols that don't require a walk and are simply based off latest messages (e.g. binary).
One option might be having a sub-class of validators where message creation is specific to protocol type (or maybe protocol class...). E.g. there's one for binary, integer, order, and a different validator class for blockchain and concurrent rewrite.
The text was updated successfully, but these errors were encountered: