Support manually clearing the conpty buffer #1585

Open
opened 2026-01-30 22:31:10 +00:00 by claunia · 0 comments
Owner

Originally created by @zadjii-msft on GitHub (Jun 10, 2019).

From @Tyriar in microsoft/vscode#75141

This is happening because Terminal: Clear tells the frontend (the thing rendering everything) to clear, but the way that the conpty backend works is it will sometimes reprint what it thinks should be visible. Since it doesn't know about our clear it reprints the unwanted output, this doesn't happen on a regular linux/mac backend that conpty is trying to emulate.

Is there anything that can be done here to tell conpty to not reprint the screen? I suspect python.exe does not enter alt mode so I'm not sure why a reprint is necessary.

Originally created by @zadjii-msft on GitHub (Jun 10, 2019). *From @Tyriar in [microsoft/vscode#75141](https://github.com/microsoft/vscode/issues/75141)* > This is happening because Terminal: Clear tells the frontend (the thing rendering everything) to clear, but the way that the conpty backend works is it will sometimes reprint what it thinks should be visible. Since it doesn't know about our clear it reprints the unwanted output, this doesn't happen on a regular linux/mac backend that conpty is trying to emulate. > Is there anything that can be done here to tell conpty to not reprint the screen? I suspect python.exe does not enter alt mode so I'm not sure why a reprint is necessary.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#1585