Asking about Governor related features

Dear OpenZeppelin team,

I'm trying to build my DAO using Governor doc and there are some features that I don't understand much. Imaging the situation where I deployed my Governor with MyTimelock and MyToken (MTK) as constructor parameters:

  1. Token address
  • I see that I need to import MTK by hand in Tally. Wouldn't it cause troubles if someone accidentally import the wrong Token address?
  • It leads me to wonder if Governor can realize the Token constructed with it. I checked the events emitted after deploying and it seems like there is no event with Token address. Is that the reason why Tally and my Subgraph can't fetch that Token address? Alternatively, Would OpenZeppelin auto-generated Schema be the issue?
  1. Query Governor in Subgraph
  • I use Openzeppelin auto-generated Schema to query Governor with The Graph. However, I can't query Governor's address before the first Proposal is created. Is it because of the Events emitted when deploying Governor? I don't see any event with Governor address.
  1. Timelock's Proposer role
  • Governor documentary stated like this:
    "Proposer fight: Having multiple proposers, while providing redundancy in case one becomes unavailable, can be dangerous. As proposer have their say on all operations, they could cancel operations they disagree with, including operations to remove them for the proposers."
  • I believe Proposer role will have such powerful control. However, I faced a weird issue while I was proposing in Tally. I didn't gave my Address 4 the Proposer role on purpose. I made sure to check the hasRole function many times. However, I was still be able to Queue the Proposal. Therefore, I though Queue is executed through Governor instance, but then, wouldn't it be conflicted with what the documentary warning?
  1. castVoteBySig and delegateBySig function
  • With these two functions, it seems to be possible to build a gas-free governor application which means maybe the service provider pays all necessary gases. Would it be possible? Is this feature in development? Because I don't seem to find any useful info in the Doc or in the introduction video.
  1. cancel() function
  • I wonder if the cancel() function in TimelockController is extended from Governor's internal cancel()? They seem to be used in different scenarios

Please clarify for me and correct me if I misunderstand somewhere.
Thank you in advance

:1234: Code to reproduce


:computer: Environment

I use Remix, OpenZeppelin Wizard and Defender to create my Governor

You should ask that to Tally.

The token used by the governor cannot be updated. We don't really need to have an event, because we don't need to notify anyone that this value changed. In most cases, there will be a token() method that you can call.

That is correct. The subgraph needs activity to hook into. There is currently no way around that :confused:

The normal configuration is to have the governor be the (only) proposer on the timelock. That way, when a proposal is successful, anyone can call queue on the governor, and the governor be able to forward the proposal to the timelock.

The warning is saying that, if some other address, beyond the governor itself, has the proposer role on the timelock, then that address can bypass the governance, and possibly cancel governance action.

This is supported at the contract level. We do not however provide offchain tolling/UI to do that. You'd have to come up with your own interface that gets user to produce the signatures, and relay them (with all the DOS protection needed)

The cancel function on the timelock is designed so that address with the right role are able to cancel a proposal. This is "generic".
The internal _cancel function in the governor allow the dev to possibly expose it (with some restrictions) to allow proposals being cancelled.

It is possible to combine these in different ways:

  • having the governor be a canceller on the timelock, and expose the _cancel to allow cancellation of proposal during the vote & during the timelock period
  • not exposing the governor _cancel but having a multisig have the canceller role on the timelock. This would allow a council to veto governance decisions.
  • ...
  • anything you could imagine
1 Like

Thank you so so much for your time and your answer. Very informative and helpful, you are my hero :heartpulse: