Does the Worker you deploy bind to it? Show your code.
Does the Worker you deploy bind to it? Show your code.



[[workflows]] to my toml file?isolatedStorage otherwise it was complaining about not being able to find my imported Workflow class to bind.workerd/jsg/util.c++:320: error: e = kj/table.c++:49: failed: inserted row already exists in table
singleWorkfer: true got it working, so it must be that the workflows each spin up their own worker, and try to initialize something for each test?

createBatch to do 100 at a time within each of the initial 31. The total amount gets queued up very quickly. The graph above is the steps processing inside those from my understanding. ratelimit and a workflow worker?smart placement)



(workflow.not_found) Provided Workflow does not exist in production.env.WORKFLOW.get(id)? Error: instance.not_found). I've been unable to find a pattern for repro, except that it seems the codepath that invokes the workflow can successfully call get(id) later, even in a different instance of the worker; whereas some other codepath will always get instance.not_found. I'm using the same binding for the same worker with the same workflow id.name = "docpad-session-init"
main = "src/index.ts"
compatibility_date = "2024-10-22"
compatibility_flags = ["nodejs_compat"]
[[workflows]]
binding = "DOCPAD_SESSION_INIT"
name = "docpad-session-init"
class_name = "DocpadSessionInit"import { defineWorkersConfig } from '@cloudflare/vitest-pool-workers/config';
export default defineWorkersConfig({
test: {
poolOptions: {
workers: {
isolatedStorage: false,
wrangler: { configPath: './wrangler.toml' },
},
poolMatchGlobs: [],
},
maxConcurrency: 1,
},
})import { createExecutionContext } from "cloudflare:test";
import { describe, it, expect } from "vitest";
describe("test", () => {
it('test', () => {
// referencing something from cloudflare:test
const ctx = createExecutionContext()
expect(2).toBe(2)
})
})// elsewhere, as a helper - e.g. on the Workflow class
async function getDB(db, this.env) {
if (!db) {
db = // create a new connection
}
return db
}[[unsafe.bindings]]
name = "RATE_LIMIT_MEASUREMENT_GUEST"
type = "ratelimit"
namespace_id = "1000"
simple = { limit = 3, period = 60 }export default class WorkflowsService extends WorkerEntrypoint<CloudflareEnv> {
// ...
async createWorkflow(payload: Params) {
// check if the user has exceeded the limit
const RATE_LIMITER = this.env.RATE_LIMIT_MEASUREMENT_GUEST;
const { success } = await RATE_LIMITER.limit({
key: payload.userIdOrIpAddress,
});
// success locally works as expected but on production I can x3/x4 the limit and still success=true (all sending the exact same
// Something in one of these two steps causes the workflow to show outcome of "exception" and
// level of "error". What?
const { foo, bar } = await step.do("test", async () => {
const foo = "hello";
const bar = "world";
return {
foo,
bar,
};
});
await step.do("test", async () => {
return foo + bar;
});
// This will not cause an error...most the time...when it's the *only* step in the workflow.
await step.do("test", async () => {
return "foooo";
});workerd/jsg/setup.c++:39: fatal: V8 fatal error; location = :0; message = Missing deoptimization information for OptimizedJSFrame::Summarize.Getting User settings...
👋 You are logged in with an OAuth Token, associated with the email email@gmail.com.
┌──────────────────────────────────┬──────────────────────────────────┐
│ Account Name │ Account ID │
├──────────────────────────────────┼──────────────────────────────────┤
│ myemail@gmail.com's Account │ xbc │
└──────────────────────────────────┴──────────────────────────────────┘
🔓 Token Permissions: If scopes are missing, you may need to logout and re-login.
Scope (Access)
- account (read)
- user (read)
- workers (write)
- workers_kv (write)
- workers_routes (write)
- workers_scripts (write)
- workers_tail (read)
- d1 (write)
- pages (write)
- zone (read)
- ssl_certs (write)
- ai (write)
- queues (write)
- pipelines (write)
- secrets_store (write)
- offline_access
🎢 Membership roles in "email@gmail.com's Account": Contact account super admin to change your permissions.
- Super Administrator - All Privileges
error: Recipe `deploy` failed on line 10 with exit code 1
`(workflow.not_found) Provided Workflow does not existenv.WORKFLOW.get(id)Error: instance.not_foundget(id)instance.not_found