theia icon indicating copy to clipboard operation
theia copied to clipboard

Closing a Terminal tab doesn't terminate the running process

Open profbbrown opened this issue 1 year ago • 1 comments

Bug Description:

If I start a long-running process in a Terminal, then close the Terminal, the process continues running the background. In other words, closing the Terminal does not appear to send the SIGHUP or SIGTERM signal to the process.

As far an I can remember, older versions of Theia's terminal (from a couple years ago) terminated the process when the tab was closed.

Steps to Reproduce:

  1. Open two Terminal tabs.
  2. In one them them, start a long-running process, such as the yes command.
  3. In the other tab, use ps -ef or top to see the process running.
  4. Close the Terminal with the long-running process.
  5. Observe that the process is still running somewhere in the background.

Additional Information

  • Operating System: Docker container running Ubuntu 22.04
  • Theia Version: 1.46.0

profbbrown avatar Feb 04 '24 07:02 profbbrown

I'm not familiar with the Theia codebase, but if this is an easy fix and someone could point me in the right direction, it's something I could try to tackle.

profbbrown avatar Mar 22 '24 20:03 profbbrown