MultiversX
Scale across the Multiverse. Build new apps, new economies, new worlds.
Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding Join the xDay 2023 /hackathon Sep 21 - Oct 21 $1M in Prizes and Funding

June 14, 2023

Release: mx-sdk-py-cli - v7.0.0

Improvements of "mxpy testnet". Re-brand to "localnet"

In this release, there is a significant change that affects backwards compatibility, specifically related to the new configuration schema. Here's an illustration of the localnet.toml file, which demonstrates the option of choosing between remote or local software resolution.

[general]
log_level = "*:DEBUG"
genesis_delay_seconds = 10
rounds_per_epoch = 100
round_duration_milliseconds = 6000

[metashard]
consensus_size = 1
...

[shards]
num_shards = 1
...

[networking]
...
port_proxy = 7950
...

[software.mx_chain_go]
resolution = "remote"
archive_url = "https://github.com/multiversx/mx-chain-go/archive/refs/heads/master.zip"
archive_download_folder = "~/multiversx-sdk/localnet_software_remote/downloaded/mx-chain-go"
archive_extraction_folder = "~/multiversx-sdk/localnet_software_remote/extracted/mx-chain-go"
local_path = "~/multiversx-sdk/localnet_software_local/mx-chain-go"

[software.mx_chain_proxy_go]
resolution = "remote"
archive_url = "https://github.com/multiversx/mx-chain-proxy-go/archive/refs/heads/master.zip"
archive_download_folder = "~/multiversx-sdk/localnet_software_remote/downloaded/mx-chain-proxy-go"
archive_extraction_folder = "~/multiversx-sdk/localnet_software_remote/extracted/mx-chain-proxy-go"
local_path = "~/multiversx-sdk/localnet_software_local/mx-chain-proxy-go"
Copied to clipboard!

Other significant changes:

  • refactoring, partial re-design;
  • allow one to use pre-built binaries of node, seednode, and proxy.
  • allow one to configure round duration, epoch duration etc.

Re-branding

In regards to the rebranding, from now on:

  • mxpy testnet <-> mxpy localnet;
  • testnet.toml <-> localnet.toml.

Commands

  • New command: creates, builds, configures a localnet (without starting it, though) - this calls new, prerequisites, build, and config in one go.
mxpy localnet setup
Copied to clipboard!
  • New command: creates a localnet.toml configuration file.
mxpy localnet new
Copied to clipboard!
  • Clean command stays the same:
mxpy localnet clean
Copied to clipboard!
  • Fetch repositories and other dependencies:
mxpy localnet prerequisites
Copied to clipboard!
  • New command: will build the software:
mxpy localnet build
Copied to clipboard!
  • Copying of files & folders & patching the config files (NO BUILD):
mxpy localnet config
Copied to clipboard!
  • Start the network (can be stopped at any time by killing the mxpy process):
mxpy localnet start
Copied to clipboard!

Remove project argument from contract deploy and contract upgrade

The --project argument from the contract deploy and contract upgrade commands has been removed. They created confusion because when it was used, if the contract wasn't previously built it would build the contract first, then load the bytecode. If the contract was built, it wouldn't rebuild it, it would just load the existing bytecode.

Consider using a newer version of "wasm-opt", by default

Newer versions of rustc might generate WASM bytecode that isn't properly handled by wasm-opt v105.

E.g.

rustc 1.70.0-nightly (9df3a39fb 2023-04-11)
Copied to clipboard!

Wasm-op error:

[wasm-validator error in function 47] unexpected false: all used features should be allowed, on ...
Copied to clipboard!

Remove command "mxpy account get-transactions"

Removed command mxpy account get-transactions, without a prior deprecation notice (being very exotic, rarely used, and not very helpful). Instead, one can directly query the API using wget or curl.

Remove already-deprecated wallet commands and options

Some commands and command arguments were deprecated in mxpy 6. Now (for mxpy 7), we remove them.

Removed:

  • command mxpy wallet derive. One should now use mxpy wallet convert, instead.
  • arguments --pem, --json, --output-path of command mxpy wallet new. One should now use --format=... and --outfile parameters, instead

Replacement examples:

  • mxpy wallet derive alice.pem --mnemonic is replaced by mxpy wallet convert --in-format=raw-mnemonic --out-format=pem --outfile=alice.pem
  • mxpy wallet new --pem --output-path=alice.pem is replaced by mxpy wallet new --format=pem --outfile=alice.pem

See:

Remove deprecated EEI checks

This is a breaking change. Nevertheless, CI workflows should remain unaffected as the latest versions of mx-sc-actions no longer rely on mxpy.

Github Release link: mxpy V7

Migration support from v6 to v7: migration to v7

We hope that you'll find these changes useful and that they will help you to be even more productive in your development work. As always, we welcome your feedback and suggestions in Discord or Telegram, and we look forward to continuing to enhance mxpy in the future.