Leios: announced_eb_size is size of the txs rather than of their references #13
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
For this to be true ...
... the
announced_eb_sizefield needs to be the size of the txs, not the size of the tx references. Syncing nodes need to download all of the txs --- there's no reason they'd already have a subset of them. And they can reconstruct the tx references from the list of txs they receive.The MsgLeiosBlockOffer does claim a byte size for the list of references, and the peer can disconnect if the peer sends an EB body with a different size.
This resulting scheme is a natural match for the fact that the reason an EB body contains references to txs instead of the txs themselves is merely an optimization.