Skip to main content

Release 14.01.2025: migration guide

This release changes the way gas is calculated for outgoing transactions and modifies the default gas price across the cluster.

Summary of key changes

  • All outgoing transactions require paying extra gas

Migration of smart contracts

  • Allocate extra gas to operations that spawn outgoing transactions

The gas required to be paid for outgoing transactions now depends on a variable titled extraGasPercent. How this variable is calculated depends on the gas price at the shard where an outgoing transaction is sent.

If the gas price at the destination shard (destShardGasPrice) is lower than the default gas price (defaultGasPrice):

extraGasPercent=min(100,(destShardGasPricedefaultGasPrice)/(defaultGasPrice/100))extraGasPercent = \min(100, (destShardGasPrice - defaultGasPrice) / (defaultGasPrice / 100))

Otherwise:

extraGasPercent=0extraGasPercent = 0

The required amount of gas for outgoing transactions is calculated as follows:

requiredGas=forwardFee+extraForwardFeeStepextraGasPercentrequiredGas = forwardFee + extraForwardFeeStep * extraGasPercent

, where forwardFee is 1000 and extraForwardFeeStep is 100.

  • Increase gas paid for all transactions

Default gas price has been changed from 10 to 100 across the cluster. This means that more feeCredit needs to be paid for the execution of all transactions.

Migration of =nil; CLI commands

No specific changes have been made to =nil; CLI commands.

Migration of Nil.js scripts

No specific changes have to be made to existing Nil.js scripts.

Migration of Hardhat scripts and tasks

No specific changes have to be made to existing Hardhat scripts and tasks.