Cloudflare Developers

CD

Cloudflare Developers

Welcome to the official Cloudflare Developers server. Here you can ask for help and stay updated with the latest news

Join

Is it possible to use WebSocket clients in workers?

Is it possible to use new WebSocket(url) and connect to an external websocket server with a worker?

CRON Trigger execution time limit for Workers Paid?

I'm on the Worker's Paid plan and I can't wrap my head around the documentation regarding CRON limits. Do I fall under the Standard row?...
No description

Debugging Workers Memory Usage

Hi all, I'm working on a fun project in which I'm using Workers to accept a POST request of some TSX code, and then it will use esbuild-wasm to build and bundle it, then respond with an HTML and the bundle JS inline. I have it working already with minimal code (ie. POSTing only a couple of lines of code) but when I try to give it say, a page to render, it fails with memory limit exceeding. I understand this might be a bit overkill for 128MB of memory in Workers, but ideally, I don't want to manage any infrastructure, so I would hope I can get this working on Workers. I am already using paid Workers, so hence why I am able to deploy (since esbuild-wasm alone is huge)....

When can we expect WebGPU to work in prod?

It asys this in the docs (The WebGPU API is currently only available in local development. You cannot yet deploy Durable Objects to Cloudflare that rely on the WebGPU API.) but it has almost been a year since the announcement. Can we use WebGPU in prod yet?...

#parallel request

#request-cancelled am making three #parallel request to work api. Sometimes one of the Calls goes into a pending state before it is cancelled. Sometime it is just cancelled. I am not sure what is going on, all the request have to go through an Auth middleware that modifies the request object to attach additional information that is then available to the controller. The Auth middleware interacts with a self managed Postgres db....

Limits for WebSockets Worker

I have a worker multiplexing 2-3 TCP sockets over a single long-lived websocket so I can use a WASM HTTP & TLS client on a frontend to perform some API requests cross-origin securely. I am getting close to the regular Workers CPU time limit and haven't recieved any warnings so was wondering if Workers that use WebSockets have different limits. Is this true?

check if fetch request returned a cached response?

In a worker if I have a fetch request: ```js const response = await fetch('...', { // ......

Worker returning 522 for custom domains

just created 2 cloudflare workers from the dashboard. then created 2 custom domains, both of the custom domains report as active. Click the link, instant 522. If I access the worker from the workers.dev trigger the worker responds correctly. I tried 2 separate domains within my account. I also re-created the worker and 2 different custom domains with that new worker as well, same result. The current cloudflare status issues don't seem to be related to this....

s3

Unable to add a fine-tune. Error: https://developers.cloudflare.com/workers-ai/tutorials/fine-tune-models-with-autotrain ``` FILE_PARSE_ERROR: 'file' should be of valid safetensors type [code: 1000], quiting......

npm run start returns Error: write EOF

Trying to set up a brand new wrangler worker, and setup and deployment both work, but the node server won't start on my machine. When try running it, it returns this (image attatched) I've wiped node and reinstalled it but Im' still getting this error. (Windows 10)...
No description

my deploy is do not make

i have a app created with cloudflare, with nodejs. Local is ok, but when I make deploy is error.
No description

dev branches blocking prod deployments

something that seems like a bug to me is that it looks like the deployments to dev & prod are in the same queue, so you can't deploy to dev & prod at the same time. this seems like a bug because if i have a team of people making changes simultaneously, there are potentially many ongoing dev deployments, and it doesn't make sense for those to be in the same queue as a prod deployment....

Service Workers and Typescript

Hello! I'm trying to call worker B from worker A. I've set up everything as described in the docs (https://developers.cloudflare.com/workers/runtime-apis/bindings/service-bindings/) and the calls work, but receive Typescript errors:...

Retrospectively adding Cloudflare Workers to an existing JS Framework project

Absolute newbie here. I have an existing Sveltekit project which was created using
npm create svelte@latest my-app
npm create svelte@latest my-app
, however I now want to add Cloudflare services such as D1 and R2, retrospectively to the existing Sveltekit project. I'm aware of Cloudflare C3
npm create cloudflare@latest
npm create cloudflare@latest
to create a new Cloudflare application which creates my Worker to interact with D1 and R2, however how do I add the Worker, using best practices, to my existing Sveltekit project? Hopefully this is a simple query however couldn't find any help in the docs or google....

Bcrypt on Cloudflare Workers

I originally sent this in #coding-help but I think this is a better channel... How can I hash data using Bcrypt on Cloudflare Workers? (I'm using Wrangler CLI with NodeJS compatibility fyi) I managed to do SHA-256 (with my own salting system by concatenating the salt to the password before hashing) using the NodeJS crypto.subtle module, which is provided by Cloudflare Workers with node compatibility....

workers dont see my R2

hey, so workers dont see my R2 for some reason. here's my simple setup: ```...

AstroJs Site Setup

Hello i am trying to setup a astrojs site with cloudflare workers as my site has javascript that runs client side that is not supported on pages. I am able to get my site up and running on cloudflare workers but the issue is that none of the css or images and even some of the javascript is not accessible or give a error code of 500 https://kiwihostingnet.splitgaming101yt.workers.dev/ is the current site i am testing it on and i just cant seem to get any of the assets to work properly they do all...

Dynamic dispatch worker call multiple user workers?

Can I call multiple user workers from a dynamic dispatch worker in a single request? And if so, how would that be billed?

Cloudflare warp not working

not priave Hey for some reason cloudflare warp doesnt work when i click connect it just says your internet is