Repository navigation
Opt-in completion wake for threads started with t3_thread_launch #15148
Replies: 3 comments
|
this would be super useful, thank you for considering 🙇 |
|
+1. Here are measurements from a workflow this would fix directly. We run a coordinator thread that starts workers with
One possible extension, not needed for the smallest version: let another thread take over as the watcher of a launched run, for example a replacement coordinator. Today, if the launching thread is gone, the signal has nowhere to go. Even just showing the watcher relationship in The smallest version proposed here (initial run only, off by default) would cover everything above except the takeover. |
|
+1 from another orchestrator setup. An Opus thread delegates coding to children, and some work needs its own top-level thread (a benchmark arm, a long job in another project). One of those launched threads finished while the parent kept waiting, and the parent only learned about it when I told it. Our workaround is a standing instruction: every brief for a |
Uh oh!
There was an error while loading. Please reload this page.
Problem
delegate_taskchildren wake their parent when they finish, but they always run in the parent's project and checkout. A thread started witht3_thread_launch(the only way to get its own worktree, or to work in another project) never notifies the thread that launched it.So an orchestrating agent has to choose: completion wake with a shared checkout, or an isolated worktree with no signal at all. With a cross-project launch there is not even a way to poll, because
t3_thread_wait/t3_thread_readare project-scoped (#15125).In practice the orchestrator ends up running a shell loop that watches for a report file or a PR, and it never learns that the launched run failed (for example a provider turn that dies during startup) unless the user tells it.
Proposal
An opt-in completion notification on
t3_thread_launch(andcreate_threads), e.g.completionWake: true:delegate_taskuses: steered into an active turn where supported, queued otherwise, replayed after restart, delivered once.t3_thread_read(which needs the launcher-scoped read from [Bug]: Threads launched into another project via t3_thread_launch can't be waited on, read, sent to, or interrupted by the launching thread #15125 for cross-project launches).This keeps launched threads ordinary top-level threads; it only adds the one-shot signal the launcher currently has to improvise.
Smallest useful version
Wake for the initial run only, default off, no change to permissions or to who may send to the launched thread.
Related
All reactions