Skip to content

upgrade-governance: add upgrade rollback proposal type #534

Description

@Emeka000

Summary

Once an upgrade is executed there is no on-chain mechanism to propose and vote on reverting to a previous WASM hash. If a bug is discovered post-upgrade, rollback requires manually re-proposing the old hash without any rollback semantics or guards.

Proposed Change

  • Add propose_rollback(signer, target_proposal_id) that creates a rollback proposal pre-populated with the WASM hash and metadata from a previously executed proposal
  • Rollback proposals require the same signer threshold as standard upgrades
  • Emit a UpgradeRollbackProposed { rollback_proposal_id, original_proposal_id, wasm_hash } event
  • Add max_rollback_age_ledgers config — rollback to proposals older than this is blocked

Acceptance Criteria

  • Rollback proposal references original proposal ID
  • Rollback blocked for proposals older than max age
  • Rollback follows same voting and timelock flow as regular upgrade
  • Test covers: propose, vote, execute rollback cycle

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions