Corrupted prompt in the terminal
Prerequisites
- [X] I have written a descriptive issue title.
- [X] I have searched all open and closed issues to ensure it has not already been reported.
- [X] I have read the troubleshooting guide.
- [X] I am sure this issue is with the extension itself and does not reproduce in a standalone PowerShell instance.
- [X] I have verified that I am using the latest version of Visual Studio Code and the PowerShell extension.
- [x] If this is a security issue, I have read the security issue reporting guidance.
Summary
In the latest version (v2022.12.1) the terminal prompt is corrupted, contains some additional symbols:

In the previous version (v2022.11.0) there is no such a problem.
PowerShell Version
Name Value
---- -----
PSVersion 5.1.14409.1029
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.14409.1029
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
Visual Studio Code Version
1.74.2
e8a3071ea4344d9d48ef8a4df2c097372b0c5161
x64
Extension Version
[email protected]
Steps to Reproduce
The issue appeared after an upgrade to the latest version. Downgrading resolves the issue. No extra steps to reproduce, just open the terminal
Visuals
No response
Logs
Those are the ANSI escape codes used by VS Code's Shell Integration feature. That should work even with PowerShell 5.1, can you give more details about your environment? Can you also test the latest preview (where we updated the shell integration script)?
Important question: what version of VS Code are you running? Is shell integration working in terminals other than the Extension Terminal?
If you need to get by, you can disable the feature by setting terminal.integrated.shellIntegration.enabled to false.
Hi!
I've tested the Preview version and the issue is occurring there too.
The regular terminal is working well:

I also tried to disable other extensions to have cleaner environment, but that didn't help.
What's your setting for terminal.integrated.shellIntegration.enabled?
Default, not changed:

If you disable it, do things clear up?
Yes, disabling resolves the issue Thank you! :)
Great! I'm not certain why shell integration is failing so badly for you, but at least we've narrowed it down and can clear things up for you.