Technical Release Memo for v1.4.15

Summary:

Casper network v1.4.15 update is a patch release that optimizes the way in which era information is written to the global state. This is done by removing the previous process of writing a unique key to the trie for each eras of information to be stored thus reducing the width of the global state.

Key Changes:

  1. In v1.4.15, we optimized the process of storing the era report by removing the mechanism of recording era information to the global state. Prior to v1.4.15, at the switch block of an era, that eras information used to be recorded onto a unique key for each eras, thus resulting in as many unique keys as the number of eras for that chain.
  2. In v1.4.15 instead of a unique key for each era, we have one stable key onto which era information is written to and any new era information is overwritten. This change reduces the width of global state and supports the upcoming feature Fast-Sync in v1.5.0 by making syncing faster and also saving on disk space, here.
  3. A new endpoint “chain_get_era_summary” was added to query the Era Summary Report.
  4. The max_stack_height value has increased from 188 to 200 to make the network more resilient.
  5. The call and call_indirect control flow opcode costs are increased to 140_000 motes to improve network resilience.
  6. An edge case bug in the block validator was fixed, more details here.
  7. A minor security update has also been added to the release, the details of which will be furnished post Mainnet release.

How do the changes impact Network Operators?

  1. There is no impact to network operations and no downtime since the pruning of era info keys will happen for each new block generated after the upgrade i.e a batch size value of 10 will prune 10 eras info keys per block, first eras 0-9 in block 1 after the upgrade will be removed followed by era 10-19 at block 2.

How do the changes impact Smart Contract/dApp Developers?

  1. There is no impact to existing contracts due to the increase in max_stack_ height from 188 to 200, existing smart contracts are not impacted by the change, since the processed and stored wasms have the previous max stack limit already injected into them.
    However any newly installed or newly upgraded or recompiled contract may be impacted by the new limit if the contract code is not already well-tuned. We urge the developers to tune their code if they encounter any issues. Tuning of code may also result in more performant logic( getting the same output with fewer opcodes and thus gas costs).
  2. There is an additional new endpoint called “chain_get_era_summary” to query the Era Summary Report and is backward compatible. This is updated in the Casper-Client v1.6.0 and will be updated in the JS SDK v2.13.0. However, the existing RPC method chain_get_era_info_by_switch_block will continue to be forward-compatible to retrieve era summary information, thus no change is needed if you are using the old RPC method. This old method will be deprecated in 2.0.0.
  3. The call and call_indirect control flow costs have been increased to 140_000 motes from 440, thus there may be a very minor increase in install and mint costs of NFTs. Because the costs are injected into stored wasms, only new contracts are affected by the cost increase.  Example: see Appendix section below.
  4. There is a change where we moved some testing features into casper-types, for more details here.


Mainnet Activation Installation Instructions
May 12 2023 Installation Instructions

Appendix: Example of CEP 78 install of contract for 1_000_000 tokens with minting for 1000 NFTs.