fix-failed-upstream

Fix: failed upstream task must block downstream

Metadata

Statusdone
Assignedagent-980
Agent identityf51439356729d112a6c404803d88015d5b44832c6c584c62b96732b63c2b0c7e
Modelclaude:sonnet
Created2026-04-28T22:23:52.061261376+00:00
Started2026-04-28T22:32:50.345779240+00:00
Completed2026-04-28T22:51:26.560481093+00:00
Tagsbug,fix,deps, eval-scheduled
Eval score0.93
└ blocking impact0.90
└ completeness1.00
└ coordination overhead0.95
└ correctness0.96
└ downstream usability0.85
└ efficiency0.86
└ intent fidelity0.93
└ style adherence0.96

Description

Description

bug-failed-upstream-treated-as-satisfied.md: dependency resolution currently treats failed upstream as satisfied — downstream tasks transition to ready and the dispatcher spawns agents against missing/broken artifacts. Confirmed in session: 3 synthesis tasks went ready after their 2 audit upstreams hit failed. After wg retry flipped failed → open, the syntheses correctly transitioned to blocked, proving the inversion.

Full details at: /home/erik/workgraph/bug-failed-upstream-treated-as-satisfied.md

Fix scope

Option A from the bug doc: in dependency resolution, treat failed as blocking. Downstream is ready iff ALL upstream are done (not done OR failed).

Out of scope for this task (defer to follow-up if needed):

  • Option B (--allow-failed-upstream per-edge flag)
  • Option C (wg unblock <task> --despite-failed-upstream operator override)

Both are reasonable additions but the safe default — failed blocks — should ship first.

Validation

  • Failing test written first (TDD): tests show downstream is blocked when upstream is failed
  • Implementation: wg ready and wg list correctly show downstream as blocked (not ready) when any upstream is in failed state
  • After wg retry of upstream (failed → open), downstream remains blocked (open upstream is still blocking) — preserves existing correct behavior
  • After upstream becomes done, downstream transitions to ready
  • cargo build + cargo test pass with no regressions
  • Permanent smoke scenario added under tests/smoke/scenarios/ that exercises this — owners list includes this task id (per CLAUDE.md grow-only smoke policy)
  • cargo install --path . was run before claiming done

Depends on

Required by

Log