René's URL Explorer Experiment


Title: PowerShell 7.3 doesn't pass variable values / cmdlet results arguments to child processes when comma is present · Issue #18502 · PowerShell/PowerShell · GitHub

Open Graph Title: PowerShell 7.3 doesn't pass variable values / cmdlet results arguments to child processes when comma is present · Issue #18502 · PowerShell/PowerShell

X Title: PowerShell 7.3 doesn't pass variable values / cmdlet results arguments to child processes when comma is present · Issue #18502 · PowerShell/PowerShell

Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerShell 5.1 and PowerShell. Steps to reprodu...

Open Graph Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh...

X Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh...

Opengraph URL: https://github.com/PowerShell/PowerShell/issues/18502

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"PowerShell 7.3 doesn't pass variable values / cmdlet results arguments to child processes when comma is present","articleBody":"### Prerequisites\n\n- [X] Write a descriptive title.\n- [X] Make sure you are able to repro it on the [latest released version](https://github.com/PowerShell/PowerShell/releases)\n- [X] Search the existing issues.\n- [X] Refer to the [FAQ](https://github.com/PowerShell/PowerShell/blob/master/docs/FAQ.md).\n- [X] Refer to [Differences between Windows PowerShell 5.1 and PowerShell](https://docs.microsoft.com/powershell/scripting/whats-new/differences-from-windows-powershell).\n\n### Steps to reproduce\n\nWhen launching an executable from PowerShell, with `$PSNativeCommandArgumentPassing \u003c\u003e \"Legacy\"` if the arguments contain a comma, the variables/cmdlets are evaluated, but the results of the evaluation don't go to the child process.\r\n\r\n```powershell\r\nC:\\Windows\\System32\u003e $PSNativeCommandArgumentPassing = \"Windows\"\r\nC:\\Windows\\System32\u003e $x = \"lame\"\r\nC:\\Windows\\System32\u003e cmd /c echo x=$x\r\nx=lame\r\nC:\\Windows\\System32\u003e cmd /c echo a,x=$x\r\na,x=$x\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo x=$x }\r\nDEBUG: 2022-11-09 20:39:02.1548 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:39:02.1551 ParameterBinding Information: 0 :     BIND argument [/c echo x=lame]\r\nDEBUG: 2022-11-09 20:39:02.1702 ParameterBinding Information: 0 : CALLING BeginProcessing\r\nx=lame\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo a,x=$x }\r\nDEBUG: 2022-11-09 20:39:07.6131 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:39:07.6134 ParameterBinding Information: 0 :     BIND argument [/c echo a,x=$x]\r\nDEBUG: 2022-11-09 20:39:07.6194 ParameterBinding Information: 0 : CALLING BeginProcessing\r\na,x=$x\r\nC:\\Windows\\System32\u003e $PSNativeCommandArgumentPassing = \"Standard\"\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo x=$x }\r\nDEBUG: 2022-11-09 20:39:22.6507 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:39:22.6510 ParameterBinding Information: 0 :     BIND cmd line arg [/c] to position [0]\r\nDEBUG: 2022-11-09 20:39:22.6513 ParameterBinding Information: 0 :     BIND cmd line arg [echo] to position [1]\r\nDEBUG: 2022-11-09 20:39:22.6515 ParameterBinding Information: 0 :     BIND cmd line arg [x=lame] to position [2]\r\nDEBUG: 2022-11-09 20:39:22.6681 ParameterBinding Information: 0 : CALLING BeginProcessing\r\nx=lame\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo a,x=$x }\r\nDEBUG: 2022-11-09 20:39:25.2418 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:39:25.2422 ParameterBinding Information: 0 :     BIND cmd line arg [/c] to position [0]\r\nDEBUG: 2022-11-09 20:39:25.2425 ParameterBinding Information: 0 :     BIND cmd line arg [echo] to position [1]\r\nDEBUG: 2022-11-09 20:39:25.2428 ParameterBinding Information: 0 :     BIND cmd line arg [a,x=$x] to position [2]\r\nDEBUG: 2022-11-09 20:39:25.2666 ParameterBinding Information: 0 : CALLING BeginProcessing\r\na,x=$x\r\nC:\\Windows\\System32\u003e $PSNativeCommandArgumentPassing = \"Legacy\"\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo x=$x }\r\nDEBUG: 2022-11-09 20:39:36.2214 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:39:36.2218 ParameterBinding Information: 0 :     BIND argument [/c echo x=lame]\r\nDEBUG: 2022-11-09 20:39:36.2561 ParameterBinding Information: 0 : CALLING BeginProcessing\r\nx=lame\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo a,x=$x }\r\nDEBUG: 2022-11-09 20:39:38.4751 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:39:38.4755 ParameterBinding Information: 0 :     BIND argument [/c echo a,x=lame]\r\nDEBUG: 2022-11-09 20:39:38.4822 ParameterBinding Information: 0 : CALLING BeginProcessing\r\na,x=lame\r\nC:\\Windows\\System32\u003e\r\n```\r\n\r\nWe can see that the cmdlet is executed (or attempted):\r\n\r\n```powershell\r\nC:\\Windows\\System32\u003e $PSNativeCommandArgumentPassing = \"Standard\"\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo cd=$(Get-Location) }\r\nDEBUG: 2022-11-09 20:48:15.0675 ParameterBinding Information: 0 : BIND NAMED cmd line args [Get-Location]\r\nDEBUG: 2022-11-09 20:48:15.0677 ParameterBinding Information: 0 : BIND POSITIONAL cmd line args [Get-Location]\r\nDEBUG: 2022-11-09 20:48:15.0679 ParameterBinding Information: 0 : BIND cmd line args to DYNAMIC parameters.\r\nDEBUG: 2022-11-09 20:48:15.0681 ParameterBinding Information: 0 : MANDATORY PARAMETER CHECK on cmdlet [Get-Location]\r\nDEBUG: 2022-11-09 20:48:15.0683 ParameterBinding Information: 0 : CALLING BeginProcessing\r\nDEBUG: 2022-11-09 20:48:15.0685 ParameterBinding Information: 0 : CALLING ProcessRecord\r\nDEBUG: 2022-11-09 20:48:15.0687 ParameterBinding Information: 0 : CALLING EndProcessing\r\nDEBUG: 2022-11-09 20:48:15.0762 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:48:15.0767 ParameterBinding Information: 0 :     BIND cmd line arg [/c] to position [0]\r\nDEBUG: 2022-11-09 20:48:15.0770 ParameterBinding Information: 0 :     BIND cmd line arg [echo] to position [1]\r\nDEBUG: 2022-11-09 20:48:15.0773 ParameterBinding Information: 0 :     BIND cmd line arg [cd=C:\\Windows\\System32] to position [2]\r\nDEBUG: 2022-11-09 20:48:15.0943 ParameterBinding Information: 0 : CALLING BeginProcessing\r\ncd=C:\\Windows\\System32\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo foo,cd=$(Get-Location) }\r\nDEBUG: 2022-11-09 20:48:18.2709 ParameterBinding Information: 0 : BIND NAMED cmd line args [Get-Location]\r\nDEBUG: 2022-11-09 20:48:18.2712 ParameterBinding Information: 0 : BIND POSITIONAL cmd line args [Get-Location]\r\nDEBUG: 2022-11-09 20:48:18.2714 ParameterBinding Information: 0 : BIND cmd line args to DYNAMIC parameters.\r\nDEBUG: 2022-11-09 20:48:18.2717 ParameterBinding Information: 0 : MANDATORY PARAMETER CHECK on cmdlet [Get-Location]\r\nDEBUG: 2022-11-09 20:48:18.2719 ParameterBinding Information: 0 : CALLING BeginProcessing\r\nDEBUG: 2022-11-09 20:48:18.2721 ParameterBinding Information: 0 : CALLING ProcessRecord\r\nDEBUG: 2022-11-09 20:48:18.2723 ParameterBinding Information: 0 : CALLING EndProcessing\r\nDEBUG: 2022-11-09 20:48:18.2815 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:48:18.2819 ParameterBinding Information: 0 :     BIND cmd line arg [/c] to position [0]\r\nDEBUG: 2022-11-09 20:48:18.2821 ParameterBinding Information: 0 :     BIND cmd line arg [echo] to position [1]\r\nDEBUG: 2022-11-09 20:48:18.2824 ParameterBinding Information: 0 :     BIND cmd line arg [foo,cd=$(Get-Location)] to position [2]\r\nDEBUG: 2022-11-09 20:48:18.2999 ParameterBinding Information: 0 : CALLING BeginProcessing\r\nfoo,cd=$(Get-Location)\r\nC:\\Windows\\System32\u003e Trace-Command -PSHost -Name \"ParameterBinding\" { cmd /c echo foo,cd=$(Get-Locatio) }\r\nDEBUG: 2022-11-09 20:48:24.7753 ParameterBinding Information: 0 : BIND PIPELINE object to parameters: [Out-Default]\r\nDEBUG: 2022-11-09 20:48:24.7756 ParameterBinding Information: 0 :     PIPELINE object TYPE = [System.Management.Automation.ErrorRecord]\r\nDEBUG: 2022-11-09 20:48:24.7759 ParameterBinding Information: 0 :     RESTORING pipeline parameter's original values\r\nDEBUG: 2022-11-09 20:48:24.7762 ParameterBinding Information: 0 :     Parameter [InputObject] PIPELINE INPUT ValueFromPipeline NO COERCION\r\nDEBUG: 2022-11-09 20:48:24.7765 ParameterBinding Information: 0 :     BIND arg [The term 'Get-Locatio' is not recognized as a name of a cmdlet, function, script file, or executable program.\r\nCheck the spelling of the name, or if a path was included, verify that the path is correct and try again.] to parameter [InputObject]\r\nDEBUG: 2022-11-09 20:48:24.7768 ParameterBinding Information: 0 :         BIND arg [The term 'Get-Locatio' is not recognized as a name of a cmdlet, function, script file, or executable program.\r\nCheck the spelling of the name, or if a path was included, verify that the path is correct and try again.] to param [InputObject] SUCCESSFUL\r\nDEBUG: 2022-11-09 20:48:24.7771 ParameterBinding Information: 0 : MANDATORY PARAMETER CHECK on cmdlet [Out-Default]\r\nDEBUG: 2022-11-09 20:48:24.7774 ParameterBinding Information: 0 : CALLING ProcessRecord\r\nDEBUG: 2022-11-09 20:48:24.7778 ParameterBinding Information: 0 :     BIND NAMED cmd line args [Out-LineOutput]\r\nDEBUG: 2022-11-09 20:48:24.7785 ParameterBinding Information: 0 :         BIND arg [Microsoft.PowerShell.Commands.Internal.Format.ConsoleLineOutput] to parameter [LineOutput]\r\nDEBUG: 2022-11-09 20:48:24.7803 ParameterBinding Information: 0 :             COERCE arg to [System.Object]\r\nDEBUG: 2022-11-09 20:48:24.7830 ParameterBinding Information: 0 :                 Parameter and arg types the same, no coercion is needed.\r\nDEBUG: 2022-11-09 20:48:24.7845 ParameterBinding Information: 0 :             BIND arg [Microsoft.PowerShell.Commands.Internal.Format.ConsoleLineOutput] to param [LineOutput] SUCCESSFUL\r\nDEBUG: 2022-11-09 20:48:24.7853 ParameterBinding Information: 0 :     BIND POSITIONAL cmd line args [Out-LineOutput]\r\nDEBUG: 2022-11-09 20:48:24.7858 ParameterBinding Information: 0 :     MANDATORY PARAMETER CHECK on cmdlet [Out-LineOutput]\r\nDEBUG: 2022-11-09 20:48:24.7863 ParameterBinding Information: 0 :     CALLING BeginProcessing\r\nDEBUG: 2022-11-09 20:48:24.7868 ParameterBinding Information: 0 :     BIND PIPELINE object to parameters: [Out-LineOutput]\r\nDEBUG: 2022-11-09 20:48:24.7873 ParameterBinding Information: 0 :         PIPELINE object TYPE = [System.Management.Automation.ErrorRecord]\r\nDEBUG: 2022-11-09 20:48:24.7878 ParameterBinding Information: 0 :         RESTORING pipeline parameter's original values\r\nDEBUG: 2022-11-09 20:48:24.7885 ParameterBinding Information: 0 :         Parameter [InputObject] PIPELINE INPUT ValueFromPipeline NO COERCION\r\nDEBUG: 2022-11-09 20:48:24.7890 ParameterBinding Information: 0 :         BIND arg [The term 'Get-Locatio' is not recognized as a name of a cmdlet, function, script file, or executable program.\r\nCheck the spelling of the name, or if a path was included, verify that the path is correct and try again.] to parameter [InputObject]\r\nDEBUG: 2022-11-09 20:48:24.7895 ParameterBinding Information: 0 :             BIND arg [The term 'Get-Locatio' is not recognized as a name of a cmdlet, function, script file, or executable program.\r\nCheck the spelling of the name, or if a path was included, verify that the path is correct and try again.] to param [InputObject] SUCCESSFUL\r\nDEBUG: 2022-11-09 20:48:24.7901 ParameterBinding Information: 0 :     MANDATORY PARAMETER CHECK on cmdlet [out-lineoutput]\r\nDEBUG: 2022-11-09 20:48:24.7904 ParameterBinding Information: 0 :     CALLING ProcessRecord\r\nDEBUG: 2022-11-09 20:48:24.7911 ParameterBinding Information: 0 :         BIND NAMED cmd line args [Format-Default]\r\nDEBUG: 2022-11-09 20:48:24.7916 ParameterBinding Information: 0 :         BIND POSITIONAL cmd line args [Format-Default]\r\nDEBUG: 2022-11-09 20:48:24.7920 ParameterBinding Information: 0 :         MANDATORY PARAMETER CHECK on cmdlet [Format-Default]\r\nDEBUG: 2022-11-09 20:48:24.7924 ParameterBinding Information: 0 :         CALLING BeginProcessing\r\nDEBUG: 2022-11-09 20:48:24.7928 ParameterBinding Information: 0 :         BIND PIPELINE object to parameters: [Format-Default]\r\nDEBUG: 2022-11-09 20:48:24.7932 ParameterBinding Information: 0 :             PIPELINE object TYPE = [System.Management.Automation.ErrorRecord]\r\nDEBUG: 2022-11-09 20:48:24.7937 ParameterBinding Information: 0 :             RESTORING pipeline parameter's original values\r\nDEBUG: 2022-11-09 20:48:24.7946 ParameterBinding Information: 0 :             Parameter [InputObject] PIPELINE INPUT ValueFromPipeline NO COERCION\r\nDEBUG: 2022-11-09 20:48:24.7954 ParameterBinding Information: 0 :             BIND arg [The term 'Get-Locatio' is not recognized as a name of a cmdlet, function, script file, or executable program.\r\nCheck the spelling of the name, or if a path was included, verify that the path is correct and try again.] to parameter [InputObject]\r\nDEBUG: 2022-11-09 20:48:24.7967 ParameterBinding Information: 0 :                 BIND arg [The term 'Get-Locatio' is not recognized as a name of a cmdlet, function, script file, or executable program.\r\nCheck the spelling of the name, or if a path was included, verify that the path is correct and try again.] to param [InputObject] SUCCESSFUL\r\nDEBUG: 2022-11-09 20:48:24.7974 ParameterBinding Information: 0 :         MANDATORY PARAMETER CHECK on cmdlet [format-default]\r\nDEBUG: 2022-11-09 20:48:24.7978 ParameterBinding Information: 0 :         CALLING ProcessRecord\r\nDEBUG: 2022-11-09 20:48:24.8372 ParameterBinding Information: 0 :             BIND NAMED cmd line args [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8377 ParameterBinding Information: 0 :                 BIND arg [True] to parameter [Off]\r\nDEBUG: 2022-11-09 20:48:24.8381 ParameterBinding Information: 0 :                     COERCE arg to [System.Management.Automation.SwitchParameter]\r\nDEBUG: 2022-11-09 20:48:24.8384 ParameterBinding Information: 0 :                         Parameter and arg types the same, no coercion is needed.\r\nDEBUG: 2022-11-09 20:48:24.8388 ParameterBinding Information: 0 :                     BIND arg [True] to param [Off] SUCCESSFUL\r\nDEBUG: 2022-11-09 20:48:24.8392 ParameterBinding Information: 0 :             BIND POSITIONAL cmd line args [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8395 ParameterBinding Information: 0 :             MANDATORY PARAMETER CHECK on cmdlet [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8399 ParameterBinding Information: 0 :             CALLING BeginProcessing\r\nDEBUG: 2022-11-09 20:48:24.8402 ParameterBinding Information: 0 :             CALLING ProcessRecord\r\nDEBUG: 2022-11-09 20:48:24.8406 ParameterBinding Information: 0 :             CALLING EndProcessing\r\nDEBUG: 2022-11-09 20:48:24.8539 ParameterBinding Information: 0 :             BIND NAMED cmd line args [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8544 ParameterBinding Information: 0 :                 BIND arg [1] to parameter [Version]\r\nDEBUG: 2022-11-09 20:48:24.8548 ParameterBinding Information: 0 :                     Executing DATA GENERATION metadata: [Microsoft.PowerShell.Commands.SetStrictModeCommand+ArgumentToPSVersionTransformationAttribute]\r\nDEBUG: 2022-11-09 20:48:24.8553 ParameterBinding Information: 0 :                         result returned from DATA GENERATION: 1.0\r\nDEBUG: 2022-11-09 20:48:24.8556 ParameterBinding Information: 0 :                     COERCE arg to [System.Version]\r\nDEBUG: 2022-11-09 20:48:24.8560 ParameterBinding Information: 0 :                         Parameter and arg types the same, no coercion is needed.\r\nDEBUG: 2022-11-09 20:48:24.8564 ParameterBinding Information: 0 :                     Executing VALIDATION metadata: [Microsoft.PowerShell.Commands.SetStrictModeCommand+ValidateVersionAttribute]\r\nDEBUG: 2022-11-09 20:48:24.8568 ParameterBinding Information: 0 :                     BIND arg [1.0] to param [Version] SUCCESSFUL\r\nDEBUG: 2022-11-09 20:48:24.8571 ParameterBinding Information: 0 :             BIND POSITIONAL cmd line args [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8575 ParameterBinding Information: 0 :             MANDATORY PARAMETER CHECK on cmdlet [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8578 ParameterBinding Information: 0 :             CALLING BeginProcessing\r\nDEBUG: 2022-11-09 20:48:24.8582 ParameterBinding Information: 0 :             CALLING ProcessRecord\r\nDEBUG: 2022-11-09 20:48:24.8585 ParameterBinding Information: 0 :             CALLING EndProcessing\r\nDEBUG: 2022-11-09 20:48:24.8592 ParameterBinding Information: 0 :             BIND NAMED cmd line args [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8595 ParameterBinding Information: 0 :                 BIND arg [1] to parameter [Version]\r\nDEBUG: 2022-11-09 20:48:24.8599 ParameterBinding Information: 0 :                     Executing DATA GENERATION metadata: [Microsoft.PowerShell.Commands.SetStrictModeCommand+ArgumentToPSVersionTransformationAttribute]\r\nDEBUG: 2022-11-09 20:48:24.8604 ParameterBinding Information: 0 :                         result returned from DATA GENERATION: 1.0\r\nDEBUG: 2022-11-09 20:48:24.8607 ParameterBinding Information: 0 :                     COERCE arg to [System.Version]\r\nDEBUG: 2022-11-09 20:48:24.8610 ParameterBinding Information: 0 :                         Parameter and arg types the same, no coercion is needed.\r\nDEBUG: 2022-11-09 20:48:24.8614 ParameterBinding Information: 0 :                     Executing VALIDATION metadata: [Microsoft.PowerShell.Commands.SetStrictModeCommand+ValidateVersionAttribute]\r\nDEBUG: 2022-11-09 20:48:24.8618 ParameterBinding Information: 0 :                     BIND arg [1.0] to param [Version] SUCCESSFUL\r\nDEBUG: 2022-11-09 20:48:24.8621 ParameterBinding Information: 0 :             BIND POSITIONAL cmd line args [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8625 ParameterBinding Information: 0 :             MANDATORY PARAMETER CHECK on cmdlet [Set-StrictMode]\r\nDEBUG: 2022-11-09 20:48:24.8628 ParameterBinding Information: 0 :             CALLING BeginProcessing\r\nDEBUG: 2022-11-09 20:48:24.8632 ParameterBinding Information: 0 :             CALLING ProcessRecord\r\nDEBUG: 2022-11-09 20:48:24.8635 ParameterBinding Information: 0 :             CALLING EndProcessing\r\nGet-Locatio: The term 'Get-Locatio' is not recognized as a name of a cmdlet, function, script file, or executable program.\r\nCheck the spelling of the name, or if a path was included, verify that the path is correct and try again.\r\nDEBUG: 2022-11-09 20:48:24.8905 ParameterBinding Information: 0 : BIND NAMED native application line args [C:\\Windows\\system32\\cmd.exe]\r\nDEBUG: 2022-11-09 20:48:24.8912 ParameterBinding Information: 0 :     BIND cmd line arg [/c] to position [0]\r\nDEBUG: 2022-11-09 20:48:24.8917 ParameterBinding Information: 0 :     BIND cmd line arg [echo] to position [1]\r\nDEBUG: 2022-11-09 20:48:24.8928 ParameterBinding Information: 0 :     BIND cmd line arg [foo,cd=$(Get-Locatio)] to position [2]\r\nDEBUG: 2022-11-09 20:48:24.9049 ParameterBinding Information: 0 : CALLING BeginProcessing\r\nfoo,cd=$(Get-Locatio)\r\nC:\\Windows\\System32\u003e\r\n```\n\n### Expected behavior\n\n```console\nC:\\Foo\u003e docker run --rm -it --mount type=bind,src=$(Get-Location),dst=C:\\target mcr.microsoft.com/windows/servercore:10.0.20348.887 powershell.exe\r\nWindows PowerShell\r\nCopyright (C) Microsoft Corporation. All rights reserved.\r\n\r\nInstall the latest PowerShell for new features and improvements! https://aka.ms/PSWindows\r\n\r\nPS C:\\\u003e $PSVersionTable\r\n\r\nName                           Value\r\n----                           -----\r\nPSVersion                      5.1.20348.859\r\nPSEdition                      Desktop\r\nPSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}\r\nBuildVersion                   10.0.20348.859\r\nCLRVersion                     4.0.30319.42000\r\nWSManStackVersion              3.0\r\nPSRemotingProtocolVersion      2.3\r\nSerializationVersion           1.1.0.1\r\n\r\n\r\nPS C:\\\u003e\n```\n\n\n### Actual behavior\n\n```console\nC:\\Foo\u003e docker run --rm -it --mount type=bind,src=$(Get-Location),dst=C:\\target mcr.microsoft.com/windows/servercore:10.0.20348.887 powershell.exe\r\ndocker: Error response from daemon: invalid mount config for type \"bind\": invalid mount path: '$(Get-Location)' mount path must be absolute.\r\nSee 'docker run --help'.\r\nC:\\Foo\u003e\n```\n\n\n### Error details\n\n_No response_\n\n### Environment data\n\n```powershell\nC:\\\u003e $PSVersionTable\r\n\r\nName                           Value\r\n----                           -----\r\nPSVersion                      7.3.0\r\nPSEdition                      Core\r\nGitCommitId                    7.3.0\r\nOS                             Microsoft Windows 10.0.22621\r\nPlatform                       Win32NT\r\nPSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}\r\nPSRemotingProtocolVersion      2.3\r\nSerializationVersion           1.1.0.1\r\nWSManStackVersion              3.0\n```\n\n\n### Visuals\n\n_No response_","author":{"url":"https://github.com/conioh","@type":"Person","name":"conioh"},"datePublished":"2022-11-09T18:56:09.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":26},"url":"https://github.com/18502/PowerShell/issues/18502"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:5e83b1fc-38fc-4410-c3fd-f189a8fb9fa3
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idD982:A841C:10E34E6:183DE8A:6A5A1851
html-safe-nonceab760002b80692f190dde41325cf4318abc30ea52142f9119756d7c2a3684167
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOTgyOkE4NDFDOjEwRTM0RTY6MTgzREU4QTo2QTVBMTg1MSIsInZpc2l0b3JfaWQiOiIzNDEwOTE4MjQ5MjE0OTA4NDk4IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac75cbedd1c6d5bc3a94a52be54a6a4223798520feba07f2d5eb397f609eef5499
hovercard-subject-tagissue:1442592226
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/PowerShell/PowerShell/18502/issue_layout
twitter:imagehttps://opengraph.githubassets.com/b7abe585a2c345e1904bd2a936b7d1053078bd3377313a7c3b13f9b33873b2be/PowerShell/PowerShell/issues/18502
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/b7abe585a2c345e1904bd2a936b7d1053078bd3377313a7c3b13f9b33873b2be/PowerShell/PowerShell/issues/18502
og:image:altPrerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameconioh
hostnamegithub.com
expected-hostnamegithub.com
None8c2fe7351e4e987cb8f75e2425a0b895d807779bc4c2d3c312be0a54082219f7
turbo-cache-controlno-preview
go-importgithub.com/PowerShell/PowerShell git https://github.com/PowerShell/PowerShell.git
octolytics-dimension-user_id11524380
octolytics-dimension-user_loginPowerShell
octolytics-dimension-repository_id49609581
octolytics-dimension-repository_nwoPowerShell/PowerShell
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id49609581
octolytics-dimension-repository_network_root_nwoPowerShell/PowerShell
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release501ec24a694e4933bb3d70e768b1461c0def57a2
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/PowerShell/PowerShell/issues/18502#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShell%2Fissues%2F18502
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShell%2Fissues%2F18502
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=PowerShell%2FPowerShell
Reloadhttps://github.com/PowerShell/PowerShell/issues/18502
Reloadhttps://github.com/PowerShell/PowerShell/issues/18502
Reloadhttps://github.com/PowerShell/PowerShell/issues/18502
Please reload this pagehttps://github.com/PowerShell/PowerShell/issues/18502
PowerShell https://github.com/PowerShell
PowerShellhttps://github.com/PowerShell/PowerShell
Notifications https://github.com/login?return_to=%2FPowerShell%2FPowerShell
Fork 8.4k https://github.com/login?return_to=%2FPowerShell%2FPowerShell
Star 54.5k https://github.com/login?return_to=%2FPowerShell%2FPowerShell
Code https://github.com/PowerShell/PowerShell
Issues 1.2k https://github.com/PowerShell/PowerShell/issues
Pull requests 287 https://github.com/PowerShell/PowerShell/pulls
Discussions https://github.com/PowerShell/PowerShell/discussions
Actions https://github.com/PowerShell/PowerShell/actions
Projects https://github.com/PowerShell/PowerShell/projects
Security and quality 3 https://github.com/PowerShell/PowerShell/security
Insights https://github.com/PowerShell/PowerShell/pulse
Code https://github.com/PowerShell/PowerShell
Issues https://github.com/PowerShell/PowerShell/issues
Pull requests https://github.com/PowerShell/PowerShell/pulls
Discussions https://github.com/PowerShell/PowerShell/discussions
Actions https://github.com/PowerShell/PowerShell/actions
Projects https://github.com/PowerShell/PowerShell/projects
Security and quality https://github.com/PowerShell/PowerShell/security
Insights https://github.com/PowerShell/PowerShell/pulse
PowerShell 7.3 doesn't pass variable values / cmdlet results arguments to child processes when comma is presenthttps://github.com/PowerShell/PowerShell/issues/18502#top
Needs-TriageThe issue is new and needs to be triaged by a work group.https://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Needs-Triage%22
Resolution-No ActivityIssue has had no activity for 6 months or morehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Resolution-No%20Activity%22
WG-Enginecore PowerShell engine, interpreter, and runtimehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Engine%22
https://github.com/conioh
coniohhttps://github.com/conioh
on Nov 9, 2022https://github.com/PowerShell/PowerShell/issues/18502#issue-1442592226
latest released versionhttps://github.com/PowerShell/PowerShell/releases
FAQhttps://github.com/PowerShell/PowerShell/blob/master/docs/FAQ.md
Differences between Windows PowerShell 5.1 and PowerShellhttps://docs.microsoft.com/powershell/scripting/whats-new/differences-from-windows-powershell
Needs-TriageThe issue is new and needs to be triaged by a work group.https://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Needs-Triage%22
Resolution-No ActivityIssue has had no activity for 6 months or morehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22Resolution-No%20Activity%22
WG-Enginecore PowerShell engine, interpreter, and runtimehttps://github.com/PowerShell/PowerShell/issues?q=state%3Aopen%20label%3A%22WG-Engine%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.