The cursor froze. One moment the Linux terminal was humming along, scrolling lines of output. The next, dead stop. The process? A Mercurial command pulling from a remote repository.
Engineers across different environments have started hitting the same wall: a reproducible Linux terminal bug triggered under specific Mercurial operations. At first glance, it looks like a random hang. In reality, it’s tied to how certain versions of Mercurial and the terminal environment handle unexpected output under heavy repo operations.
The symptoms are sharp and disruptive. After running a hg pull or hg update, the terminal becomes unresponsive. Input is ignored. The only way out is killing the session. Logs show no clear fatal error, only partial traces. Some builds survive; others break mid-run. It’s not a new Mercurial concept—this is an execution-level terminal handling flaw.
Here’s what’s consistent across affected systems:
- Linux shells, usually Bash or Zsh
- Medium to large repositories with many changesets
- I/O strain during remote pulls or updates
- Specific Mercurial versions compiled against older Python libraries
The cause appears to be a race condition when Mercurial’s output stream writes to a terminal that can’t keep up. Buffer overflows and deadlocks occur in rare timing conditions. On some systems, it’s less than 1 in 20 pulls. On others, nearly every pull under high network load will trigger it.