-
Notifications
You must be signed in to change notification settings - Fork 305
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update the use of the prediction interface to adapt to the breaking changes introduced in PowerShell 7.2.0-preview.6 #2524
Conversation
🎉 |
After installing PSReadLine 2.2.0-beta3 and starting a new console using 7.2-Preview.5 (because 6 is unusable with old PSReadLine) the console works but calls to PSReadLine functions generally throw errors. (See below for examples)
Get-Module PSReadLine
Get-PSReadLineKeyHandlerGet-PSReadLineKeyHandler: The type initializer for 'Microsoft.PowerShell.PSConsoleReadLine' threw an exception. Get-PSReadLineOptionGet-PSReadLineOption: The type initializer for 'Microsoft.PowerShell.PSConsoleReadLine' threw an exception. No reboot was performed prior to this. |
@HerbM The 2.2.0-beta3 works with PowerShell 7.2.0-preview.6 and above versions. If you need to work with all 7.2 preview versions of PowerShell, try using 2.1.0 PSReadLine. |
Yes, PSReadline 2.2.0-beta3 does work with PowerShell 7.2.0-preview6 which I confirmed over on the PSReadline issue that I was referred to for this issue. However, it is important that one either removes PSReadLine beta before upgrading as it will make all of PowerShell useless even with -NoProfile until PowerShell is also update. FWIW: And also this is all working on Windows 11 22000.51 Thanks. |
PR Summary
Fix #2495
Update the use of the prediction interface to adapt to the breaking changes introduced in PowerShell 7.2.0-preview.6.
PredictionClient
instance to represent the client information. Today it includes the client name and the client type.PR Checklist
Microsoft Reviewers: Open in CodeFlow