-
Notifications
You must be signed in to change notification settings - Fork 354
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wasm store failure: reference-types not enabled: zero byte expected (at offset 0x11da) #2292
Comments
Had chat with @webmaster128 . Apparently it's related to the new rustc release - they included new experimental features to the wasm , that are not supported by
Let's leave this issue open until wasmd supports latest rust. |
Latest cosmwasm/optimizer (0.16.1) also works because it contains Rust 1.81.0 |
Reference types are enabled on chains running CosmWasm 2.2 (wasmvm 2.2.x) which is the next version to be released |
I'm closing here, since this is solved on main and can be worked around as described above. |
We recently upgraded our testnet network from 1.5 to 2.1.4 and statesync is now giving this issue
|
@jhernandezb It's very curious that this is happening in state-sync. We allowed the reference types intermittently in some 2.2 release candidate versions, but had to ultimately roll back in #2311 because wasmer does not fully support reference types yet, so we have to wait for them. |
@chipshort is it possible that 1.5 allowed it to upload with recent versions of the compiler? I checked parsed_wasm.rs and it was using the default (enabled) https://github.com/CosmWasm/cosmwasm/blob/release/1.5/packages/vm/src/parsed_wasm.rs#L33 but this disabled in gatekeeper https://github.com/CosmWasm/cosmwasm/blob/release/1.5/packages/vm/src/wasm_backend/gatekeeper.rs#L22C5-L22C34 Not really sure whats the different in both settings tho. |
added a test to gatekeeper
This will panic in 2.2 (expected) but this works in 1.5 |
Are you sure? For me, this panics both on main, as well as |
Do you know which wasm file causes this problem? I'd like to do some tests with that if possible. |
You are right, let me try to get the wasm that fails during statesync |
When executing
wasm store ...
I'm receiving this error:Compilation works fine.
My deps in Cargo.toml:
rustc 1.82.0 (f6e511eec 2024-10-15)
The text was updated successfully, but these errors were encountered: