Skip to content

bug(workflow-builder): archon-workflow-builder.yaml fails to load — schema example uses $other-node.output which triggers DAG validation error #1446

@tbrandenburg

Description

@tbrandenburg

Summary

The bundled archon-workflow-builder.yaml workflow fails to load with a DAG structure validation error every time Archon starts. The YAML schema reference section embedded in the generate-yaml node's prompt contains a literal template example using \$other-node.output, which the DAG validator incorrectly treats as a real inter-node dependency reference.

Error

{"level":40,"module":"workflow.loader","filename":"archon-workflow-builder.yaml","structureError":"Node 'generate-yaml' references unknown node '\$other-node.output'","msg":"dag_structure_invalid"}
{"level":40,"module":"workflow.discovery","errorCount":1,"errors":[{"filename":"archon-workflow-builder.yaml","error":"Node 'generate-yaml' references unknown node '\$other-node.output'","errorType":"validation_error"}],"msg":"app_default_workflow_errors"}

Root Cause

In .archon/workflows/defaults/archon-workflow-builder.yaml, the generate-yaml node's prompt contains a YAML schema reference with example syntax like:

          script: |
            const data = $other-node.output;
          depends_on: [other-node-id]
          when: "$<other-node>.output == 'value'"

The DAG validator in loader.ts scans all prompt text for $<nodeId>.output patterns and validates that the referenced node exists. It's matching $other-node.output inside the fenced code block / comment text as if it were a real dependency reference.

Impact

  • The workflow fails to load on every Archon startup
  • workflow list shows 1 error
  • The archon-workflow-builder workflow is unavailable

Fix

Either:

  1. Escape or rename the placeholder references in the prompt (e.g. use <nodeId>.output without the $ in the docs, or wrap in a different format)
  2. Restrict DAG $nodeId.output reference scanning to prompt:, when:, bash:, and script: field values only — not to content inside triple-backtick fenced code blocks within prompt text
  3. Add a # nocheck annotation mechanism for known-safe placeholder text

Option 2 is the most robust fix as it prevents similar issues in other workflow prompts that document the syntax.

Closes (self-contained bug — no related issue)

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Medium priority - Backlog, when time permitsarea: workflowsWorkflow enginebugSomething is broken

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions