{"record":{"id":"506a8cd6054fb168","repo":"langgenius/dify","slug":"workflow-draft-was-modified-in-another-tab-reload","errorCode":null,"errorMessage":"Workflow draft was modified in another tab; reload required.","messagePattern":"Workflow draft was modified in another tab; reload required\\.","errorType":"exception","errorClass":"WorkflowApplyHashCollisionError","httpStatus":null,"severity":"error","filePath":"web/app/components/workflow/workflow-generator/apply.ts","lineNumber":190,"sourceCode":"  }\n\n  try {\n    await syncWorkflowDraft({\n      url,\n      params: {\n        graph,\n        features: existing?.features ?? {},\n        conversation_variables: existing?.conversation_variables ?? [],\n        // Field is accepted by the backend but not typed in the Pick<> shape of\n        // ``syncWorkflowDraft``'s params — spread it in so it reaches the wire.\n        ...(existing?.hash ? { hash: existing.hash } : {}),\n      } as Parameters<typeof syncWorkflowDraft>[0]['params'],\n    })\n  } catch (e) {\n    // 409 → draft was edited in another tab between our fetch and sync.\n    // Translate the raw Response rejection into a typed error so the caller\n    // can show a Reload affordance instead of a generic \"apply failed\" toast.\n    if (isHashCollisionResponse(e)) throw new WorkflowApplyHashCollisionError()\n    throw e\n  }\n}\n","sourceCodeStart":172,"sourceCodeEnd":194,"githubUrl":"https://github.com/langgenius/dify/blob/ef8544b173fd6cd7a8e71df2cab576e52bebbfbc/web/app/components/workflow/workflow-generator/apply.ts#L172-L194","documentation":"Error \"Workflow draft was modified in another tab; reload required.\" thrown in langgenius/dify.","triggerScenarios":"Thrown at web/app/components/workflow/workflow-generator/apply.ts:190 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"ef8544b173fd6cd7a8e71df2cab576e52bebbfbc","analyzedAt":"2026-08-12T05:15:17.394Z","schemaVersion":2},"datasetVersion":"2026-08-12T13:17:24.610Z"}