Suddenly all our ctx.waitUntil workers are failing?
We have been using ctx.waitUntil for 2 years already with Cloudflare workers with the basic code sample below. This has always worked without any issues. Suddenly about an hour ago, all our workers with ctx.waitUntil fail with the following error message: "Can't read from request stream after response has been sent." This has never happend before and we haven't changed our code at all . Wondering if something is down with Workers? ctx.waitUntil(executeWebhookWait(request, env, pathName));
finalResponse = { success: true};
return new Response(JSON.stringify(finalResponse), {
status: 200,
headers: {
'content-type': 'application/json',
},
});
async function executeWebhookWait(request: Request, env: Env, pathName: string) {
const content = await request.text();
//DO other STUFFF
}
finalResponse = { success: true};
return new Response(JSON.stringify(finalResponse), {
status: 200,
headers: {
'content-type': 'application/json',
},
});
async function executeWebhookWait(request: Request, env: Env, pathName: string) {
const content = await request.text();
//DO other STUFFF
}
