avaer
avaer
CDCloudflare Developers
Created by avaer on 6/5/2024 in #workers-help
"internal error" calling .fetch on bound Durable Object
I'm getting this thrown when trying to call DO fetch. I think my worker is configured incorrectly. My worker code is very simple:
async function handleAgentRequest(request, env) {
const guid = env.GUID;
const id = env.AGENT.idFromName(guid);
const stub = env.AGENT.get(id);
return await stub.fetch(request);
}

export default {
async fetch(request, env, ctx) {
try {
return await handleAgentRequest(request, env);
} catch (err) {
console.warn(err.stack);
}
},
}
async function handleAgentRequest(request, env) {
const guid = env.GUID;
const id = env.AGENT.idFromName(guid);
const stub = env.AGENT.get(id);
return await stub.fetch(request);
}

export default {
async fetch(request, env, ctx) {
try {
return await handleAgentRequest(request, env);
} catch (err) {
console.warn(err.stack);
}
},
}
What are some things to check in my worker settings to debug this?
25 replies
CDCloudflare Developers
Created by avaer on 6/4/2024 in #workers-help
Workers for platforms authentication
How are users authenticated when using Workers for Platforms? Does each user need their own CloudFlare account or is is possible to support deployment on their behalf?
24 replies
CDCloudflare Developers
Created by avaer on 5/22/2024 in #workers-help
workers.api.error.internal_server
I’m getting an internal error on trying to deploy a worker module from the API: https://api.cloudflare.com/client/v4/accounts/8d093faf5772cff838a12d1c9bc87afd/workers/scripts/agent-worker-f53a7df5-550c-4af3-91a5-1ec1442c6553/content 2 { “result”: null, “success”: false, “errors”: [ { “code”: 10002, “message”: “workers.api.error.internal_server” } ], “messages”: } I have the HAR file but I’m not sure where to post it, since it contains my keys. Going through the support flow does not allow me to post a ticket, it leads me here (I am on the Pro plan). Any way to get help with this backend error? The API doesn’t tell me what I am doing wrong. Thanks!
1 replies