collation-generation: Support compressed PoVs directly (#4825)

This adds support for returning a compressed PoV directly to the
collation generation. This is mainly to not requiring to compress a PoV
twice.
This commit is contained in:
Bastian Köcher
2022-02-07 20:14:08 +01:00
committed by GitHub
parent 59cddb9f23
commit bb69c82cc5
4 changed files with 50 additions and 21 deletions
@@ -309,9 +309,7 @@ async fn handle_new_activations<Context: SubsystemContext>(
// Apply compression to the block data.
let pov = {
let pov = polkadot_node_primitives::maybe_compress_pov(
collation.proof_of_validity,
);
let pov = collation.proof_of_validity.into_compressed();
let encoded_size = pov.encoded_size();
// As long as `POV_BOMB_LIMIT` is at least `max_pov_size`, this ensures