Skip to main content

Parthenon

Parthenon, OlympusDAO's on-chain governance system.

The Parthenon policy is also the Kernel's Executor.

Methods

ACTIVATION_DEADLINE

function ACTIVATION_DEADLINE() external view returns (uint256)

Amount of time a submitted proposal can exist before activation can no longer be triggered.

Returns

NameTypeDescription
_0uint256undefined

ACTIVATION_TIMELOCK

function ACTIVATION_TIMELOCK() external view returns (uint256)

Amount of time a submitted proposal must exist before triggering activation.

Returns

NameTypeDescription
_0uint256undefined

COLLATERAL_DURATION

function COLLATERAL_DURATION() external view returns (uint256)

Amount of time a non-executed proposal must wait for the proposal to go through.

This is inclusive of the voting period (so the deadline is really ~4 days, assuming a 3 day voting window).

Returns

NameTypeDescription
_0uint256undefined

COLLATERAL_MINIMUM

function COLLATERAL_MINIMUM() external view returns (uint256)

The minimum amount of VOTES the proposer must post in collateral to submit

Returns

NameTypeDescription
_0uint256undefined

COLLATERAL_REQUIREMENT

function COLLATERAL_REQUIREMENT() external view returns (uint256)

The amount of VOTES a proposer needs to post in collateral in order to submit a proposal

This number is expressed as a percentage of total supply in basis points: 500 = 5% of the supply

Returns

NameTypeDescription
_0uint256undefined

EXECUTION_DEADLINE

function EXECUTION_DEADLINE() external view returns (uint256)

Amount of time after the proposal is activated (NOT AFTER PASSED) when it can be activated (otherwise proposal will go stale).

This is inclusive of the voting period (so the deadline is really ~4 days, assuming a 3 day voting window).

Returns

NameTypeDescription
_0uint256undefined

EXECUTION_THRESHOLD

function EXECUTION_THRESHOLD() external view returns (uint256)

Net votes required to execute a proposal on chain as a percentage of total registered votes.

Returns

NameTypeDescription
_0uint256undefined

EXECUTION_TIMELOCK

function EXECUTION_TIMELOCK() external view returns (uint256)

Required time for a proposal before it can be activated.

This amount should be greater than 0 to prevent flash loan attacks.

Returns

NameTypeDescription
_0uint256undefined

INSTR

function INSTR() external view returns (contract INSTRv1)

Returns

NameTypeDescription
_0contract INSTRv1undefined

VOTES

function VOTES() external view returns (contract VOTESv1)

Returns

NameTypeDescription
_0contract VOTESv1undefined

VOTING_PERIOD

function VOTING_PERIOD() external view returns (uint256)

The period of time a proposal has for voting

Returns

NameTypeDescription
_0uint256undefined

WARMUP_PERIOD

function WARMUP_PERIOD() external view returns (uint256)

Amount of time a wallet must wait after depositing before they can vote.

Returns

NameTypeDescription
_0uint256undefined

_max

function _max(uint256 a, uint256 b) external pure returns (uint256)

Parameters

NameTypeDescription
auint256undefined
buint256undefined

Returns

NameTypeDescription
_0uint256undefined

activateProposal

function activateProposal(uint256 proposalId_) external nonpayable

Parameters

NameTypeDescription
proposalId_uint256undefined

changeKernel

function changeKernel(contract Kernel newKernel_) external nonpayable

Function used by kernel when migrating to a new kernel.

Parameters

NameTypeDescription
newKernel_contract Kernelundefined

configureDependencies

function configureDependencies() external nonpayable returns (Keycode[] dependencies)

Define module dependencies for this policy.

Returns

NameTypeDescription
dependenciesKeycode[]- Keycode array of module dependencies.

executeProposal

function executeProposal(uint256 proposalId_) external nonpayable

Parameters

NameTypeDescription
proposalId_uint256undefined

getProposalMetadata

function getProposalMetadata(uint256) external view returns (address submitter, uint256 submissionTimestamp, uint256 collateralAmt, uint256 activationTimestamp, uint256 totalRegisteredVotes, uint256 yesVotes, uint256 noVotes, bool isExecuted, bool isCollateralReturned)

Return a proposal metadata object for a given proposal id.

Parameters

NameTypeDescription
_0uint256undefined

Returns

NameTypeDescription
submitteraddressundefined
submissionTimestampuint256undefined
collateralAmtuint256undefined
activationTimestampuint256undefined
totalRegisteredVotesuint256undefined
yesVotesuint256undefined
noVotesuint256undefined
isExecutedboolundefined
isCollateralReturnedboolundefined

isActive

function isActive() external view returns (bool)

Easily accessible indicator for if a policy is activated or not.

Returns

NameTypeDescription
_0boolundefined

kernel

function kernel() external view returns (contract Kernel)

Returns

NameTypeDescription
_0contract Kernelundefined

reclaimCollateral

function reclaimCollateral(uint256 proposalId_) external nonpayable

Parameters

NameTypeDescription
proposalId_uint256undefined

requestPermissions

function requestPermissions() external view returns (struct Permissions[] requests)

Function called by kernel to set module function permissions.

Returns

NameTypeDescription
requestsPermissions[]- Array of keycodes and function selectors for requested permissions.

submitProposal

function submitProposal(Instruction[] instructions_, string title_, string proposalURI_) external nonpayable

Parameters

NameTypeDescription
instructions_Instruction[]undefined
title_stringundefined
proposalURI_stringundefined

vote

function vote(uint256 proposalId_, bool approve_) external nonpayable

Parameters

NameTypeDescription
proposalId_uint256undefined
approve_boolundefined

Events

CollateralReclaimed

event CollateralReclaimed(uint256 proposalId, uint256 tokensReclaimed_)

Parameters

NameTypeDescription
proposalIduint256undefined
tokensReclaimed_uint256undefined

ProposalActivated

event ProposalActivated(uint256 proposalId, uint256 timestamp)

Parameters

NameTypeDescription
proposalIduint256undefined
timestampuint256undefined

ProposalExecuted

event ProposalExecuted(uint256 proposalId)

Parameters

NameTypeDescription
proposalIduint256undefined

ProposalSubmitted

event ProposalSubmitted(uint256 proposalId, string title, string proposalURI)

Parameters

NameTypeDescription
proposalIduint256undefined
titlestringundefined
proposalURIstringundefined

VotesCast

event VotesCast(uint256 proposalId, address voter, bool approve, uint256 userVotes)

Parameters

NameTypeDescription
proposalIduint256undefined
voteraddressundefined
approveboolundefined
userVotesuint256undefined

Errors

CollateralAlreadyReturned

error CollateralAlreadyReturned()

DepositedAfterActivation

error DepositedAfterActivation()

ExecutionTimelockStillActive

error ExecutionTimelockStillActive()

ExecutionWindowExpired

error ExecutionWindowExpired()

ExecutorNotSubmitter

error ExecutorNotSubmitter()

KernelAdapter_OnlyKernel

error KernelAdapter_OnlyKernel(address caller_)

Parameters

NameTypeDescription
caller_addressundefined

NotAuthorized

error NotAuthorized()

NotEnoughVotesToExecute

error NotEnoughVotesToExecute()

PastVotingPeriod

error PastVotingPeriod()

Policy_ModuleDoesNotExist

error Policy_ModuleDoesNotExist(Keycode keycode_)

Parameters

NameTypeDescription
keycode_Keycodeundefined

ProposalAlreadyActivated

error ProposalAlreadyActivated()

ProposalAlreadyExecuted

error ProposalAlreadyExecuted()

ProposalIsNotActive

error ProposalIsNotActive()

UnableToActivate

error UnableToActivate()

UnmetCollateralDuration

error UnmetCollateralDuration()

UserAlreadyVoted

error UserAlreadyVoted()

UserHasNoVotes

error UserHasNoVotes()

WarmupNotCompleted

error WarmupNotCompleted()