Just hit this issue with dfx 0.16.1
. Previous deploys (using this same version of dfx) have succeeded.
Here were my steps (I’m using dfxvm):
- I briefly upgraded from dfx 0.16.1 to 0.18.0 in order to deploy a canister on the same subnet as another canister.
- I downgraded back to dfx 0.16.1, and attempted to deploy a new wasm for an existing canister. I received this error:
Failed during wasm installation call: The replica returned a replica error: reject code CanisterError, reject message Canister <canister_id> trapped explicitly: canister_pre_upgrade attempted with outstanding message callbacks (try stopping the canister before upgrade), error code None
At first I freaked out thinking my canister had trapped in the pre upgrade hook, but I don’t think this is the case based on the message. I also am using Motoko stable
for all of my types, so serialization is being done in the background by the language. Finally, none of these stable
types were changed in the upgrade…so no data was lost (I verified this)
- After ensuring nothing had been lost, I tried upgrading my canister again and received a different error this time (looks similar to others in this thread)
Failed during wasm installation call: Candid returned an error: input: 4449444c036d016c01cedfa0a804026d7b010003_204b7cb7e28621a6f1110913a33e11455d407f584d3cfe91edf6c12c75b6bd00a2204f7deaf907cea359eda7caa340b204e1558cf451da3fe7582a4cb010a57290d020f52735197797ef2a9e1d2b5d7ed8c13bcd1f41fc65a4731742c12b87f2346bc3
table: type table0 = vec table1
type table1 = record { 1_158_164_430 : table2 }
type table2 = vec nat8
wire_type: record { 1_158_164_430 : table2 }, expect_type: vec nat8
Again, both of these deployment attempts come when using dfx 0.16.1 after downgrading from dfx 0.18.0 back to 0.16.1 using dfxvm.