Tezos Development Part 2: Self-amendment & Governance

Tezos Development Part 2: Self-amendment & Governance

Tezos Development Part 2: Self-amendment & On-Chain Governance

Tezos utilizes a unique self-amendment and on-chain governance process. It is extremely difficult to talk about these two concepts separately. We will try to explain how the Self-amendment process and On-Chain governance work on Tezos. These two allow upgrading the protocol without the need for hard forks, which can be troublesome to the network.

Why is this important?

Blockchain is based on a peer-to-peer network, a set of rules all participants agree on. The acceptance of this or any other set of rules is defined by consensus. It ends to be a social construct, although blockchains are ruled by algorithms and code, it’s still used and developed by people.

In order to have a public and decentralized blockchain that can be improved along with innovations, it is necessary to set the bases on how all participants can express their agreement or disagreement on the current rules, future upgrades, or new innovations.

A more detailed explanation can be found here: The politics of algorithms. | Arthur Breitman | TEDxSanFrancisco 

Governance

Tezos uses On-Chain Governance to propose, select, test, and activate protocol upgrades (amendments) that can be approved or refused within the designed process, this Self-Amendment process is divided into five different periods:

  1. Proposal Period: delegates propose amendments and select one to continue with.
  2. Exploration Vote Period: delegates vote on whether to continue with the selected proposal.
  3. Cooldown Period: the community gets some time to test and discuss the proposal.
  4. Promotion Vote Period: delegates vote on whether to activate this proposal or not.
  5. Adoption Period: the community gets some time to prepare for the activation.

The governance process in Tezos is based on a system of token-weighted voting. This means that the more tokens a voter holds, the more weight their vote will carry. This is intended to give larger stakeholders a greater say in the direction of the network, while still allowing for smaller stakeholders to participate in the process.

Who can participate in this on-chain governance?

In order to propose and vote on changes to the protocol, Tezos uses its bakers who are responsible for validating transactions and creating new blocks on the network. So, bakers are the ones that can propose, vote, and activate protocol upgrades.

This doesn’t mean that every other participant in the tezos ecosystem is excluded, being tezos based on liquid proof of stake, every tez holder can delegate its voting power to any baker(delegate), this process is known as “delegation,”. The delegator can change delegate at any moment. Therefore, everyone can participate. There are different criteria to rate a baker and different platforms for discussing protocol upgrades.

Bakers:  

In this context, bakers can be classified as “Public” or “Private”. Public bakers are open to everyone delegating their tez to them and they provide a baking service allowing delegators to share a percentage of the profits of the baking activity. On the other hand, private bakers are free to keep their profits regardless of who delegated their stake to them and they can not avoid someone delegating to them.

Criteria to select a baker:

If you want to select from a Public Baker you could see the different platforms listing them and how they value each baker, some of the criteria might include: efficiency, fee, projects in the tezos ecosystem, baker’s payout system, free space, involvement in network management, and support.

For mention, the most popular rating platforms: Baking Bad, TzStats, and Tezos Nodes are valuable sources of information.

Self-amendment

As mentioned before, it consists of 5 periods each of which lasts five baking cycles, representing 8192 blocks (≈ 2.8 days) each cycle, giving around 14 days for each period and about two months for the whole process. Let’s describe each a little bit more:

  1. Proposal period:

In this first period, all delegates can submit up to 20 proposals, the delegates submit a proposal by submitting the hash of the source code. When the delegate submits a proposal they are also voting for that proposal. This voting is token-weighted based on the number of rolls delegated to the proposer/voter at the beginning of the period.

In order to proceed to the next period it is necessary to have only one proposal that has achieved a quorum of at least 5% of votes. If there’s no proposal that meets that requirement or if there’s a tie. Then the proposal period restarts.

A good way to keep you informed about proposal discussions is to visit Tezos Agora Forum or by joining the tezos ecosystem communities.

If you are a baker:

The process for submitting a new proposal is out of the scope of this article but by having a proposal hash, you could submit or upvote for a proposal by running the following command:

 ./octez-client submit proposals <YOUR_BAKER_ADDRESS> for <PROPOSAL_HASH>

If you want to upvote for several you could upvote for upto 20 proposals by running:

 ./octez-client submit proposals <YOUR_BAKER_ADDRESS> for <PROPOSAL_HASH1> <PROPOSAL_HASH2>…

You could also upvote for a proposal and then for another, the first upvote can not be deleted.

  1. Exploration Vote Period:

In this period, voters get to vote “Yay”, “Nay” or “Pass” for the selected proposal, it is required that one proposal from the previous period meets two requirements:

  1. Super-majority: reaching super majority means that the cumulated staked of “Yay” ballots is greater than 80% of the cumulated staked of “Yay” and “Nay”.  
  2. Quorum: a quorum of participation is computed during this period, a calculated number each exploration and promotion period to determine the minimum number of voter participants required.

If the voting participation fails to achieve a quorum of participation and 80% of the super-majority, the self-amendment process restarts to the first-period, proposal.

If you are a baker:

The process to ballot the selected proposal is by running the following command:

 ./octez-client submit ballot for <YOUR_BAKER_ADDRESS> <PROPOSAL_HASH> <YAY|NAY|PASS>

  1. Cooldown Period:

During this period, bakers don’t have to vote on-chain. The main focus of this period occurs Off-chain, where communities discuss their thoughts on the selected proposal, and bakers and developers are able to test and discuss in order to decide on how they will vote.  Passing the 5 baking cycles, the process moves to the next period, promotion.  

  1. Promotion vote period:

Similarly to the exploration period, the same two requirements need to be met, super-majority and quorum, the difference is that if requirements are met the proposal will be finally adopted, and it becomes relevant to make voting based on the previous discussions and test from the cooldown period.

        If you are a baker:

The process to ballot the selected proposal is by running the following command:

 ./octez-client submit ballot for <YOUR_BAKER_ADDRESS> <PROPOSAL_HASH> <YAY|NAY|PASS>

  1. Adoption Period:

By this final period, bakers and the entire ecosystem have some time to prepare for the activation. This includes updating the dev tools. An official release of the protocol is announced that might include a full changelog and update instructions.  

After this phase, the mainnet activation is complete.

If you are a baker:

It’s extremely advised that you update the protocol with sufficient time before activation, if activation happens and you are still in the previous protocol version you will lose endorsements and bakings resulting in decreasing efficiency and performance.

For the upgrade, follow the instructions described in the official release, you might find it in “https://tezos.gitlab.io/releases/version-<version_number>.html” Alternatively you should join tezos baking slack for updates and support if needed during the process.

The process usually consists on:

Upgrade the node to the new protocol version:

To update from sources run:

git fetch

git checkout <version_number>

rm -rf _opam _build

make build-deps

eval $(opam env)

make

Once the node is updated, run the baker:

./octez-baker-<Protocol_version> run with local node ~/.octez-node <YOUR_BAKER_ADDRESS_OR_ALIAS> –liquidity-baking-toggle-vote pass

A baker in the adoption period could have bakers running for the previous and the upcoming protocol version at the same time, after activation the baker with the previous protocol version will be depreciated, and the baker with the new one will start running after activation.  

(Optionally) run the accuser:

./octez-accuser-<Protocol_version> run

Final thoughts

Governance in the blockchain is an interesting and deep topic, tezos has implemented its on-chain governance since 2019 and is a blockchain that was designed thinking in governance from its beginnings.

Probably, the best place to check the current period and learn about the amendment process is Tezos Agora and you can see the history of all amendments in the Open Tezos Documentation.

Exported with Wordable