Skip to content

Remove-Item: potential v6 regression on path like Function:\Global:* #4330

@nightroman

Description

@nightroman

Steps to reproduce

    # works
    $null = New-Item Function:\Global:Test-Me -Value '"Test-Me1"'
    Test-Me

    # works
    Set-Item Function:\Global:Test-Me -Value '"Test-Me2"'
    Test-Me

    # works in v2-v5, fails in v6
    Remove-Item Function:\Global:Test-Me

Expected behavior

Remove-Item Function:\Global:Test-Me removes the specified global function in v6,
like it does in v2-v5.

Actual behavior

Remove-Item Function:\Global:Test-Me fails in v6:

    Remove-Item : The given path's format is not supported.

Environment data

    Name                           Value
    ----                           -----
    PSVersion                      6.0.0-beta
    PSEdition                      Core
    GitCommitId                    v6.0.0-beta.4
    OS                             Microsoft Windows 10.0.10586
    Platform                       Win32NT
    PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
    PSRemotingProtocolVersion      2.3
    SerializationVersion           1.1.0.1
    WSManStackVersion              3.0

Metadata

Metadata

Assignees

Labels

Issue-BugIssue has been identified as a bug in the productResolution-FixedThe issue is fixed.WG-Engine-Providersbuilt-in PowerShell providers such as FileSystem, Certificates, Registry, etc.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions