PowerShell / PowerShell/vscode-powershell

Clear of console and content vanishing after resize

Open
#3,970 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Area-UI Issue-Bug
Dominant language
TypeScript
Stars
1.9k
Forks
547
PR merge metrics
No merged PRs in 30d

Description

Prerequisites
  • I have written a descriptive issue title.
  • I have searched all issues to ensure it has not already been reported.
  • I have read the troubleshooting guide.
  • I am sure this issue is with the extension itself and does not reproduce in a standalone PowerShell instance.
  • I have verified that I am using the latest version of Visual Studio Code and the PowerShell extension.
  • If this is a security issue, I have read the security issue reporting guidance.
Summary

As discussed on Discord -> Problems with resize, write-progress:

ConsoleProblems

Clear-Host not working properly
Clear

Is enabled:

    "terminal.integrated.windowsEnableConpty": true,
PowerShell Version
Name                           Value
----                           -----
PSVersion                      5.1.22000.652
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.22000.652
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
Visual Studio Code Version
1.67.1
da15b6fd3ef856477bf6f4fb29ba1b7af717770d
x64
Extension Version
ms-vscode.powershell@2022.5.1
ms-vscode.powershell-preview@2022.5.1
tobysmith568.run-in-powershell@1.1.1
TylerLeonhardt.vscode-inline-values-powershell@0.0.5
Steps to Reproduce

As shown on GIFs try to do something in the console, resize, console up and down, type again, and notice how things get distorted.

Visuals

No response

Logs

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the console resize and Clear-Host behavior shown in the linked GIFs, using the reported PowerShell 5.1, VS Code 1.67.1, and extension 2022.5.1 versions with ConPTY enabled. The payload names no source files or tests, so tracing the extension's terminal handling will be necessary; done means resizing, clearing, and typing no longer distort or lose console content.

Written by the indexing model from the issue text.

Assessment

Tech stack
powershell, typescript, vscode
Domain
desktop, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.