Subagent card stays "running" after turn_ended, transcript files split into two desynced paths, and follow-up resume/interrupt calls stall for minutes

Hey @JinFeng_Xie, thanks for the report and the timestamps.

I looked at both subagents you listed (today’s and the one from Oct 27), and they show the same pattern. The subagent finished its main work, and a few seconds later a background command it had started on its own also finished. That woke the subagent for one more short turn (the “Briefly inform the user about the task result” reply you saw). That extra turn is what landed in the top-level transcript. After it, the subagent’s original task never reported back as finished, so the card in the parent chat kept showing running until the parent’s follow-up interrupted it a few minutes later.

I’ve flagged this to the team.

In the meantime, two things should help:

  1. When you launch a background subagent, ask it to wait for any background commands it starts to finish (or stop them and wait for them to exit) before it gives its final answer. The stuck card shows up when one of those commands finishes after the subagent is already done.
  2. If a card does get stuck, ask the parent to read the subagent’s transcript files directly instead of resuming it with an interrupt. The result is in those files, and reading them skips the multi-minute wait.

To help us confirm the trigger, could you try this in a new chat?

  1. Open a new Agent chat in the Editor layout.
  2. Send: “Launch one background subagent. Its task: run sleep 20 && echo done as a background terminal command, then reply ‘started’ right away without waiting for it.”
  3. Wait about 30 seconds without sending anything.
  4. Check whether the subagent’s card in the parent chat still shows running, and whether a top-level agent-transcripts/<subagent-id>/<subagent-id>.jsonl file appeared in addition to the one under subagents/.