Summary
In this omnibus proposal, we suggest the following changes:
- Migrate Neutron Voting Registry Contract to v0.3.0;
- Update Pre-Propose Single Overrule Contract, Proposal Multiple, Proposal Single, Pre-Propose Multiple, SubDAO Pre-Propose Single, SubDAO Proposal Single, SubDAO Core Contracts (for Security and Grants SubDAOs), Grants SubDAO Timelock Single Contract;
- Update Vesting Contract for the Grants SubDAO to v1.1.1;
Content of the omnibus
Migration of Neutron Voting Registry to v0.3.0
Neutron Registry v0.3.0 contains completely new logic for handling voting vaults:
- each vault in the registry can be deactivated, meaning a deactivated vault will not handle queries for voting power from the height of deactivation. But the vault is still able to handle historical voting power queries prior to the height of deactivation;
- when a new vault is added to the registry, it will handle only queries after the height of vault addition;
This solves a lot of issues with vault management and consistency of historic voting power calculations.
Here is the full list of changes: [NTRN-78] upgrade neutron voting registry to v2 by sotnikov-s · Pull Request #75 · neutron-org/neutron-dao · GitHub
Update of DAO contracts
The proposal contains migration of contracts (Pre-Propose Single Overrule Contract, Proposal Multiple, Proposal Single, SubDAO Core Contracts (for Security and Grants SubDAOs), Grants SubDAO Timelock Single Contract)) to the new versions to resolve issues with handling errors during proposal execution:
Currently there is no way to understand exactly why a proposal execution failed if the Proposal module of a DAO has close_proposal_on_execution_failure
flag enabled in its configuration.
If this flag is set to true
, a proposal will be closed, even if msgs inside the proposal failed to execute. There is also no way to get an error of msg execution to understand what exactly went wrong.
This update enables functionality to save an error during message execution to facilitate the investigation and debugging process of failed proposals.
Here is the full list of changes: Feat: save failed result backport #ntrn-80 by pr0n00gler · Pull Request #83 · neutron-org/neutron-dao · GitHub
Update other DAO and TGE contracts to fix minor issues and keep dependencies up to date
Upgrade of Vesting Contract for the Grants SubDAO to v1.1.1
This is a minor release update which fixes a small bug in vesting contracts which enabled resetting vesting token in the contract during an active vesting, which could break the logic of the contract.
Here is the full diff of changes: [NTRN-105] feat: disable vesting token change once set by sotnikov-s · Pull Request #59 · neutron-org/neutron-tge-contracts · GitHub
Technical details
-
DAO contracts release: Release v0.5.0 · neutron-org/neutron-dao · GitHub
-
TGE contracts release: Release v0.4.6 · neutron-org/neutron-tge-contracts · GitHub
-
To verify the migration you need to check that uploaded contracts contain only changes from the relevant releases. For that you need to take a hash of uploaded binaries and compare it with the hash of binaries you built on your machine.
Let’s see how to verify validity of the first migration message in the proposal:-
At first we need to understand which contract is being migrated. We can do it by taking a value from the
contract_addr
field in the message (neutron1suhgf5svhu4usrurvxzlgn54ksxmn8gljarjtxqnapv8kjnp4nrstdxvff
), looking at the tables, finding a row with this address and checking the name of the contract. In our case it’s Neutron DAO Core; -
Here we need to build contracts locally. For that we need to clone the repo:
$ git clone https://github.com/neutron-org/neutron-dao.git $ cd neutron-dao $ git checkout v0.5.0 $ make build
Since we are verifying DAO contract we are cloning the DAO repo.
If you want to verify some of the TGE contracts, you need to clone TGE repo (GitHub - neutron-org/neutron-tge-contracts); -
After this we should take a hash of
cwd_core.wasm
contract (name of the binary is similar to the name of contract in step 1):$ shasum -a 256 artifacts/cwd_core.wasm
5a1d4cba81d4176bcce88bb8a14dfd6713b06e096373c2dcecf4d9d8de64d319
is the hash of the Main DAO Core binary you’ve built on your machine.To verify that the migration will happen to the same proper binary you should get a hash of the deployed contract by its code id (you can see a
new_code_id
in the message to be executed below):$ neutrond q wasm code-info 325 --node <https://rpc-kralum.neutron-1.neutron.org:443> --output json | jq ".data_hash" "5a1d4cba81d4176bcce88bb8a14dfd6713b06e096373c2dcecf4d9d8de64d319"
If hashes are equal, that means the deployed binary is correct and contains all the fixes above.
You can verify the rest of migrate message the same way.
-
Executable message
[
{
"wasm": {
"migrate": {
"contract_addr": "neutron1suhgf5svhu4usrurvxzlgn54ksxmn8gljarjtxqnapv8kjnp4nrstdxvff",
"new_code_id": 325,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1fuyxwxlsgjkfjmxfthq8427dm2am3ya3cwcdr8gls29l7jadtazsuyzwcc",
"new_code_id": 327,
"msg": "ewogICAgImZyb21fY29tcGF0aWJsZSI6IHt9CiAgICB9Cg=="
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1zjdv3u6svlazlydmje2qcp44yqkt0059chz8gmyl5yrklmgv6fzq9chelu",
"new_code_id": 327,
"msg": "ewogICAgImZyb21fY29tcGF0aWJsZSI6IHt9CiAgICB9Cg=="
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron12pwnhtv7yat2s30xuf4gdk9qm85v4j3e6p44let47pdffpklcxlq56v0te",
"new_code_id": 339,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1436kxs0w2es6xlqpp9rd35e3d0cjnw4sv8j3a7483sgks29jqwgshlt6zh",
"new_code_id": 339,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1hulx7cgvpfcvg83wk5h96sedqgn72n026w6nl47uht554xhvj9nsgs8v0z",
"new_code_id": 346,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1up07dctjqud4fns75cnpejr4frmjtddzsmwgcktlyxd4zekhwecqt2h8u6",
"new_code_id": 341,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1w798gp0zqv3s9hjl3jlnwxtwhykga6rn93p46q2crsdqhaj3y4gsum0096",
"new_code_id": 342,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1pvrwmjuusn9wh34j7y520g8gumuy9xtl3gvprlljfdpwju3x7ucsj3fj40",
"new_code_id": 331,
"msg": "ewogICAgImZyb21fY29tcGF0aWJsZSI6IHt9CiAgICB9Cg=="
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1lvl674duw26psvzux5050du5kfg40kmy5z70t6am8pw6yje2wfjq66lmj2",
"new_code_id": 332,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron15m728qxvtat337jdu2f0uk6pu905kktrxclgy36c0wd822tpxcmqvnrurt",
"new_code_id": 333,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron14n7jt2qkngxtgr7dgdt50g4xn2a29llz79h9y25lrsqyxrwmngmsmt9kta",
"new_code_id": 333,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1zjd5lwhch4ndnmayqxurja4x5y5mavy9ktrk6fzsyzan4wcgawnqjk5g26",
"new_code_id": 346,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1s0fjev2pmgyaj0uthszzp3tpx59yp2p07vwhj0467sl9j343dk9qss6x9w",
"new_code_id": 335,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1f6jlx7d9y408tlzue7r2qcf79plp549n30yzqjajjud8vm7m4vdspg933s",
"new_code_id": 326,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron1atjemf7fjkkstae45q6dhuskvxlmnt9ndm05srd7jwhpxq9fhdgqgz28es",
"new_code_id": 336,
"msg": "e30K"
}
}
},
{
"wasm": {
"migrate": {
"contract_addr": "neutron13we0myxwzlpx8l5ark8elw5gj5d59dl6cjkzmt80c5q5cv5rt54qvzkv2a",
"new_code_id": 337,
"msg": "e30K"
}
}
}
]