Ctrl+C was supposed to copy. It stopped the agent instead.

All articles

You go to copy an error message out of an agent's terminal and press Ctrl+C. Nothing lands on the clipboard. Instead the agent stops mid-task, sometimes halfway through editing a file. It feels like the tool is broken. It is not. With nothing selected at the moment you pressed it, it did exactly what a terminal does with that key.

Why Ctrl+C means stop

In a terminal, Ctrl+C is not a copy command. It sends the interrupt character to the program in front of you, and the program decides what that means. For a coding agent it means: stop what you are doing. Copying with Ctrl+C is a desktop habit, and a terminal that offers it has to fit it in alongside the older meaning.

The compromise DevThrottle's terminal makes: if text is selected, Ctrl+C copies it. If nothing is selected, it interrupts. That works until the moment it does not: you click once to put focus on the window, the click clears the selection you thought you had, and the next Ctrl+C goes to the agent.

The key that never interrupts

The fix is a habit, not a setting. Use Ctrl+Shift+C to copy. In the DevThrottle Director's terminal the keys behave like this on Windows and Linux:

  • Ctrl+C with text selected copies the selection and clears it.
  • Ctrl+C with nothing selected sends the interrupt, as it would in any terminal, and the agent stops.
  • Ctrl+Shift+C copies the selection, and with nothing selected it does nothing at all. It never interrupts.
  • Ctrl+V pastes.

The worst case for Ctrl+Shift+C is that nothing gets copied. The worst case for Ctrl+C is that a long piece of work stops in the middle. Only the first one is cheap.

On a Mac the split is cleaner, because the Mac already has a separate copy key. Cmd+C copies, as in every Mac app, and Ctrl+C keeps its terminal meaning: it is always the interrupt, even with text selected. Ctrl+Shift+C still copies there too, for anyone who learned it on another machine.

When you meant to stop it

Sometimes the interrupt is exactly what you want, and then it is good that the key passes straight through. Ctrl+C, Ctrl+D, Ctrl+Z and Ctrl+L, the arrows, Enter and the function keys all reach the agent as if you had started it in your own terminal. That is also how you answer the moments when the agent's tool stops and asks for a keypress: an arrow-key menu, a yes-or-no question, a pager. Click into the terminal and answer it there.

For anything longer than a keypress, there is a better place to type than the terminal. The box below it holds what you write and sends nothing until you press Send, so a stray key there cannot interrupt anything. The terminal above becomes your window onto what the agent is doing.

If the agent already stopped

What an interrupt does is up to the agent: DevThrottle passes the key through and the program decides. If the agent stopped the step and is waiting, tell it what you want, which is usually to carry on from where it was, and look at the file it was in the middle of editing before it continues.

Every terminal key and shortcut is listed on the embedded terminal page, and the box below the terminal is explained in The prompt bar is not the terminal.

Talk to usBook a 20-minute call