Skip to content

Internal error when expanding auto variable holding Linq.GroupBy result. #4174

Closed
PowerShell/PowerShellEditorServices
#1975
@kborowinski

Description

@kborowinski

Prerequisites

  • I have written a descriptive issue title.
  • I have searched all open and closed issues to ensure it has not already been reported.
  • I have read the troubleshooting guide.
  • I am sure this issue is with the extension itself and does not reproduce in a standalone PowerShell instance.
  • I have verified that I am using the latest version of Visual Studio Code and the PowerShell extension.
  • If this is a security issue, I have read the security issue reporting guidance.

Summary

Auto variable of type GroupedEnumerable<int, bool> fails on expansion in Variables panel with internal error:
image

PowerShell Version

Name                           Value
----                           -----
PSVersion                      7.2.6
PSEdition                      Core
GitCommitId                    7.2.6
OS                             Microsoft Windows 10.0.19044
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0, 5.0, 5.1.10032.0, 6.0.0, 6.1… 
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

Visual Studio Code Version

1.72.0-insider
cfc01197555cb14a0d2d3463b331ce41de5733be
x64

Extension Version

Steps to Reproduce

  1. Start debugging following script:
[int[]]$a = 1..100
$b = [Linq.Enumerable]::GroupBy($a, [Func[int, bool]]{if ($args[0] % 3) {$false} else {$true}})
$b.Count
  1. Try to expand $b variable in Variables panel view

Visuals

Animation

Logs

1663251725-e5f15643-1440-4168-a26a-5c23a0f319ce1663251721624.zip

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions