It seems after upgrading to the latest SNS version there is a lower limit on wasm size when upgrading. Is there a way to increase it for a canister with a proposal?
Trying to upgrade using quill produces error:
“the maximum canister WASM and argument size for UpgradeSnsControlledCanister is 2000000 bytes.”
Before upgrading SNS the canister was deploying. It is 2,070,589 bytes. Just 70kb above. Any suggestions on how to optimize it with moc compiler arguments or another tool are welcome. It has 3 actors inside, so that’s why it’s bigger.
Looks like the limit was introduced around 4 months ago in 7842ba0dd46bc44036448b7449c6c0ee26f0ae89.
Are you trying to upgrade to a gzipped WASM? If not, that might help.
Otherwise, it’s hard to tell how to optimize the WASM size without seeing your code. Maybe there are some dependencies / libraries that you could remove?
Pinging @ggreif and @chenyan in case there’s a better way to optimize Motoko for WASM size.