vscode-powershell: Errors that occur when loading profile scripts aren't written to the console

System Details

  • Operating system name and version: Windows 10 Pro
  • VS Code version: 1.11.2
  • PowerShell extension version: 0.12.2
  • Output from $PSVersionTable:
PS C:\GitHub\dbatools> code -v
1.11.2
6eaebe3b9c70406d67c97779468c324a7a95db0e
PS C:\GitHub\dbatools>
PS C:\GitHub\dbatools> $pseditor.EditorServicesVersion

Major  Minor  Build  Revision
-----  -----  -----  --------
0      12     1      0


PS C:\GitHub\dbatools>
PS C:\GitHub\dbatools> code --list-extensions --show-versions
eamodio.gitlens@3.4.5
gerane.Theme-Blackboard@0.0.2
gerane.Theme-earthsong-light@0.0.2
LaurentTreguier.vscode-simple-icons@1.2.0
michelemelluso.gitignore@1.0.1
ms-mssql.mssql@0.3.0
ms-vscode.PowerShell@0.12.2
ms-vscode.wordcount@0.1.0
RolandGreim.sharecode@0.4.0
sensourceinc.vscode-sql-beautify@0.0.4
Shan.code-settings-sync@2.6.2
swyphcosmo.spellchecker@1.2.13
tinaciousdesign.theme-tinaciousdesign@0.2.4
Tyriar.theme-sapphire@0.1.0
PS C:\GitHub\dbatools>
PS C:\GitHub\dbatools> $PSVersionTable

Name                           Value
----                           -----
PSVersion                      5.1.14393.1066
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.14393.1066
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

Issue Description

Running VS Code the initial terminal that is started for PowerShell showing as “1: PowerShell Integrated Console” does not load my user profile. This is with powershell.enableProfileLoading set to true.

Although if I start a new terminal for PowerShell I can see that my profile does get loaded.

Attached Logs

Logs.zip

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 36 (18 by maintainers)

Commits related to this issue

Most upvoted comments

Hey Shawn, it turns out that errors that occur while loading your profile script aren’t currently being written to the console. I can confirm that profile.ps1 does get loaded so you’ve probably just got an error in that profile that isn’t showing up in the console. I’m fixing the error writing issue for tomorrow’s update.