Skip to content

Global workflows invisible to webhook commands and web UI #1138

@jonasvanderhaegen

Description

@jonasvanderhaegen

Bug

Workflows placed in ~/.archon/.archon/workflows/ (global/user scope) are not discovered by:

  1. Webhook-triggered slash commands (@archon /workflow run my-workflow via GitHub comments)
  2. Web UI (GET /api/workflows returns empty for global workflows)

The CLI and orchestrator find them correctly because they pass globalSearchPath: getArchonHome() to discoverWorkflowsWithConfig.

Root Cause

Two callers of discoverWorkflowsWithConfig don't pass globalSearchPath:

  1. packages/core/src/handlers/command-handler.ts — lines 566, 612, 807 (list, reload, run)
  2. packages/server/src/routes/api.ts — line 1770 (GET /api/workflows)

Without globalSearchPath, step 2 of discoverWorkflows (searching ~/.archon/.archon/workflows/) is skipped entirely. Only bundled defaults + repo-local .archon/workflows/ are searched.

Impact

Users who place custom workflows in the global directory (as documented) cannot trigger them via:

  • GitHub webhook comments (@archon /workflow run ... → "Workflow not found")
  • The Archon web UI (workflows tab shows empty or only bundled defaults)

Fix

PR #1136 — pass { globalSearchPath: getArchonHome() } to all 4 call sites. getArchonHome is already exported from @archon/paths and already imported in both files.

4 lines changed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High priority - Address soon, next in queuearea: handlersCommand handlerarea: serverHTTP server (packages/server) - API routes, SSE, adaptersarea: workflowsWorkflow enginebugSomething is brokeneffort/lowSingle file or function, one responsibility, isolated change

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions