Terminating Exceptions not handled correctly, throw REPL ArgumentOutOfRangeException
See original GitHub issueIssue Type: Bug
Open PSES:
throw 'oops'
StackTrace
An error occurred while running the REPL loop:System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index') at System.Collections.Generic.List`1.get_Item(Int32 index) at Microsoft.PowerShell.EditorServices.Utility.PSCommandExtensions.MergePipelineResults(PSCommand psCommand) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Utility\PSCommandExtensions.cs:line 59 at Microsoft.PowerShell.EditorServices.Utility.PSCommandExtensions.AddOutputCommand(PSCommand psCommand) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Utility\PSCommandExtensions.cs:line 45 at Microsoft.PowerShell.EditorServices.Services.PowerShell.Execution.SynchronousPowerShellTask`1.ExecuteNormally(CancellationToken cancellationToken) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Execution\SynchronousPowerShellTask.cs:line 106 at Microsoft.PowerShell.EditorServices.Services.PowerShell.Execution.SynchronousPowerShellTask`1.Run(CancellationToken cancellationToken) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Execution\SynchronousPowerShellTask.cs:line 55 at Microsoft.PowerShell.EditorServices.Services.PowerShell.Execution.SynchronousTask`1.ExecuteSynchronously(CancellationToken executorCancellationToken) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Execution\SynchronousTask.cs:line 92--- End of stack trace from previous location ---
at Microsoft.PowerShell.EditorServices.Services.PowerShell.Execution.SynchronousTask`1.get_Result() in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Execution\SynchronousTask.cs:line 60 at Microsoft.PowerShell.EditorServices.Services.PowerShell.Execution.SynchronousTask`1.ExecuteAndGetResult(CancellationToken cancellationToken) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Execution\SynchronousTask.cs:line 109 at Microsoft.PowerShell.EditorServices.Services.PowerShell.Host.PsesInternalHost.InvokePSCommand[TResult](PSCommand psCommand, PowerShellExecutionOptions executionOptions, CancellationToken cancellationToken) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Host\PsesInternalHost.cs:line 364 at Microsoft.PowerShell.EditorServices.Services.PowerShell.Host.PsesInternalHost.InvokePSCommand(PSCommand psCommand, PowerShellExecutionOptions executionOptions, CancellationToken cancellationToken) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Host\PsesInternalHost.cs:line 368 at Microsoft.PowerShell.EditorServices.Services.PowerShell.Host.PsesInternalHost.InvokeInput(String input, CancellationToken cancellationToken) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Host\PsesInternalHost.cs:line 681 at Microsoft.PowerShell.EditorServices.Services.PowerShell.Host.PsesInternalHost.DoOneRepl(CancellationToken cancellationToken) in C:\Users\JGrote\Projects\PowerShellEditorServices\src\PowerShellEditorServices\Services\PowerShell\Host\PsesInternalHost.cs:line 643
Details
Extension version: 2021.11.0 VS Code version: Code - Insiders 1.63.0-insider (a7104f13ff61bcd9f4c827d8fe3c0d27bb479fd8, 2021-11-08T05:14:49.440Z) OS version: Windows_NT x64 10.0.22000 Restricted Mode: No
System Info
Item | Value |
---|---|
CPUs | AMD Ryzen 7 4700U with Radeon Graphics (8 x 1996) |
GPU Status | 2d_canvas: enabled gpu_compositing: enabled multiple_raster_threads: enabled_on oop_rasterization: enabled opengl: enabled_on rasterization: enabled skia_renderer: enabled_on video_decode: enabled vulkan: disabled_off webgl: enabled webgl2: enabled |
Load (avg) | undefined |
Memory (System) | 15.36GB (3.63GB free) |
Process Argv | –file-uri file:///c%3A/Users/JGrote/Projects/vscode-powershell/extension-dev.code-workspace --crash-reporter-id 4453efaa-0821-4555-88e2-3de8bad9109e |
Screen Reader | no |
VM | 0% |
A/B Experiments
vsliv695:30137379
vsins829:30139715
vsliv368cf:30146710
vsreu685:30147344
python383:30185418
vspor879:30202332
vspor708:30202333
vspor363:30204092
pythontb:30258533
pythonptprofiler:30281269
vshan820:30294714
pythondataviewer:30285072
vscod805:30301674
pythonvspyt200:30323110
vsccppwt:30382699
bridge0708:30335490
pygetstartedt2:30353727
bridge0723:30353136
pythonrunftest32:30365365
pythonf5test824:30361779
javagetstartedt:30350119
pythonvspyt187:30365360
pydsgst2:30361790
vsaa593:30376534
vsc1dsc:30394499
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:8 (1 by maintainers)
Top Results From Across the Web
Azure AD Connect - after uninstall cannot configure and install ...
ThrowArgumentOutOfRangeException (ExceptionArgument argument ... [10:50:05.651] [ 25] [ERROR] A terminating unhandled exception occurred.
Read more >Exceptions in C# - Replit
Here's an example: Since this code causes an exception, it will not run. In this case, the statement contains which means that it...
Read more >Apply Your Knowledge | Error Handling for the User Interface
When the record in the source data file is not in the required format, the application needs to throw a custom exception. You...
Read more >Zero-overhead deterministic exceptions: Throwing values
“throwing logic error type exceptions… is not recoverable… ... sistent and correct error handling when given a single consistent method of ...
Read more >Discuss Factorial - Codewars
But, I don't know the concept of exception well. In a small part of the tests it says "Should throw error". I wrote...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thanks for identifying and providing the fix for this @JustinGrote!
Mistake. Reopened 😃