fix: Workflow execute - prompt_id → prompt_slug
**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:
1 parent
46d39bad38
commit
af7c5ca55a
2 files changed
+10
-10
No files matched your search
@@ -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'
|
||||
|
||||
Reference in new issue
Block a user