Metadata
| Status | done |
|---|---|
| Assigned | agent-980 |
| Agent identity | f51439356729d112a6c404803d88015d5b44832c6c584c62b96732b63c2b0c7e |
| Model | claude:sonnet |
| Created | 2026-04-28T22:23:52.061261376+00:00 |
| Started | 2026-04-28T22:32:50.345779240+00:00 |
| Completed | 2026-04-28T22:51:26.560481093+00:00 |
| Tags | bug,fix,deps, eval-scheduled |
| Eval score | 0.93 |
| └ blocking impact | 0.90 |
| └ completeness | 1.00 |
| └ coordination overhead | 0.95 |
| └ correctness | 0.96 |
| └ downstream usability | 0.85 |
| └ efficiency | 0.86 |
| └ intent fidelity | 0.93 |
| └ style adherence | 0.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-upstreamper-edge flag) - Option C (
wg unblock <task> --despite-failed-upstreamoperator 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 readyandwg listcorrectly show downstream asblocked(notready) when any upstream is infailedstate -
After
wg retryof upstream (failed → open), downstream remainsblocked(open upstream is still blocking) — preserves existing correct behavior -
After upstream becomes
done, downstream transitions toready - 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
- 2026-04-28T22:23:52.043168859+00:00 Task paused
- 2026-04-28T22:28:53.663180606+00:00 Task resumed
- 2026-04-28T22:29:15.855333070+00:00 Lightweight assignment: agent=Careful Programmer (f5143935), exec_mode=full, context_scope=task, reason=Careful Programmer (role=Programmer, tradeoff=Careful) is the best match: this is a correctness-critical dependency resolution bug requiring TDD, code modification, and exhaustive testing—exactly what Careful excels at.
- 2026-04-28T22:32:50.345783087+00:00 Spawned by coordinator --executor claude --model sonnet
- 2026-04-28T22:33:01.658306697+00:00 Starting implementation: read bug doc, exploring dependency resolution code
- 2026-04-28T22:34:19.077281769+00:00 Found bug: is_terminal() returns true for Done|Failed|Abandoned; all dep checks use is_terminal(). Fix: add is_dep_satisfied() returning true only for Done|Abandoned. 4 sites to fix: query.rs x3 + coordinator.rs x1.
- 2026-04-28T22:50:36.480426543+00:00 Fix complete: is_dep_satisfied() added to Status, applied to all 5 dependency resolution sites. All 2065 lib tests pass (1 pre-existing failure). Smoke scenario passes.
- 2026-04-28T22:51:02.721808851+00:00 Committed: 0e87438fc — pushed to origin wg/agent-980/fix-failed-upstream
- 2026-04-28T22:51:18.766384309+00:00 Validated: all 4 checklist items confirmed — (1) failed upstream blocks downstream, (2) retry keeps downstream blocked, (3) done upstream unblocks downstream, (4) smoke scenario passes. cargo build + cargo test pass (2065 pass, 1 pre-existing failure unrelated). cargo install --path . run.
- 2026-04-28T22:51:26.560487846+00:00 Task pending eval (agent reported done; awaiting `.evaluate-*` to score)
- 2026-04-28T22:54:15.816247279+00:00 PendingEval → Done (evaluator passed; downstream unblocks)