The /cosmwasm.wasm.v1.MsgInstantiateContract2 type has a FixMsg boolean that has omitempty in its go struct definition. Somewhat unintuitively, this means that whenever it is false, it should be ommitted, and whenever it is true, it should be set.
This is correctly represented by the protobuf encoder here:
but is incorrectly represented in the Amino encoder:
To fix this, I believe these changes should be made to toAmino and fromAmino respectively:
The
/cosmwasm.wasm.v1.MsgInstantiateContract2
type has aFixMsg
boolean that hasomitempty
in its go struct definition. Somewhat unintuitively, this means that whenever it isfalse
, it should be ommitted, and whenever it istrue
, it should be set.This is correctly represented by the protobuf encoder here:
but is incorrectly represented in the Amino encoder:
To fix this, I believe these changes should be made to
toAmino
andfromAmino
respectively: