Skip to content

governor:propose

Create a Governor proposal from a block of commands: each action in the block becomes one of the proposal calls. Optionally binds the proposal id to a variable.

governor:propose [variable] <governor> <description> <actions>
Name Type Description
[variable] variable Variable to bind the proposal id to
governor address Governor address
description string Proposal description (markdown)
actions block Block of commands making up the proposal
load governor
load access-control
set $governor 0x323A76393544d5ecca80cd6ef2A560C6a395b7E3
set $token 0xC18360217D8F7Ab5e7c516566761Ea12Ce7F9D72
# Bind the proposal id for voting later in the same script
governor:propose $proposalId $governor "Fund the grants program" (
exec $token transfer(address,uint256) 0x4F2083f5fBede34C2714aFfb3105539775f7FE64 100e18
access-control:grant $token MINTER_ROLE 0x4F2083f5fBede34C2714aFfb3105539775f7FE64
)
  • Every transaction action produced by the block becomes one (target, value, calldata) entry of the proposal, in order.
  • The sender needs voting power above the Governor’s proposalThreshold at the previous block.
  • The optional leading variable is bound to the proposal id (via getProposalId/hashProposal, with a local fallback), ready for governor:vote or @governor.proposalState.
  • Keep the description: governor:queue, governor:execute and governor:cancel need the exact same description and action block to derive the proposal id.