{"record":{"id":"2d39acc7d1bd7399","repo":"windmill-labs/windmill","slug":"flow-at-path-path-doesn-t-exist","errorCode":null,"errorMessage":"Flow at path: ${path} doesn't exist","messagePattern":"Flow at path: (.+?) doesn't exist","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"frontend/src/lib/components/flows/scheduleUtils.ts","lineNumber":17,"sourceCode":"import { ScheduleService, type Schedule, type TriggersCount } from '$lib/gen'\nimport type { ScheduleTrigger } from '../triggers'\nimport type { Writable } from 'svelte/store'\nimport { writable } from 'svelte/store'\nimport { get } from 'svelte/store'\nimport { sendUserToast } from '$lib/utils'\nimport { stateSnapshot } from '$lib/svelte5Utils.svelte'\n\n// Load the schedule of a flow given its path and the workspace\nexport async function loadSchedule(path: string, workspace: string): Promise<ScheduleTrigger> {\n\tconst existsSchedule = await ScheduleService.existsSchedule({\n\t\tworkspace,\n\t\tpath\n\t})\n\n\tif (!existsSchedule) {\n\t\tthrow new Error(`Flow at path: ${path} doesn't exist`)\n\t}\n\n\tconst schedule = await ScheduleService.getSchedule({\n\t\tworkspace,\n\t\tpath\n\t})\n\n\treturn {\n\t\tsummary: schedule.summary ?? undefined,\n\t\tenabled: schedule.enabled,\n\t\tcron: schedule.schedule,\n\t\ttimezone: schedule.timezone,\n\t\targs: schedule.args ?? {}\n\t}\n}\n\nexport async function loadSchedules(\n\tforceRefresh: boolean,","sourceCodeStart":1,"sourceCodeEnd":35,"githubUrl":"https://github.com/windmill-labs/windmill/blob/e474e8803ce2ff5c2df09a58dab51d45f5c922ca/frontend/src/lib/components/flows/scheduleUtils.ts#L1-L35","documentation":"loadSchedule first checks schedule existence with ScheduleService.existsSchedule for the given workspace and path. If the backend reports no schedule exists for that flow path, it throws this error instead of fetching, surfacing that the flow (or its schedule) is missing so the caller can react rather than receive a null schedule.","triggerScenarios":"Calling loadSchedule(workspace, path) where no schedule exists for path — the existsSchedule API returned false. Despite the message wording, it is the schedule existence check that fails.","commonSituations":"Flow was deleted or renamed while a schedules list page was open; typo in the flow path; schedule was unscheduled/deleted on another tab; workspace switched so the path belongs to a different workspace.","solutions":["Verify the flow path exists in the target workspace before loading its schedule.","Refresh the schedules list after any delete/rename so stale paths are not requested.","Handle the throw in the caller by removing the stale entry from the UI list instead of retrying."],"exampleFix":"// before\nconst schedule = await loadSchedule(workspace, path)\n// after\nlet schedule\ntry {\n  schedule = await loadSchedule(workspace, path)\n} catch {\n  toast.info(`Flow ${path} no longer exists`)\n  schedules = schedules.filter((s) => s.path !== path)\n}","handlingStrategy":"try-catch","validationCode":"const exists = await ScheduleService.existsSchedule({ workspace, path })\nif (!exists) {\n  toast.info(`No schedule for ${path}`)\n  return\n}","typeGuard":null,"tryCatchPattern":"try {\n  const schedule = await loadSchedule(workspace, path)\n} catch (e) {\n  if (String(e.message).includes(\"doesn't exist\")) {\n    removeStaleScheduleEntry(path)\n    return\n  }\n  throw e\n}","preventionTips":["Refresh schedule lists after delete/rename operations.","Validate the flow path against the current workspace.","Check existence before fetching when operating on stale data."],"tags":["svelte","api","schedules","not-found"],"backgroundTag":"resource-not-found","analyzedSha":"e474e8803ce2ff5c2df09a58dab51d45f5c922ca","analyzedAt":"2026-09-03T12:38:19.024Z","contentChangedAt":"2026-09-03T12:38:19.024Z","schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}