Context variables (REPO, BRANCH) not reliably propagated to downstream steps
Author: robobobbyCreated Feb 23, 2026Updated Feb 23, 2026
Problem
When running workflows (feature-dev, bug-fix, security-audit), the first step (planner/triager/scanner) is instructed to output REPO: and BRANCH: key-value lines. These should be parsed by parseOutputKeyValues() and merged into the run context.
However, agents don't always output these keys in the expected format. When they're missing, all downstream steps receive [missing: repo] and [missing: branch] in their resolved input templates, causing them to operate blind.
Reproduction
- Start a feature-dev workflow with a task pointing to a specific repo
- Planner agent outputs
STATUS: doneandCHANGES:but omitsREPO:andBRANCH: - All downstream steps (setup, implement, verify, etc.) receive
REPO: [missing: repo]
Suggested Fixes
- Validation gate: After the first step completes, verify that
repoandbranchexist in the run context. If missing, retry the step with a more forceful prompt, or fail with a clear error. - Task-level context: Allow
REPOandBRANCHto be specified in the task input itself (e.g. parsed from the task text), so they're available as fallback context from the start. - Template warning: When
resolveTemplate()encounters a missing key, log a warning rather than silently inserting[missing: key].
Environment
- Antfarm v0.5.1
- Observed across all 3 workflows
Source: snarktank/ralph