paritytech / polkadot-sdk

The Parity Polkadot Blockchain SDK
https://polkadot.network/
1.8k stars 652 forks source link

Ensure weights are correct #5792

Open eskimor opened 1 week ago

eskimor commented 1 week ago

Implement a (generic) fuzzy test to fill up a blocks with random transactions and parameters. Then verify that the resulting block is valid in terms of actual execution time and size.

This test should be generic or easily adjustable and part of any templates. Both system chains and community chains should run this test by default in CI.

kianenigma commented 1 week ago

This, plus https://github.com/paritytech/polkadot-sdk/issues/152 would make great tools to ensure it is REALLY HARD to mess your parachains' weights.