PowerShell

The PowerShell forum accepts bug reports as well as feedback and suggestions. For more information, check out the PowerShell Homepage

The following is a list of the states we use to track items.

status meaning
survey We saw this and we are considering it. Please upvote if it’s important to you.
needs more information We don’t understand the issue and need additional details.
investigating We are looking at this internally to understand things like: scenario, reproduction of issue, costing, or other technical details.
in queue The issue is understood and in our unprioritized backlog. Your votes will be used to drive prioritization of this work.

Please feel free to provide feedback or file bugs here.

(thinking…)

Enter your idea and we'll search to see if someone has already suggested it.

If a similar idea already exists, you can support and comment on it.

If it doesn't exist, you can post your idea so others can support it.

Enter your idea and we'll search to see if someone has already suggested it.

  • Hot ideas
  • Top ideas
  • New ideas
  • My feedback
  1. ISE Bracket Shading

    I think that the ISE should have some user-customizable options - such as bracket shading. The grey isn't quite dark enough to spot. PowerGUI's shading is significantly darker, making it easier to detect the correlating bracket.

    2 votes
    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)

      We’ll send you updates on this idea

      0 comments  ·  ISE and tooling  ·  Flag idea as inappropriate…  ·  Admin →
    • Duplicate help files in PSWorkflow module break Get-Help

      At some point in the 5.0 time period, Update-Help installed About topic files in the en-US directory for the PSWorkflow module with .txt (not .help.txt) file name extensions.

      e.g. about_Foreach-Parallel.txt

      Later, this was fixed and Update-Help installed the same help files in the same directory with the (correct) ".help.txt" file name extension.

      e.g. about_Foreach-Parallel.help.txt

      Now, the PSWorkflow\en-US directory has 9 pairs of files that are identical except for the file name extension.

      about_ActivityCommonParameters.help.txt
      about_ActivityCommonParameters.txt
      about_Checkpoint-Workflow.help.txt
      about_Checkpoint-Workflow.txt
      about_Foreach-Parallel.help.txt
      about_Foreach-Parallel.txt
      about_InlineScript.help.txt
      about_InlineScript.txt
      about_Parallel.help.txt
      about_Parallel.txt
      about_Sequence.help.txt
      about_Sequence.txt
      about_Suspend-Workflow.help.txt
      about_Suspend-Workflow.txt
      about_WorkflowCommonParameters.help.txt
      about_WorkflowCommonParameters.txt
      about_Workflows.help.txt
      about_Workflows.txt

      Get-Help should ignore the .txt files (must have changed in…

      1 vote
      Sign in
      Check!
      (thinking…)
      Reset
      or sign in with
      • facebook
      • google
        Password icon
        I agree to the terms of service
        Signed in as (Sign out)

        We’ll send you updates on this idea

        survey  ·  0 comments  ·  Documentation  ·  Flag idea as inappropriate…  ·  Admin →
      • Powershell and collections (in particular, collection of preference variables)

        I've been struggling with exporting and importing preference variables from local to remote sessions. One idea that came to me was the idea of a collection of preference variables. According to a fellow at StackOverflow, Powershell doesn't institute these kinds of collections. If this is true, I would kindly request them to be implemented.

        2 votes
        Sign in
        Check!
        (thinking…)
        Reset
        or sign in with
        • facebook
        • google
          Password icon
          I agree to the terms of service
          Signed in as (Sign out)

          We’ll send you updates on this idea

          0 comments  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →

          What are the environment variables you are interested in exporting? If it’s possible to enumerate them, then you can set them up in multiple locations.
          Take a look at the New-PSSessionConfigurationFile cmd (start with the help for it). It’s designed to enable part of the scenario you are interested in, but not sure if that is enough of what you are asking for.

        • Sort properties alphabetically

          Please make cmdlet results (e.g. Format-List) sort results automatically by properties in alphabetical order.

          Certain cmdlets do this, such as get-member. I don't understand why all cmdlets do not do this, or at least not have an option to do this.

          When I am searching for information I readily do not know (e.g. what properties are available and which values may be assigned to them), it makes it very difficult to find what I need when I have to look at a bunch of properties that are seemingly sorted in some sort of random order.

          2 votes
          Sign in
          Check!
          (thinking…)
          Reset
          or sign in with
          • facebook
          • google
            Password icon
            I agree to the terms of service
            Signed in as (Sign out)

            We’ll send you updates on this idea

            1 comment  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
          • Remember last command output eg PSLastItem - forgot to assign object to variable

            When you type in and run a cmdlet (especially one with side-effects) and forget to assign the output to a varialbe, it would be nice to be able to pick up the last output still stored in object form, from an automatic PS variable (eg PSLastItem) to feed into another command.
            Example: running Start-Process with -PassThru, then wanting the ExitCode of the result which I forgot to assign. Maybe even re-use $_ as shorthand, because we're not in the pipeline?

            2 votes
            Sign in
            Check!
            (thinking…)
            Reset
            or sign in with
            • facebook
            • google
              Password icon
              I agree to the terms of service
              Signed in as (Sign out)

              We’ll send you updates on this idea

              2 comments  ·  ISE and tooling  ·  Flag idea as inappropriate…  ·  Admin →
            • Package PowerShell Classes in a Module

              Object Oriented Programming seems to be supported now in PowerShell, but custom classes defined in modules don't seem to behave the way they should.

              There only seem to be two consistent ways to make these work when importing a module that has classes defined:
              1. Import the module, then run "using module ..." to make the classes available in the session. Alternatively, you can import the module with the using statement, but this isn't ideal (no versioning).
              2. Add the class definition file(s) to the ScriptsToProcess attribute of the module. This isn't ideal either as it runs the scripts in…

              10 votes
              Sign in
              Check!
              (thinking…)
              Reset
              or sign in with
              • facebook
              • google
                Password icon
                I agree to the terms of service
                Signed in as (Sign out)

                We’ll send you updates on this idea

                1 comment  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
              • script output incompatible

                I wrote one python script which just output on cmd, but when I run the script with it's name it opens a new python window

                script name: test.py

                script content:
                print("Content-Type: text/html\n")
                print("Hello")
                temp = raw_input()

                1 vote
                Sign in
                Check!
                (thinking…)
                Reset
                or sign in with
                • facebook
                • google
                  Password icon
                  I agree to the terms of service
                  Signed in as (Sign out)

                  We’ll send you updates on this idea

                  0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                • Don't require -LogName parameter for Write-EventLog

                  The documentation https://msdn.microsoft.com/en-us/powershell/reference/5.1/microsoft.powershell.management/write-eventlog#-logname says it's required.
                  However, the .NET framework doesn't require it (https://msdn.microsoft.com/en-us/library/system.diagnostics.eventlog.source.aspx clearly shows this in example, and the documentation says Source names must already be unique), so why does PowerShell?

                  2 votes
                  Sign in
                  Check!
                  (thinking…)
                  Reset
                  or sign in with
                  • facebook
                  • google
                    Password icon
                    I agree to the terms of service
                    Signed in as (Sign out)

                    We’ll send you updates on this idea

                    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                  • Fix imposter backslash characters in some paths.

                    I posted a question at "The Official Scripting Guys Forum!" and at the end of our thread the responding partner, jrv, recommended that I repost as a bug in your forum.

                    The issue is that under certain reproducible circumstances, including one detailed by me later in the Scripting Guys thread, path strings returned by drilling down through [AppDomain]::CurrentDomain.GetAssemblies() contain "imposter" backslash characters that cannot be parsed by Split-Path. Instead of Unicode '\' = [char]0x005C they contain Unicode "big reverse solidus" = [char]0x29F9. After his investigation, jrv suggested that the issue arises when an imported module contains a class.

                    The thread…

                    2 votes
                    Sign in
                    Check!
                    (thinking…)
                    Reset
                    or sign in with
                    • facebook
                    • google
                      Password icon
                      I agree to the terms of service
                      Signed in as (Sign out)

                      We’ll send you updates on this idea

                      2 comments  ·  Flag idea as inappropriate…  ·  Admin →
                    • Get-Content bug: A parameter cannot be found that matches parameter name 'Encoding'

                      Get-Conent with the Encoding parameter works against local file system paths such as this example:
                      Get-Content -Encoding Byte -Path C:\Users\desktop.ini

                      However, against a mapped network drive it does not:
                      Get-Content -Encoding Byte -Path I:\Users\desktop.ini
                      Get-Content : A parameter cannot be found that matches parameter name 'Encoding'.
                      At line:1 char:13
                      + Get-Content -Encoding Byte -Path I:\Users\desktop.ini

                      The issue can be re-produced against a non-existing network drive as well.
                      The behaviour is not expected and the error message is very misleading to users who don`t know what dynamic parameters is, since the same code works against a local path where -Encoding is…

                      1 vote
                      Sign in
                      Check!
                      (thinking…)
                      Reset
                      or sign in with
                      • facebook
                      • google
                        Password icon
                        I agree to the terms of service
                        Signed in as (Sign out)

                        We’ll send you updates on this idea

                        0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                      • ISE Run in isolated console

                        PowerGUI has a Run in External PowerShell Window feature, which executes the code externally, allowing parameters to be passed in, and eliminating some of the ISE quirks when testing code.
                        I think have this option (along with customizable bracket shading) would be a great ISE feature.

                        1 vote
                        Sign in
                        Check!
                        (thinking…)
                        Reset
                        or sign in with
                        • facebook
                        • google
                          Password icon
                          I agree to the terms of service
                          Signed in as (Sign out)

                          We’ll send you updates on this idea

                          0 comments  ·  ISE and tooling  ·  Flag idea as inappropriate…  ·  Admin →
                        • Support proxy of PowerShell Gallery

                          Proxy is NOT supported in PowerShell Gallery now.
                          Although the "-Proxy" option exists, it seems that it does not work effectively.
                          Please supported proxy.

                          1 vote
                          Sign in
                          Check!
                          (thinking…)
                          Reset
                          or sign in with
                          • facebook
                          • google
                            Password icon
                            I agree to the terms of service
                            Signed in as (Sign out)

                            We’ll send you updates on this idea

                            0 comments  ·  PowerShell Gallery  ·  Flag idea as inappropriate…  ·  Admin →

                            Please add some information on what you need for proxy support, and the error you are receiving.

                            The current version of the cmdlets support the ability to interact with the PS Gallery if you must go through a proxy. You can supply a proxy URI and a credential set (as a pscredential object), which should work in most cases.

                            Something you can try as a troubleshooting step is to try to navigate through the proxy to reach http://powershellgallery.com/api/v2, which is the rest endpoint for the PS Gallery. That may provide you information about the end-to-end connection through the proxy.

                          • Set the PowerShell Gallery up for Twitter Cards

                            When posting a link to a GitHub repo on Twitter, the URL is generally replaced with a Twitter summary card. This is not the case, currently, when posting links to items on the Gallery. The display of cards makes these links stand out more and (should) help with social sharing of PowerShell content.

                            4 votes
                            Sign in
                            Check!
                            (thinking…)
                            Reset
                            or sign in with
                            • facebook
                            • google
                              Password icon
                              I agree to the terms of service
                              Signed in as (Sign out)

                              We’ll send you updates on this idea

                              survey  ·  0 comments  ·  PowerShell Gallery  ·  Flag idea as inappropriate…  ·  Admin →
                            • External STDERR content displayed even with $ErrorActionPreference = 'SilentlyContinue'

                              Operating system: Windows 7
                              64 bit OS:
                              PowerShell Version: 4

                              .\Invoke-MyScript.ps1
                              When I run this from the PowerShell console, the output includes data from stderr mixed in with stdout.

                              *****
                              Contents of Invoke-MyScript.ps1
                              *****
                              $ErrorActionPreference = 'SilentlyContinue'
                              python my_python_script_prints_to_stderr.py | Out-Host
                              Write-Error "A PowerShell error!!!!!!"
                              exit $LastExitCode

                              *****
                              Contents of my_python_script_prints_to_stderr.py
                              *****
                              import warnings
                              warnings.warn("A warning on stderr", Warning, 0)

                              *****
                              Output:
                              *****
                              PS C:\temp> .\Invoke-MyScript.ps1
                              my_python_script_prints_to_stderr.py:2: Warning: A warning on stderr
                              warnings.warn("A warning on stderr", Warning, 0)
                              PS C:\temp>
                              *****
                              End Output:
                              *****

                              Notice that the PowerShell Write-Error is not displayed (as expected), but the stderr data from the…

                              1 vote
                              Sign in
                              Check!
                              (thinking…)
                              Reset
                              or sign in with
                              • facebook
                              • google
                                Password icon
                                I agree to the terms of service
                                Signed in as (Sign out)

                                We’ll send you updates on this idea

                                0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                              • Add an explicit "loop forever" syntax for loops

                                Add something like:

                                loop {

                                }

                                or

                                do {

                                } forever

                                or

                                repeat {

                                }

                                for eternal loops. The use of "while ($true) {}" is normal for experienced programmers, but it's not obvious for beginners to find, and it doesn't clearly express that it's intended to be a perpetual loop. It could instead be a conditional loop with a mistake, or (to a beginner) a loop with a condition which will end at some time they don't understand.

                                Internally, it could be translated directly to "while ($true) {}" for behaviour.

                                This comes up occasionally on the internet, people (admins rather…

                                3 votes
                                Sign in
                                Check!
                                (thinking…)
                                Reset
                                or sign in with
                                • facebook
                                • google
                                  Password icon
                                  I agree to the terms of service
                                  Signed in as (Sign out)

                                  We’ll send you updates on this idea

                                  0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                                • INPUTS and OUTPUTS section of get-help not displaying properly

                                  Problem description
                                  --------------------------
                                  INPUTS and OUTPUTS section of get-help -Full content shows some unwanted tab and new line characters for almost all cmdlets.

                                  For e.g.,

                                  get-help content with INPUTS and OUTPUTS section highlighted where extra new line and tab comes for every cmdlet help content.


                                  INPUTS
                                  PSObject OR array of PSObject OR String OR array of String


                                  You can pipe one IP address or a list of IP addresses as Strings, or one PSObject or list of PSObjects having
                                  the iLO details such as IP Address, Hostname, Username and Password to access the iLO.


                                  OUTPUTS



                                  PSObject[] is returned. Use Get-Member…

                                  1 vote
                                  Sign in
                                  Check!
                                  (thinking…)
                                  Reset
                                  or sign in with
                                  • facebook
                                  • google
                                    Password icon
                                    I agree to the terms of service
                                    Signed in as (Sign out)

                                    We’ll send you updates on this idea

                                    survey  ·  0 comments  ·  Documentation  ·  Flag idea as inappropriate…  ·  Admin →
                                  • Get-PSCallStack reports some non-null stack parameters as $Null.

                                    My test case is
                                    function foo { Get-PSCallStack }

                                    foo (-1) 0 1
                                    foo (-1.0) 0.0 1.0
                                    foo 'A' '' 'B'
                                    foo $False $True

                                    The cmdlet reports the values of the passed parameters, except that 0, 0.0, '', and $False all show up as $Null. I don't customarily output Get-PSCallStack as a line in a function, that's just for this test. But the same thing happens when I'm stepping through debugging and I type Get-PSCallStack.

                                    When I asked about this at https://social.technet.microsoft.com/Forums/windowsserver/en-US/9d2fb7d6-a7f6-4f4c-80f1-525b2dba11f3/bug-in-getpscallstack the response I got was "PowerShell purposely manages these empty objects as if they were nulls. This allows…

                                    2 votes
                                    Sign in
                                    Check!
                                    (thinking…)
                                    Reset
                                    or sign in with
                                    • facebook
                                    • google
                                      Password icon
                                      I agree to the terms of service
                                      Signed in as (Sign out)

                                      We’ll send you updates on this idea

                                      1 comment  ·  Flag idea as inappropriate…  ·  Admin →
                                    • Remove-Module does not remove aliases on PowerShell v5.1.14393.206

                                      On Windows 2016 Server,
                                      Caption : Microsoft Windows Server 2016 Standard Evaluation
                                      CSDversion :
                                      BuildNumber : 14393

                                      PowerShell version:
                                      PSVersion 5.1.14393.206
                                      PSEdition Desktop
                                      BuildVersion 10.0.14393.206
                                      CLRVersion 4.0.30319.42000
                                      WSManStackVersion 3.0
                                      PSRemotingProtocolVersion 2.3
                                      SerializationVersion 1.1.0.1

                                      Using Import-Module -force or Remove-Module, the module's aliases are not removed, which creates errors about cannot add duplicate alias when reloading the module.

                                      1 vote
                                      Sign in
                                      Check!
                                      (thinking…)
                                      Reset
                                      or sign in with
                                      • facebook
                                      • google
                                        Password icon
                                        I agree to the terms of service
                                        Signed in as (Sign out)

                                        We’ll send you updates on this idea

                                        0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                                      • $_.ErrorDetails is null when Invoke-WebRequest or Invoke-RestMethod receives 400 or 500 with chunked encoding.

                                        5.1.14394.1000

                                        Expected behavior is that $_.ErrorDetails is populated with the json data response from Invoke-WebRequest or Invoke-RestMethod. However, if the transaction contains a length before the json string, an error occurs and $_.ErrorDetails is null.

                                        Sample request:

                                        HTTP/1.1 400 Bad Request
                                        Date: Mon, 14 Nov 2016 18:43:42 GMT
                                        Server: server
                                        Expires: Fri, 04 Nov 2016 18:43:42 GMT
                                        Pragma: no-cache
                                        Cache-control: no-cache, no-store, must-revalidate
                                        Content-Type: application/json
                                        X-Frame-Options: SameOrigin
                                        X-Content-Type-Options: nosniff
                                        Connection: close
                                        Transfer-Encoding: chunked

                                        4f
                                        {"totalCount":0,"messages":{"message":"User not found"}}
                                        0

                                        Expected result:
                                        $_.ErrorDetails = {"totalCount":0,"messages":{"message":"User not found"}}

                                        Actual result:
                                        $_.ErrorDetails = null

                                        2 votes
                                        Sign in
                                        Check!
                                        (thinking…)
                                        Reset
                                        or sign in with
                                        • facebook
                                        • google
                                          Password icon
                                          I agree to the terms of service
                                          Signed in as (Sign out)

                                          We’ll send you updates on this idea

                                          0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                                        • 1 vote
                                          Sign in
                                          Check!
                                          (thinking…)
                                          Reset
                                          or sign in with
                                          • facebook
                                          • google
                                            Password icon
                                            I agree to the terms of service
                                            Signed in as (Sign out)

                                            We’ll send you updates on this idea

                                            0 comments  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
                                          • Don't see your idea?

                                          Feedback and Knowledge Base