Skip to content

Commit f975c22

Browse files
Add known PowerShell.OnIdle event bug to troubleshooting.md (#3824)
1 parent 08693a7 commit f975c22

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

docs/troubleshooting.md

+12-1
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,17 @@ and you can ask for new features [in their repository](https://github.com/Micros
147147
- Document formatting is provided by [PSScriptAnalyzer], but there
148148
may be opportunities to improve our integration with it in the
149149
[PowerShell Extension] too.
150+
- PSReadLine throws an error ever so often - [#3701](https://github.com/PowerShell/vscode-powershell/issues/3701)
151+
- This is a known issue due to the PowerShell eventing framework running registered
152+
`OnIdle` events outside of PowerShell Editor Service's dedicated PowerShell execution
153+
pipeline. Until we can disable event registration, you will need to avoid registering
154+
events in the first place.
155+
- A known work around includes unregistering from this event.
156+
`Get-EventSubscriber -Force -SourceIdentifier PowerShell.OnIdle -EA 0 | Unregister-Event -Force`
157+
can be run manually (or added to your profile) to avoid this bug.
158+
* Related issues: [PowerShell Editor Services #1591](https://github.com/PowerShell/PowerShellEditorServices/issues/1591),
159+
[PSReadLine #3091](https://github.com/PowerShell/PSReadLine/issues/3091),
160+
[Azure PowerShell #16585](https://github.com/Azure/azure-powershell/issues/16586)
150161

151162
## Reporting an issue
152163

@@ -263,7 +274,7 @@ In some cases, getting to the bottom of a bug will require looking at the payloa
263274
```json
264275
"powershell editor services.trace.server":"verbose"
265276
```
266-
277+
267278
> NOTE: While VSCode will not recognize and highlight it, it is a valid option and enables tracer logs on the server.
268279
269280
- Restart Visual Studio Code and reproduce the issue.

0 commit comments

Comments
 (0)