Module blockchain

Source
Expand description

Provides the core runtime logic for managing blockchain actors (authors/validators) across their full lifecycle.

The module acts as a bridge layer between generic trait abstractions and pallet-specific storage, timing, and role-management systems.

ยงDesign Overview

  • Session-driven lifecycle: All operations (affidavits, elections, points, rewards, penalties) are scoped to sessions and aligned with deterministic session timing.

  • Time-gated execution: Affidavit submission and election processing are strictly bounded by windows derived from session start and configurable percentages.

  • Separation of concerns:

  • Deterministic and auditable: All operations avoid side effects and remain reproducible across nodes.

  • Deferred execution model: Rewards and penalties are scheduled, not immediately finalized, allowing downstream systems to aggregate, adjust, or revert them.