The "after" should not be printed.
OriginInfo : localhost
Exception :
Type : System.Management.Automation.RemoteException
SerializedRemoteException : System.Management.Automation.ItemNotFoundException: Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
at System.Management.Automation.LocationGlobber.ExpandMshGlobPath(String path, Boolean allowNonexistingPaths, PSDriveInfo drive, ContainerCmdletProvider provider, CmdletProviderContext context)
at System.Management.Automation.LocationGlobber.ResolveDriveQualifiedPath(String path, CmdletProviderContext context, Boolean allowNonexistingPaths, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedMonadPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.PSCmdlet.GetResolvedProviderPathFromPSPath(String path, ProviderInfo& provider)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPath(PSCmdlet cmdlet, String path)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPaths(PSCmdlet cmdlet, ICollection`1 paths)
SerializedRemoteInvocationInfo : System.Management.Automation.InvocationInfo
ErrorRecord :
Exception :
Type : System.Management.Automation.RemoteException
SerializedRemoteException : System.Management.Automation.ItemNotFoundException: Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
at System.Management.Automation.LocationGlobber.ExpandMshGlobPath(String path, Boolean allowNonexistingPaths, PSDriveInfo drive, ContainerCmdletProvider provider, CmdletProviderContext context)
at System.Management.Automation.LocationGlobber.ResolveDriveQualifiedPath(String path, CmdletProviderContext context, Boolean allowNonexistingPaths, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedMonadPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.PSCmdlet.GetResolvedProviderPathFromPSPath(String path, ProviderInfo& provider)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPath(PSCmdlet cmdlet, String path)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPaths(PSCmdlet cmdlet, ICollection`1 paths)
SerializedRemoteInvocationInfo : System.Management.Automation.InvocationInfo
ErrorRecord :
Exception :
Type : System.Management.Automation.RemoteException
SerializedRemoteException : System.Management.Automation.ItemNotFoundException: Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
at System.Management.Automation.LocationGlobber.ExpandMshGlobPath(String path, Boolean allowNonexistingPaths, PSDriveInfo drive, ContainerCmdletProvider provider, CmdletProviderContext context)
at System.Management.Automation.LocationGlobber.ResolveDriveQualifiedPath(String path, CmdletProviderContext context, Boolean allowNonexistingPaths, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedMonadPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.PSCmdlet.GetResolvedProviderPathFromPSPath(String path, ProviderInfo& provider)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPath(PSCmdlet cmdlet, String path)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPaths(PSCmdlet cmdlet, ICollection`1 paths)
SerializedRemoteInvocationInfo : System.Management.Automation.InvocationInfo
ErrorRecord :
Exception :
Type : System.Management.Automation.RemoteException
SerializedRemoteException : System.Management.Automation.ItemNotFoundException: Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
at System.Management.Automation.LocationGlobber.ExpandMshGlobPath(String path, Boolean allowNonexistingPaths, PSDriveInfo drive, ContainerCmdletProvider provider, CmdletProviderContext context)
at System.Management.Automation.LocationGlobber.ResolveDriveQualifiedPath(String path, CmdletProviderContext context, Boolean allowNonexistingPaths, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedMonadPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.PSCmdlet.GetResolvedProviderPathFromPSPath(String path, ProviderInfo& provider)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPath(PSCmdlet cmdlet, String path)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPaths(PSCmdlet cmdlet, ICollection`1 paths)
SerializedRemoteInvocationInfo : System.Management.Automation.InvocationInfo
ErrorRecord :
Exception :
Type : System.Management.Automation.RemoteException
SerializedRemoteException : System.Management.Automation.ItemNotFoundException: Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
at System.Management.Automation.LocationGlobber.ExpandMshGlobPath(String path, Boolean allowNonexistingPaths, PSDriveInfo drive, ContainerCmdletProvider provider, CmdletProviderContext context)
at System.Management.Automation.LocationGlobber.ResolveDriveQualifiedPath(String path, CmdletProviderContext context, Boolean allowNonexistingPaths, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedMonadPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, CmdletProviderContext context, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.LocationGlobber.GetGlobbedProviderPathsFromMonadPath(String path, Boolean allowNonexistingPaths, ProviderInfo& provider, CmdletProvider& providerInstance)
at System.Management.Automation.PSCmdlet.GetResolvedProviderPathFromPSPath(String path, ProviderInfo& provider)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPath(PSCmdlet cmdlet, String path)
at Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.CmdletHelper.ResolvePSPaths(PSCmdlet cmdlet, ICollection`1 paths)
SerializedRemoteInvocationInfo : System.Management.Automation.InvocationInfo
ErrorRecord : …
Message : Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
HResult : -2146233087
TargetObject : NoSuch.exe
CategoryInfo : InvalidArgument: (NoSuch.exe:String) [Get-AppLockerFileInformation], ItemNotFoundException
FullyQualifiedErrorId : CmdletHelper-FailedResolvingPSPath,Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.GetAppLockerFileInformationCmdlet
Message : Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
HResult : -2146233087
TargetObject : NoSuch.exe
CategoryInfo : InvalidArgument: (NoSuch.exe:String) [Get-AppLockerFileInformation], ItemNotFoundException
FullyQualifiedErrorId : CmdletHelper-FailedResolvingPSPath,Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.GetAppLockerFileInformationCmdlet
Message : Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
HResult : -2146233087
TargetObject : NoSuch.exe
CategoryInfo : InvalidArgument: (NoSuch.exe:String) [Get-AppLockerFileInformation], ItemNotFoundException
FullyQualifiedErrorId : CmdletHelper-FailedResolvingPSPath,Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.GetAppLockerFileInformationCmdlet
Message : Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
HResult : -2146233087
TargetObject : NoSuch.exe
CategoryInfo : InvalidArgument: (NoSuch.exe:String) [Get-AppLockerFileInformation], ItemNotFoundException
FullyQualifiedErrorId : CmdletHelper-FailedResolvingPSPath,Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.GetAppLockerFileInformationCmdlet
Message : Cannot find path 'C:\Users\HotCakeX\NoSuch.exe' because it does not exist.
HResult : -2146233087
TargetObject : NoSuch.exe
CategoryInfo : InvalidArgument: (NoSuch.exe:String) [Get-AppLockerFileInformation], ItemNotFoundException
FullyQualifiedErrorId : CmdletHelper-FailedResolvingPSPath,Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets.GetAppLockerFileInformationCmdlet
Prerequisites
Steps to reproduce
Thanks to @mklement0 for providing this very straightforward repro step
Expected behavior
The "after" should not be printed.
Actual behavior
"after" is printed
This problem doesn't happen in PowerShell 7.3.6
Error details
Environment data
Visuals
No response