Casino

circle-info

For this exercise you may use substrate-node-template application.

Implement:

  • CasinoGossipEngine, a wrapper over new GossipEnginearrow-up-right instance that upon receiving Nth block starts gossiping an estimate of a timestamp in block N+Kth. N and K are parameters (might be hardcoded). We want to run the casino just once.

  • CasinoBlockImport that implements BlockImportarrow-up-right trait. Custom block importer should send all info to CasinoGssipEngine required for gossiping logic. Use crate sp_timestamparrow-up-right as a source of timestamps.

Relevant substrate parts:

Last updated

Was this helpful?