Always getting "Module hash <hash> is already installed" when trying to upgrade
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 204
- Forks
- 98
- PR merge metrics
- No merged PRs in 30d
Description
I'm attempting to upgrade a custom canister locally by calling dfx canister install --mode upgrade <canister name>
I receive a message saying that the module is already installed despite the gzipped Wasm file being different. I even get this message if I remove the real .wasm.gz file and create an empty one at the expected path using touch, or rm the file.
If I try dfx canister install --mode upgrade --upgrade-unchanged <canister name> I see traces from the upgrade hooks but the canister remains unchanged. My assets canister seems unaffected.
I'm using dfx 0.12.0-beta.1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the dfx canister install --mode upgrade <canister name> command path and reproduce the behavior with the reported 0.12.0-beta.1 setup. Compare normal upgrade handling with --upgrade-unchanged, including the case where the .wasm.gz file is removed or replaced; done means a changed module is upgraded and an unchanged module is handled consistently.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100