Open MoSkinny opened 5 days ago
I'd take a look at the documentation on language modes and verify you're running in Full Language Mode with $ExecutionContext.SessionState.LanguageMode
. I wouldn't expect any PS extension to work under Constrained or Restricted as it dampens their access to .NET classes and a lot of features aside from the most basic constants and automatic variables and keywords.
I've updated to the latest version of visual studio 2022 (17.12.1) but continue to get this error occasionally when I open a new instance of visual studio. Also Visual Studio will freeze and lag and then the performance monitor suggests that I disable the extension with the message "Visual Studio stopped responding for 11 seconds. Disabling the extension PowerShell Tools for Visual Studio 2022 2024.7.0 might help"
Has this been observed by others and is there a fix?
PowerShell Tools for Visual Studio Error
Failed to initialize PowerShell Tools for Visual StudioSystem.Exception: PowerShell Tools for Visual Studio does not support constrained language module. at PowerShellTools.HostService.ServiceManagement.Debugging.PowerShellDebuggingService.InitializeRunspace(Int32 processId, PSHost psHost, Boolean sta) at PowerShellTools.ServiceManagement.ConnectionManager.OpenClientConnection() at PowerShellTools.PowerShellToolsPackage.d45.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at PowerShellTools.PowerShellToolsPackage.d 40.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at PowerShellTools.PowerShellToolsPackage.d__32.MoveNext()
OK