Tab or Pane not closing #12389

Closed
opened 2026-01-31 03:14:20 +00:00 by claunia · 3 comments
Owner

Originally created by @237dmitry on GitHub (Feb 3, 2021).

Environment

Windows Terminal Preview: Version: 1.6.10272.0 installed from Microsoft Store.
Any other software running in terminal.

Steps to reproduce

For example, you run pwsh.exe and cmd.exe in different tabs/panes and want to kill cmd.exe from pwsh.exe:

Get-Process cmd | Stop-Process # or
(Get-Process cmd).kill()  #or
taskkill /im cmd.exe /f 

The panel or tab where the cmd.exe was launched does not close after it is killed. This applies to any application and to any method of closing it. Even from the Task Manager.

#Expected behavior

The tab or panel must close when the application is stopped.

Actual behavior

The tab or the pane does not close if you close an application running in it from another one.
ss-20210204014424

Originally created by @237dmitry on GitHub (Feb 3, 2021). <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING: 1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement. 2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement. 3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number). 4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement. 5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement. All good? Then proceed! --> <!-- This bug tracker is monitored by Windows Terminal development team and other technical folks. **Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues**. Instead, send dumps/traces to secure@microsoft.com, referencing this GitHub issue. If this is an application crash, please also provide a Feedback Hub submission link so we can find your diagnostic data on the backend. Use the category "Apps > Windows Terminal (Preview)" and choose "Share My Feedback" after submission to get the link. Please use this form and describe your issue, concisely but precisely, with as much detail as possible. --> # Environment Windows Terminal Preview: Version: 1.6.10272.0 installed from Microsoft Store. Any other software running in terminal. # Steps to reproduce For example, you run pwsh.exe and cmd.exe in different tabs/panes and want to kill cmd.exe from pwsh.exe: ``` Get-Process cmd | Stop-Process # or (Get-Process cmd).kill() #or taskkill /im cmd.exe /f ``` The panel or tab where the cmd.exe was launched does not close after it is killed. This applies to any application and to any method of closing it. Even from the Task Manager. #Expected behavior The tab or panel must close when the application is stopped. # Actual behavior The tab or the pane does not close if you close an application running in it from another one. ![ss-20210204014424](https://user-images.githubusercontent.com/78153320/106819265-966a4900-668a-11eb-9fbb-b99b8f216c89.png)
claunia added the Issue-QuestionNeeds-Tag-FixResolution-Answered labels 2026-01-31 03:14:20 +00:00
Author
Owner

@DHowett commented on GitHub (Feb 3, 2021):

Set closeOnExit to always. This is working as intended: cmd effectively crashed, so Terminal leaves the pane open so you can see what happened.

@DHowett commented on GitHub (Feb 3, 2021): Set `closeOnExit` to `always`. This is working as intended: _cmd effectively crashed_, so Terminal leaves the pane open so you can see what happened.
Author
Owner

@DHowett commented on GitHub (Feb 3, 2021):

closeOnExit dictates when panes are automatically destroyed 😄

@DHowett commented on GitHub (Feb 3, 2021): `closeOnExit` dictates when panes are automatically destroyed :smile:
Author
Owner

@237dmitry commented on GitHub (Feb 3, 2021):

Thanks! Strange, but I passed by this option.

@237dmitry commented on GitHub (Feb 3, 2021): Thanks! Strange, but I passed by this option.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#12389