fix: Workflow execute - prompt_id → prompt_slug
Deploy Development / deploy (push) Successful in 55s
Build Test / lint-backend (push) Successful in 0s
Build Test / build-frontend (push) Successful in 22s

**Problem:**
Execute-Button funktionierte, aber Ausführung scheiterte mit
"Prompt not found: none" im Analysis Node.

**Root Cause:**
Mismatch zwischen Frontend (speicherte prompt_id/UUID) und
Backend (erwartete prompt_slug/String).

Backend WorkflowNode Model (workflow_models.py:193):
  prompt_slug: Optional[str] = Field(...)

**Änderungen:**
- WorkflowEditorPage.jsx: Dropdown auf slug umgestellt
  - value: prompt_slug statt prompt_id
  - onChange: selectedPrompt.slug statt .id
  - handleNodeUpdate: prompt_slug speichern

- workflowSerializer.js: Serialization/Deserialization
  - Serialize: prompt_slug statt prompt_id
  - Deserialize: node.prompt_slug lesen

**Testing:**
- Workflow mit Analysis Node neu erstellen
- Execute-Button sollte jetzt funktionieren

Part 2 Bugfix - Workflow Execution

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
LarsandClaude Opus 4.6 committed 2026-04-09 13:59:54 +02:00
1 parent 46d39bad38
commit af7c5ca55a
2 files changed
+10 -10

No files matched your search

+2 -2
View File
@@ -21,7 +21,7 @@ export function serializeToWorkflowGraph(nodes, edges, metadata = {}) {
// Type-spezifische Felder
...(node.type === 'analysis' && {
prompt_id: node.data.prompt_id || null,
prompt_slug: node.data.prompt_slug || null,
prompt_name: node.data.prompt_name || null,
questions: node.data.questions || [],
fallback_strategy: node.data.fallback_strategy || 'conservative_skip'
@@ -78,7 +78,7 @@ export function deserializeFromWorkflowGraph(jsonbData) {
label: node.label,
...(node.type === 'analysis' && {
prompt_id: node.prompt_id,
prompt_slug: node.prompt_slug,
prompt_name: node.prompt_name || null, // Falls vom Backend mitgeliefert
questions: node.questions || [],
fallback_strategy: node.fallback_strategy || 'conservative_skip'