Skip to content

"Multiple root elements" error in MAML file #832

@sdwheeler

Description

@sdwheeler

Prerequisites

  • Write a descriptive title.
  • Make sure you are able to repro it on the latest version
  • Search the existing issues.

Steps to reproduce

See MicrosoftDocs/PowerShell-Docs#12460 for original report.

On Windows PowerShell 5.1 fresh install, Update-Help reports error on help file for module Microsoft.PowerShell.Host 3.0.0.0 - downloaded XML is corrupted
However, md files are correct

Attached corrupted file
Microsoft.PowerShell.ConsoleHost.dll-help.xml

Update-Help repository
CAB location

[18:25:44] C:\Var\Temp # Update-Help -Module "Microsoft.PowerShell.Host" -Force
Update-Help : Failed to update Help for the module(s) 'Microsoft.PowerShell.Host' with UI culture(s) {en-US} : There ar e multiple root elements. Line 71, position 21.
At line:1 char:1
+ Update-Help -Module "Microsoft.PowerShell.Host" -Force
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [Update-Help], Exception
    + FullyQualifiedErrorId : UnknownErrorId,Microsoft.PowerShell.Commands.UpdateHelpCommand

Expected behavior

Updated help

Actual behavior

Error message

Error details

Environment data

Windows PowerShell 5.1

Version

1.0.1

Visuals

No response

Metadata

Metadata

Labels

Area-MAMLIssue concerns conversion to MAML

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions