TravisFrank
TravisFrank
CDCloudflare Developers
Created by TravisFrank on 4/20/2024 in #workers-help
Durable Object returning 405s
The namespace ID of the affected DO is ddd97104edc9415eba92202173ff4735
9 replies
CDCloudflare Developers
Created by TravisFrank on 4/20/2024 in #workers-help
Durable Object returning 405s
@Matt I ran into this problem again yesterday when I connected to logs from the service the DO is bound to - the DO suddenly started only returning 405s. Re-deploying with wrangler deploy fixed the issue, but this is obviously a serious problem. DOs are practically unusable if I can't observe them when I'm trying to debug an issue with a customer on the line. Has this behavior been observed before? Is there anyone at CF looking into this?
9 replies
CDCloudflare Developers
Created by Evil Morty on 4/30/2024 in #pages-help
upload a file using Cloudflare Pages and SvelteKit
@Evil Morty Did this actually solve the problem for you? I'm still running into the issue of the File being converted into a string. In my case it's a PNG
4 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
I'm actually just straight up trying to use a WASM binary in a worker. I'm using MF instead of the wrangler CLI because our repo has 17 workers and I'm not about to spin up 17 separate processes, but that means I had to handle getting the binary to MF directly since there's no "magic"
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
Aha! Based on what you just described, yes, I think passing the binary directly to MF like this would be a good approach
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
I admit I don't know anything about wasm-bindgen - is it a WASM file itself? If so, what I did here would probably work
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
Victory! I had to use path.resolve to read the WASM file and convert it into a Uint8Array. Passing that as contents does the trick 🏆
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
I tried passing the Uint8Array from the copied wasm from esbuild directly as contents, but run into this guy: workerd/jsg/util.c++:291: error: e = kj/filesystem.c++:319: failed: expected parts.size() > 0 [0 > 0]; can't use ".." to break out of starting directory stack: 10f6a4b7a 10f6a3944 10f6a3f06 10defd92b 10e7bc534 10e7878da 10e3823d5 10defe915 10d4f63ea 10d4d8a74 10ced3d6b 10ceda9b4 10cedee8f 10cedd123 10cecc4b6 10cecbff7 10cecbeb4 10cecbe9c 10f6b3a2a 10f6b3e41 10f6b2228 10f6b1f65 10cebb359 /usr/lib/dyld@641e; sentryErrorContext = jsgInternalError service core:user:images: Uncaught Error: internal error
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
Ahhhhhh okay I think I'm almost there - I can pass the modules directly to modules in the API. That works great for the script (passing the esbuild output as contents), but I'm running into No such module "foo.wasm" imported from "bar" when trying to pass in the WASM. @MrBBot Any tips on how the resolution works for the path there? Or is there an easy way to pass contents? I'm running from node
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
Ah, perhaps '.wasm': 'copy'...?
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
I think '.wasm': 'file' should work, but I'm getting TypeError: Fetch API cannot load: ../../foo.wasm. Is there something special I need to do to pass the file to the Miniflare API?
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
Everything works when deployed, so this is definitely an issue with my unique local setup
14 replies
CDCloudflare Developers
Created by TravisFrank on 4/26/2024 in #miniflare
@MrBBot I'm trying to use a WASM binary
I was hoping external: ['foo.wasm'], loader: { '.wasm': 'text' }, in the esbuild.context call would do the trick, but now I'm getting TypeError: Fetch API cannot load:
14 replies