My team and I are developing a comprehensive smart contract on the Concordium platform.
We are at the stage, where we wanted to deploy to the testnet. However, our smart contract size is ~150 kb, which is too large for the limit of ~65 kb.
Therefore, we tried to follow recommended steps to minify wasm, like using:
- removing unwrap and vec.push panics through rewriting our code and making a unwrap_abort function, that calls trap() instead
- using profile.release opt-levels
Though we can’t seem to get under ~98 kb, without removing essential third-party libraries like k256.
Any ideas/help of what we can do from here are appreciated!
We are considering attempting to split our contract in 2 or figure out if its possible to depend less on the library, though this is far from ideal.