The upgrade at this time is an upgrade of the compatible version without any change on the consensus layer of the public chain.
The upgrade time is close to the Chinese Spring Festival, so users may not get in-time technical support when upgrading. For all Conflux ecosystem projects, it is recomended to upgrade new nodes after Febuarary 22. From v1.1.1, Conflux-rust will apply the new address format. If returns include address information, it will be in the new format.
The Conflux Foundation suggests that in the future, Conflux ecosystem projects will obsolete hex40 addresses (starting with 0x) gradually and upgrade to base32check addresses (starting with a network ID, eg. cfx:). On ConfluxScan, there will be a conversion tool between old addresses and new addresses.
The new address format is only a conversion of the old format. Users can still login Conflux wallet via private keys or secret phrases. User assets will not be affected.
Detailed CIP-37 content: https://github.com/Conflux-Chain/CIPs/blob/master/CIPs/cip-37.md
Chinese version of CIP-37: https://forum.conflux.fun/t/topic/4745
v1.1.1 Upgrade Details
Incompatible Changes
- CIP-37: Conflux to shift to base32 address format (starting with a network ID, eg. cfx:). The hex address format similar to Ethereum is deprecated in rpc interactions to full node.
- Keep all data (including directories
storage_db
,blockchain_db
, andnet_config
) within a single directory configured withconflux_data_dir
(the default directory name isblockchain_data
).
Compatible RPC Changes
- Add
cfx_getSupplyInfo
to return the CFX supply information. - Include
networkId
incfx_getStatus
response. - Include
address
incfx_getAccount
response.
Improvements
- Support CIP-37 address format in
mining_author
configuration. - Reduce delay in logs pub-sub; now we send logs immediately after they become available.
- Implement Execution Trace functionality. It includes detailed call/create/return/internal_transfer events being triggered by a transfer. Inspecting the trace information will enable the applications like conflux-scan to be able to track all transfers of CFX accurately.
- Improve the test framework to fix some random test failure.
What do Conflux ecosystem developers need to do for this upgrade?
The Conflux official will update all the tutorials and SDKs on February 5th, but it is suggested for ecosystem applications, wallets, exchanges and mining pools to upgrade RPC after February 22nd. Users using the official nodes (RPC) can remain the same. The current version of RPC will be valid sill the end of March, and after that, the Conflux official will provide the latest version of RPC.
After upgrading the node (RPC), developers need to use the latest SDK. Without additional configuration, interactions can only process with base32 addresses (starting with a network ID, eg. cfx:). All ecosystem applications, wallets, exchanges and mining pools, please remind users and developers.
Influence on the front end interface
Portal
- After upgrading to v0.5.11, API will return hex40 addresses (starting with 0x), the signature only supports hex40 addresses (starting with 0x), but there will be a notice when transferring to a hex40 address (starting with 0x).
- After upgrading to v0.6 , API only returns base32 addresses (starting with a network ID, eg. cfx:), the signature supports both hex40 addresses (starting with 0x) and base32 addresses (starting with a network ID, eg. cfx:).
- DApps need to consider the situation that users do not upgrade their Portal and API returns with both hex40 addresses (starting with 0x) and base32 addresses (starting with a network ID, eg. cfx:).
SDK adapting
How does Conflux Javascript SDK adapt CIP37: https://github.com/Conflux-Chain/js-conflux-sdk/blob/master/docs/conflux_checksum_address.md
In Chinese: https://juejin.cn/post/6922723243811930119
Influence on the back end service program
SDK adapting
How does Conflux Java SDK adapt CIP37: https://github.com/Conflux-Chain/java-conflux-sdk/blob/master/docs/cfx-address.md
In Chinese: https://juejin.cn/post/6922724320191971342
How does Conflux Golang SDK adapt CIP37: https://github.com/Conflux-Chain/go-conflux-sdk
In Chinese: https://juejin.cn/post/6922763171941842958/
Configuration of node docs
Configuration instruction
v1.1.1 and later versions
Open the run/tethys.toml file in a text editor and configure the mining parameters:
mining_author="personal wallet address"
personal wallet address : both hex40 addresses (starting with 0x) and base32 addresses (starting with a network ID, eg. cfx:) are acceptable.
Note:
At present, the mining_author in Conflux-rustv1.1.1 requires quotation marks to identify new addresses, such as
mining_author='"cfx:aampumd7hpufe4krfpsur645xt1cewtkpybkhyn7fc"'
The Conflux-rust v1.1.2 that will be released later will allow you to directly enter the address, such as
mining_author="cfx:aampumd7hpufe4krfpsur645xt1cewtkpybkhyn7fc"
Directory changes:
In v1.1.1 and later versions, all data are kept under the directory of conflux_data_dir
. The default path is ./blockchain_data
.
The default directory structure before v1.1.1 was:
├── blockchain_db
├── net_config
├── storage_db
├── conflux
├── log
├── log.yaml
├── start.bat
├── start.sh
├── stderr.txt
├── tethys.toml
The default directory structure after v1.1.1 ( including v1.1.1) is:
├── blockchain_data
│ ├── blockchain_db
│ ├── net_config
│ └── storage_db
├── conflux
├── log
├── log.yaml
├── start.bat
├── start.sh
├── stderr.txt
├── tethys.toml
Adapting method 1 (recommended):
Create a new directory blockchain_data
, and move the three directories blockchain_db
, net_config
and storage_db
to blockchain_data
. It is not necessary to change the configuration file tethys.toml
.
Adapting method 2:
Do not move the directories, and set the configuration file tethys.toml
as follows:
conflux_data_dir = "."
netconf_dir = "./net_config"
block_db_dir = "./blockchain_db"