awaitCallee (internal/domain/workflow/workflow_call.go) fails the parent stage on the first CallStatus error, even when the callee is still running. A briefly unavailable State Store -- a restart, a transport blip -- therefore kills a wait:true call whose child would have finished.
Design
Classify the read error, not the whole wait. storecontract gains ErrUnavailable, derived by staterpc's unmapError from the Unavailable gRPC code (wrapping both, so status-code readers still see it). awaitCallee retries a read that is ErrUnavailable or context.DeadlineExceeded with doubling backoff capped at callReadMaxBackoff, inside the caller's own context, and fails at once on a contract error (ErrCallNotYours, ErrCallCallerNotRunning). The child is never re-started: the call keeps the callee id it already has, so recovery starts no second child.
Acceptance criteria
Tests pin: two refused reads then an answer still yields the callee's outputs; ErrCallNotYours fails on the first read; an outage outlasting the caller's deadline returns the deadline; and a whole wait:true call step retries a refused read, starts exactly one child and closes one call step.
Close reason
Verified: fixed in code or doc/file no longer exists (see burndown 2026-10-13)
Imported from beads archie-core-bsk2 · GitHub #1549 · type bug · priority P2 · created 2026-10-08 · closed 2026-10-12
awaitCallee (internal/domain/workflow/workflow_call.go) fails the parent stage on the first CallStatus error, even when the callee is still running. A briefly unavailable State Store -- a restart, a transport blip -- therefore kills a wait:true call whose child would have finished.
### Design
Classify the read error, not the whole wait. storecontract gains ErrUnavailable, derived by staterpc's unmapError from the Unavailable gRPC code (wrapping both, so status-code readers still see it). awaitCallee retries a read that is ErrUnavailable or context.DeadlineExceeded with doubling backoff capped at callReadMaxBackoff, inside the caller's own context, and fails at once on a contract error (ErrCallNotYours, ErrCallCallerNotRunning). The child is never re-started: the call keeps the callee id it already has, so recovery starts no second child.
### Acceptance criteria
Tests pin: two refused reads then an answer still yields the callee's outputs; ErrCallNotYours fails on the first read; an outage outlasting the caller's deadline returns the deadline; and a whole wait:true call step retries a refused read, starts exactly one child and closes one call step.
### Close reason
Verified: fixed in code or doc/file no longer exists (see burndown 2026-10-13)
---
_Imported from beads `archie-core-bsk2` · GitHub #1549 · type bug · priority P2 · created 2026-10-08 · closed 2026-10-12_
sam
added the mediumbug labels 2026-10-27 13:39:38 +00:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
awaitCallee (internal/domain/workflow/workflow_call.go) fails the parent stage on the first CallStatus error, even when the callee is still running. A briefly unavailable State Store -- a restart, a transport blip -- therefore kills a wait:true call whose child would have finished.
Design
Classify the read error, not the whole wait. storecontract gains ErrUnavailable, derived by staterpc's unmapError from the Unavailable gRPC code (wrapping both, so status-code readers still see it). awaitCallee retries a read that is ErrUnavailable or context.DeadlineExceeded with doubling backoff capped at callReadMaxBackoff, inside the caller's own context, and fails at once on a contract error (ErrCallNotYours, ErrCallCallerNotRunning). The child is never re-started: the call keeps the callee id it already has, so recovery starts no second child.
Acceptance criteria
Tests pin: two refused reads then an answer still yields the callee's outputs; ErrCallNotYours fails on the first read; an outage outlasting the caller's deadline returns the deadline; and a whole wait:true call step retries a refused read, starts exactly one child and closes one call step.
Close reason
Verified: fixed in code or doc/file no longer exists (see burndown 2026-10-13)
Imported from beads
archie-core-bsk2· GitHub #1549 · type bug · priority P2 · created 2026-10-08 · closed 2026-10-12