Skip to content

Accept multiple suggested corrections from PSScriptAnalyzer #2076

Open
@mcgurdan

Description

@mcgurdan

VSCode seems to be bomb out if a diagnostic records have multiple elements within it's SuggestedCorrections property; despite the property being specified as plural and of type ObjectModel.Collection containing [PowerShell.ScriptAnalyzer.Generic.CorrectionExtent].

This almost seems like a bug, but maybe it was just overlooked as generally there is only a single suggested correction (if any). I am currently implementing many custom rules which should always contain a suggested correction that suppresses the diagnostic record and if applicable, the fix that can be applied.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions