GovernorTimelock

On‑chain administrative gateway for governor‑privileged actions. Enforces time‑delayed execution via scheduled proposals and per‑function timelock parameters. Manages proposer/executor/canceller roles and supports role updates through the timelock itself.

Functions

CANCELLER_ROLE

Returns the bytes32 representation of the canceller role.

    function CANCELLER_ROLE()
        view
        returns (
            bytes32 cancelerRole
        );

EXECUTOR_ROLE

Returns the bytes32 representation of the executor role.

    function EXECUTOR_ROLE()
        view
        returns (
            bytes32 executorRole
        );

PROPOSER_ROLE

Returns the bytes32 representation of the proposer role.

ROLE_ADMIN

Returns the bytes32 representation of the role admin.

MIN_DELAY

Returns the minimum allowed delay (seconds).

MIN_EXECUTION_WINDOW

Returns the minimum allowed execution window (seconds).

defaultTimelockParameters

Returns the default timelock parameters.

setDefaultTimelockParameters

Sets the default timelock parameters (only via timelock itself).

Parameters:

Index
Name
Type
Internal Type
Description

0

delay

uint32

uint32

New default delay (seconds)

1

executionWindow

uint32

uint32

New default window (seconds)

setFunctionTimelockParameters

Sets per‑function timelock parameters (only via timelock itself).

Parameters:

Index
Name
Type
Internal Type
Description

0

target

address

address

Target contract address

1

functionSelector

bytes4

bytes4

Function selector

2

delay

uint32

uint32

Delay for this function (seconds)

3

executionWindow

uint32

uint32

Execution window for this function

scheduleProposals

Schedules proposals for execution after the delay.

Parameters:

Index
Name
Type
Internal Type
Description

0

targets

address[]

address[]

Target contract addresses to call

1

data

bytes[]

bytes[]

Encoded calldata for each target

unscheduleProposals

Unschedules proposals by id (non‑role updates only).

Parameters:

Index
Name
Type
Internal Type
Description

0

proposalIds

uint256[]

uint256[]

IDs of proposals to cancel

executeProposals

Executes proposals within their execution window.

Parameters:

Index
Name
Type
Internal Type
Description

0

proposalIds

uint256[]

uint256[]

IDs of proposals to execute

1

targets

address[]

address[]

Target contract addresses

2

data

bytes[]

bytes[]

Encoded calldata for each target

proposeRoleUpdates

Proposes role grants/revocations (must be executed via timelock).

Parameters:

Index
Name
Type
Internal Type
Description

0

roles

bytes32[]

bytes32[]

Roles to update

1

accounts

address[]

address[]

Accounts to apply role changes to

2

shouldGrant

bool[]

bool[]

true to grant, false to revoke

updateRole

Updates a role (callable only by the timelock itself during execution).

Parameters:

Index
Name
Type
Internal Type
Description

0

role

bytes32

bytes32

Role identifier

1

account

address

address

Account to update

2

grantRole

bool

bool

true to grant, false revoke

isExecutable

Returns true if a proposalId is executable now.

Parameters:

Index
Name
Type
Internal Type
Description

0

proposalId

uint256

uint256

Proposal to check timing

Events

DefaultTimelockSet

ERC20TokenWithdrawn

FunctionTimelockSet

PendingTokenWithdrawerSet

ProposalExecuted

ProposalScheduled

ProposalUnscheduled

RoleUpdated

TokenWithdrawerAccepted

Last updated