Skip to content

Get-ChildItem doesn't output correctly when used with Invoke-Command #10759

@leoniDEV

Description

@leoniDEV

Using Invoke-Command to get the folder list from a remote computer an empty table is displayed, this seems a problem with the formatting of the output.

Steps to reproduce

 Invoke-Command {Get-ChildItem $env:APPDATA} -ComputerName buildsrv1

Expected behavior

Get the list of folders
Annotazione 2019-10-10 112845

Actual behavior

Annotazione 2019-10-10 110545

Additional Notes

The object returned by the command seems ok, If i pipe the Invoke-Command to Select-Object or Format-List the output is correct

Annotazione 2019-10-10 112235

Annotazione 2019-10-10 112401

Environment data

Name                           Value
----                           -----
PSVersion                      7.0.0-preview.4
PSEdition                      Core
GitCommitId                    7.0.0-preview.4
OS                             Microsoft Windows 10.0.18995
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

No one assigned

    Labels

    Area-FileSystem-Providerspecific to the FileSystem providerIssue-BugIssue has been identified as a bug in the productKeepOpenThe bot will ignore these and not auto-closeWG-Cmdlets-Managementcmdlets in the Microsoft.PowerShell.Management moduleWG-Engine-FormatWG-RemotingPSRP issues with any transport layer

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions