Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem: Interchain accounts are not enabled in chain-main #732

Merged

Conversation

devashishdxt
Copy link
Collaborator

Solution: Enable interchain accounts in app.go and add an upgrade handler

Solution: Enable intterchain accounts in `app.go` and add an upgrade handler
@codecov
Copy link

codecov bot commented Mar 17, 2022

Codecov Report

Merging #732 (3981db4) into master (7dc44f8) will increase coverage by 0.43%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##           master     #732      +/-   ##
==========================================
+ Coverage   20.60%   21.03%   +0.43%     
==========================================
  Files          76       89      +13     
  Lines        9989    10226     +237     
==========================================
+ Hits         2058     2151      +93     
- Misses       7465     7599     +134     
- Partials      466      476      +10     
Flag Coverage Δ
integration_tests 18.41% <ø> (-1.54%) ⬇️
unit_tests 7.48% <0.00%> (-0.04%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
app/app.go 6.52% <0.00%> (+1.91%) ⬆️
x/icaauth/keeper/keeper.go 19.44% <0.00%> (ø)
x/icaauth/module_ibc.go 8.33% <0.00%> (ø)
x/icaauth/client/cli/tx_submit_tx.go 38.23% <0.00%> (ø)
x/icaauth/client/cli/tx.go 100.00% <0.00%> (ø)
x/icaauth/keeper/msg_server_submit_tx.go 0.00% <0.00%> (ø)
...uth/client/cli/query_interchain_account_address.go 26.31% <0.00%> (ø)
x/icaauth/keeper/msg_server_register_account.go 0.00% <0.00%> (ø)
x/icaauth/client/cli/tx_register_account.go 29.41% <0.00%> (ø)
x/icaauth/module.go 76.00% <0.00%> (ø)
... and 8 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7dc44f8...3981db4. Read the comment docs.

app/app.go Outdated Show resolved Hide resolved
@devashishdxt devashishdxt requested a review from tomtau March 17, 2022 04:43
Copy link
Contributor

@tomtau tomtau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the app wiring seems all right

app/app.go Show resolved Hide resolved
app/app.go Outdated
Comment on lines 537 to 539
"/cosmos.authz.v1beta1.MsgExec",
"/cosmos.authz.v1beta1.MsgGrant",
"/cosmos.authz.v1beta1.MsgRevoke",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe remove authz and feegrant "/cosmos.staking.v1beta1.MsgCreateValidator", "/cosmos.vesting.v1beta1.MsgCreateVestingAccount", and "/cosmos.staking.v1beta1.MsgEditValidator"....
they seem a bit esoteric for interchain accounts?

and maybe add Nft transfer? it could be potentially interesting e.g. if a Nft is owned by an interchain account that corresponds to a smart contract on Cronos?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

app/app.go Outdated
@@ -478,7 +575,9 @@ func New(
}

if upgradeInfo.Name == planName && !app.UpgradeKeeper.IsSkipHeight(upgradeInfo.Height) {
storeUpgrades := storetypes.StoreUpgrades{}
storeUpgrades := storetypes.StoreUpgrades{
Added: []string{icacontrollertypes.StoreKey, icahosttypes.StoreKey},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the ica auth module doesn't need to be added?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ica auth module does not access the store. Anyway, I've added it to the store upgrades just to be safe.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and it doesn't have any params etc., so no need to initialize anything in the upgrade handler?
or should that 5minute timeout be a param?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't have any params right now. But, it's a good idea to move default timeout duration to params. I'll do that in future PR.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added an option here: #731 (comment)

@devashishdxt devashishdxt requested a review from tomtau March 17, 2022 08:04
Copy link
Contributor

@tomtau tomtau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@calvinaco mentioned it may also be good to add minting/burning NFTs or perhaps denom issue?

@devashishdxt
Copy link
Collaborator Author

@calvinaco mentioned it may also be good to add minting/burning NFTs or perhaps denom issue?

Ok. I'll keep #726 open until we've reached a conclusion on this.

@devashishdxt devashishdxt merged commit 67b2668 into crypto-org-chain:master Mar 17, 2022
@devashishdxt devashishdxt deleted the ica-upgrade-handler branch March 17, 2022 08:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants