langgenius/dify · error · Error

Failed to save agent composer draft.

Error message

Failed to save agent composer draft.

What it means

Error "Failed to save agent composer draft." thrown in langgenius/dify.

Source

Thrown at web/features/agent-v2/agent-detail/configure/use-agent-configure-sync.ts:154

    }) => {
      const savedDraftKey = JSON.stringify(configSnapshot)
      const saveSequence = ++nextSaveSequenceRef.current
      try {
        await saveComposerDraft({
          params: {
            agent_id: agentId,
          },
          body: {
            variant: 'agent_app',
            save_strategy: 'save_to_current_version',
            agent_soul: configSnapshot,
          },
        })
      } catch (error) {
        // Autosave is silent and keeps the local draft intact; explicit commands must stop at this boundary.
        if (!silent) {
          if (publish) throw error
          throw new Error('Failed to save agent composer draft.')
        }

        return false
      }

      applySavedDraft({
        draftBaseline,
        draftKey: savedDraftKey,
        saveSequence,
      })

      if (publish) {
        await publishAgent({
          params: {
            agent_id: agentId,
          },
          body: {},
        })

View on GitHub (pinned to ef8544b173)

When it happens

Trigger: Thrown at web/features/agent-v2/agent-detail/configure/use-agent-configure-sync.ts:154 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of langgenius/dify@ef8544b173 (2026-08-12). Data as JSON: /api/errors/c5b0125cce8d74ef. Report an issue: GitHub.