Skip to main content
← Back to list
01Issue
BugOpenSwamp CLIPublic
AssigneesNone

Relationships

#3839 workflow validate/run say "Workflow not found" for a file that doctor workflows explains is misnamed

Opened by reset · 10/23/2026

On 20261020.024627.0-sha.26dc044f (macOS 27), a workflow saved as workflows/plain.yaml is invisible to validate and run, and the error gives no reason. In a workspace from swamp repo init --tool none: swamp workflow create plain writes workflows/workflow-plain.yaml and swamp workflow validate plain passes (Result: PASSED). After mv workflows/workflow-plain.yaml workflows/plain.yaml, the same validate prints Error: Workflow not found: plain and exits 1; swamp workflow validate workflows/plain.yaml prints Error: Workflow not found: workflows/plain.yaml; swamp workflow search --json returns "results": [].

swamp doctor workflows on the same workspace already knows the cause: ⚠ plain → Not loaded: swamp only reads files named workflow-<name>.yaml in <workspace>/workflows. Rename <workspace>/workflows/plain.yaml to workflow-<name>.yaml, or remove it if it is a stale copy of a workflow that already loads. (exit 0). The file carries name: plain, so the loader could have matched it or the error could have said why it did not.

Expected: Workflow not found for a name that matches the name: field of a YAML file under workflows/ says the file is not loaded because of its name, as doctor does, or points at swamp doctor workflows. Actual: validate and run report only Workflow not found: plain; the explanation exists only in doctor.

Steps to reproduce:

  1. mkdir ws && cd ws && SWAMP_REPO_DIR=$PWD swamp repo init --tool none
  2. swamp workflow create plain && mv workflows/workflow-plain.yaml workflows/plain.yaml
  3. swamp workflow validate plain -> Error: Workflow not found: plain
  4. swamp doctor workflows -> the Not loaded: swamp only reads files named workflow-<name>.yaml warning.

Prior art: #1468 (shipped) added the broken-file warning before Workflow not found for a file that fails to parse; #2942 (shipped) aligned doctor's file set with the loader's. Neither covers a well-formed file whose name does not match the pattern.

Suggestion: when a workflow lookup fails, run the same misnamed-file check doctor runs on the workflows/ directory and append its sentence to the error, or at least Run 'swamp doctor workflows' to see files that are not loaded.

02Bog Flow
◉OPEN○TRIAGED○IN PROGRESS○SHIPPED

Open

10/23/2026, 5:22:28 PM

No activity in this phase yet.

03Sludge Pulse

Sign in to post a ripple.