zeroblackalpha
CDCloudflare Developers
•Created by zeroblackalpha on 7/28/2023 in #workers-help
Promise will never complete error for WASI worker
I'm writing a WASI worker using
@cloudflare/workers-wasi
and while it works locally using wrangler, I get a Promise will never complete.
error when actually deploying to cloudflare workers. I am using Wrangler 3.4.0 and Rust 1.71.0. I am building the WASI image using cargo-wasi in release mode, so wasm-opt is enabled.
worker.ts
main.rs
The code seems to fail specifically on image::load_from_memory(image_bytes)
. The include_bytes
does work as the worker runtime correctly returns the image if I try to directly print out the bytes of the image to stdout. I don't expect to have hit any aborts or panics as the image is being loaded correctly and it decodes correctly locally. Are there known behavior differences between wrangler and the worker runtime for WASI?2 replies