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

Should add a new function for contract update (with storage migration) #4

Open
riversyang opened this issue Sep 29, 2022 · 0 comments

Comments

@riversyang
Copy link
Member

riversyang commented Sep 29, 2022

It seems the function deploy_and_init of near.rpc.Client should only be used to deploy and initialize a contract. (I also think the init function name of Octopus contracts can be fixed as new.) But when we update a contract with storage migration, it's better to perform the code deployment and migration in one transaction. Or the contract may become unavailable if the migration function fails.

I think we should add a function in cli to perform store_wasm_of_self function and then update_self function of a contract. (We can use these two function names in all Octopus contracts.)

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

No branches or pull requests

1 participant