You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to use the Observe SDK in cloudflare workers, there is an error:
[wrangler:err] TypeError: wasm.__wbindgen_add_to_stack_pointer is not a function
at demangle (/home/nilslice/Projects/dylibso/workers-wasm-observability/node_modules/@dylibso/observe-sdk-honeycomb/dist/esm/index.js:2204:10)
at null.<anonymous> (/home/nilslice/Projects/dylibso/workers-wasm-observability/node_modules/@dylibso/observe-sdk-honeycomb/dist/esm/index.js:2293:27)
at [object Object]
at SpanCollector.setNames (/home/nilslice/Projects/dylibso/workers-wasm-observability/node_modules/@dylibso/observe-sdk-honeycomb/dist/esm/index.js:2292:18)
at HoneycombAdapter.start (/home/nilslice/Projects/dylibso/workers-wasm-observability/node_modules/@dylibso/observe-sdk-honeycomb/dist/esm/index.js:3898:21)
at Object.fetch (/home/nilslice/Projects/dylibso/workers-wasm-observability/src/worker.ts:38:38)
at async jsonError (/home/nilslice/Projects/dylibso/workers-wasm-observability/node_modules/wrangler/templates/middleware/middleware-miniflare3-json-error.ts:22:10)
[wrangler:inf] POST / 500 Internal Server Error (44ms)
From my investigation, it seems like Cloudlfare Workers doesn't support loading wasm modules from a Base64 string: cloudflare/workers-sdk#1366 (comment)
Which is what we are doing in the published npm pacakges: (look for var modsurfer_demangle_bg_default = __toBinary("AGFzbQEAAAABngEUYAJ/fwF).
Please note that we are using this pattern here too, but it seems like the build process encodes the binary during bundling. So we probably need to change the build process to fix this
The text was updated successfully, but these errors were encountered:
When trying to use the Observe SDK in cloudflare workers, there is an error:
From my investigation, it seems like Cloudlfare Workers doesn't support loading wasm modules from a Base64 string: cloudflare/workers-sdk#1366 (comment)
Which is what we are doing in the published npm pacakges: (look for
var modsurfer_demangle_bg_default = __toBinary("AGFzbQEAAAABngEUYAJ/fwF
).Repro
https://github.com/dylibso/workers-wasm-observability
Workaround
I manually patched the problematic code like so:
Please note that we are using this pattern here too, but it seems like the build process encodes the binary during bundling. So we probably need to change the build process to fix this
The text was updated successfully, but these errors were encountered: