Skip to content

feat(workflow): add sentinel stall guard and telemetry - #17

Merged
reoring merged 4 commits into
mainfrom
feat/workflow-sentinel
Feb 26, 2026
Merged

reoring merged 4 commits into
mainfrom
feat/workflow-sentinel

Conversation

@reoring

@reoring reoring commented Feb 26, 2026

Copy link
Copy Markdown
Owner

What

Add optional Sentinel support to workflow execution:

  • Workflow-level sentinel config + step-level stall policy (parser + types)
  • Runtime stall guarding for steps and completion checks (interrupt/fail/ignore)
  • Telemetry sink that records sentinel state/events while still forwarding to the normal ExecEvent sink

Why

Detect and handle stalled steps deterministically (especially around long-running agents) and persist enough telemetry to debug/iterate on policies.

Notes

  • Includes docs under docs/features/ and new unit/AT coverage under tests/.

Testing

Not run in this environment.

Add optional Sentinel workflow config and per-step stall policies to detect stalls, record telemetry, and abort or mark steps deterministically. Includes docs and tests.
proc.kill() sends SIGTERM which may not terminate child processes spawned
via 'sh -c ...', leaving pipes open and blocking stream reads indefinitely.
Use SIGKILL (signal 9) to guarantee immediate process termination.
Use process.kill(-pid, SIGKILL) to terminate the entire process group,
ensuring child processes spawned by the shell are also killed. Falls back
to proc.kill(9) if process group kill fails.
Instead of relying solely on proc.kill() to close pipes (which may fail
when shell child processes keep pipes open), race the probe work against
a timeout promise. This guarantees run() returns within timeoutMs
regardless of process cleanup behavior.
@reoring
reoring merged commit f015460 into main Feb 26, 2026
2 checks passed
@reoring
reoring deleted the feat/workflow-sentinel branch March 1, 2026 02:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant