SkilldexAll articles

Propagate one deadline through a skill run

Share the remaining time with dependencies instead of granting every step a fresh timeout.

A workflow that gives each of five tool calls a thirty-second timeout can keep a user waiting considerably longer than the stated limit. A run-level deadline lets each step see what time remains and makes the workflow’s stopping behavior predictable.

Start from the user-visible commitment

Set a deadline for the whole request, then allocate time to the steps that matter. Include queue delay and reserve time to reconcile or explain the result. Pass a remaining budget downstream when supported, and use a local timeout otherwise. Commit to asynchronous work explicitly when synchronous completion is unrealistic.

Reserve time for uncertain writes

Ending a network wait does not prove a service stopped its operation. If a mutation outlasts a call deadline, preserve its identifier and leave room for a status check. Where the status is still unknown, report it accurately and retain a path for later reconciliation.

Test the slowest plausible route

Delay the run at different boundaries. Verify that retries do not reset the original deadline and the workflow skips optional work when little time remains. Exercise cases where the service confirms completion just after the client stopped waiting, since correctness depends on handling that late state.

Sources