Skip to content

v0.7.1

Compare
Choose a tag to compare
@gmanev7 gmanev7 released this 21 Jun 13:28
· 717 commits to main since this release
9e02273

What's Changed

🚀 Features

  • Intro void
  • feat(leaser): close protocol
  • feat(admin): Add protocol deregistration
  • fix(admin): Remove protocol from storage on deregistration
  • feat(admin)!: Remove rewards dispatcher contract
  • refactor(admin): Remove serde aliases
  • (versioning) Introduce void-contract release label
  • (scripts) Leaser init msg - add protocols_registry
  • (admin) Add expected void-contract release label
  • (void) Return the expected data on migration
  • (admin) Use the new API version of versioning

🚜 Refactor

  • (versioning) Use factory member fn-s

⚙️ Miscellaneous Tasks

  • (versioning) Reduce a method visibility

NOTES on building this release

  • The release was mainly built with CI with two exceptions:
    -- manually built a neutron-astroport-usdc_axelar for net-dev on channel-3/channel-1035
    -- manually replaced the oracle.wasm of osmosis-osmosis-usdc_noble for net-dev with one built outside a Docker container. The CI built did not pass cosmwasm-check

Upgrade from v0.7.0

Store the new code of all platform and protocol contracts

IMPORTANT! They all should have --run-as <admin contract address> and with their respective --code-hash <code hash>, where <code hash> is the binary's SHA256 hash.

Pass the Admin contract, with --instantiate-anyof-addresses nolus1gurgpv8savnfw66lckwzn4zk7fp394lpe667dhu7aw48u40lj6jsqxf8nd, when preparing the store code proposals of the Leaser, and with --instantiate-anyof-addresses <the_Leaser_addr> for the Lease ones.

Migrate the contracts via the Admin contract

Prepare a proposal metadata

Open a JSON file with the structure below and fill in the details. Save.

{
 "title": "Migration to v0.7.1",
 "authors": [
  "The Nolus Team"
 ],
 "summary": "A summary of the migration",
 "details": "More details ...",
 "proposal_forum_url": "<some>",
 "vote_option_context": "???"
}

Store on IPFS

Upload the metadata JSON prepared above to IPFS and save its CID

Prepare the proposal

Open a JSON file with the structure below and fill in the details. Save.

{
  "messages": [
    {
      "@type": "/cosmwasm.wasm.v1.MsgMigrateContract",
      "sender": "<proposal_sender>",
      "contract": "nolus1gurgpv8savnfw66lckwzn4zk7fp394lpe667dhu7aw48u40lj6jsqxf8nd",
      "msg": {
        "migrate_contracts": {
          "release": "tag-v0.7.1-2024-06-21T12:38+00:00",
          "migration_spec": {
            "platform": {
              "timealarms": {
                "code_id": "<Timealarms code Id>",
                "migrate_msg": "{}"
              },
              "treasury": {
                "code_id": "<Treasury code Id>",
                "migrate_msg": "{}"
              }
            },
            "protocol": {
              "<name of a registered protocol>": {
                "leaser": {
                  "code_id": "<Leaser code Id>",
                  "migrate_msg": "{\"protocols_registry\":\"<Admin contract addr>\"}"
                },
                "lpp": {
                  "code_id": "<Lpp code Id>",
                  "migrate_msg": "{}"
                },
                "oracle": {
                  "code_id": "<Oracle code Id>",
                  "migrate_msg": "{}"
                },
                "profit": {
                  "code_id": "<Profit code Id>",
                  "migrate_msg": "{}"
                },
                "reserve": {
                  "code_id": "<Reserve code Id>",
                  "migrate_msg": "{}"
                }
              },
              "<name of another registered protocol>": {
                ...
              }
            }
          }
        }
      }
    }
  ],
  "metadata": "ipfs://<CID of the proposal metadata>",
  "deposit": "1000000000unls",
  "title": "Migration to v0.7.1",
  "summary": "A summary of the migration"
}

Migrate the contracts

nolusd tx gov submit-proposal <path_to_the_proposal_json> --from <signer> --gas <gas_amount> --gas-prices 0.0025unls