From 1a1da6f105baf47babf292ea71a8218868071c5a Mon Sep 17 00:00:00 2001 From: Bob Arnson Date: Wed, 28 Feb 2024 21:35:41 -0500 Subject: [PATCH] Add detail when failing to extract containers. --- src/wix/WixToolset.Core.Burn/BurnBackendWarnings.cs | 4 ++-- src/wix/WixToolset.Core.Burn/CommandLine/ExtractSubcommand.cs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/wix/WixToolset.Core.Burn/BurnBackendWarnings.cs b/src/wix/WixToolset.Core.Burn/BurnBackendWarnings.cs index 3b2ecdd7a..9c7cde13d 100644 --- a/src/wix/WixToolset.Core.Burn/BurnBackendWarnings.cs +++ b/src/wix/WixToolset.Core.Burn/BurnBackendWarnings.cs @@ -26,9 +26,9 @@ public static Message EmptyContainer(SourceLineNumber sourceLineNumbers, string return Message(sourceLineNumbers, Ids.EmptyContainer, "The Container '{0}' is being ignored because it doesn't have any payloads.", containerId); } - public static Message FailedToExtractAttachedContainers(SourceLineNumber sourceLineNumbers) + public static Message FailedToExtractAttachedContainers(SourceLineNumber sourceLineNumbers, string message) { - return Message(sourceLineNumbers, Ids.FailedToExtractAttachedContainers, "Failed to extract attached container. This most often happens when extracting a stripped bundle from the package cache, which is not supported."); + return Message(sourceLineNumbers, Ids.FailedToExtractAttachedContainers, "Failed to extract attached container. This most often happens when extracting a stripped bundle from the package cache, which is not supported. Detail: {0}", message); } public static Message HiddenBundleNotSupported(SourceLineNumber sourceLineNumbers, string packageId) diff --git a/src/wix/WixToolset.Core.Burn/CommandLine/ExtractSubcommand.cs b/src/wix/WixToolset.Core.Burn/CommandLine/ExtractSubcommand.cs index a6660a06f..091b75a6e 100644 --- a/src/wix/WixToolset.Core.Burn/CommandLine/ExtractSubcommand.cs +++ b/src/wix/WixToolset.Core.Burn/CommandLine/ExtractSubcommand.cs @@ -72,9 +72,9 @@ public override Task ExecuteAsync(CancellationToken cancellationToken) reader.ExtractAttachedContainers(this.ExtractContainersPath, this.IntermediateFolder); } } - catch + catch (Exception e) { - this.Messaging.Write(BurnBackendWarnings.FailedToExtractAttachedContainers(new SourceLineNumber(this.ExtractContainersPath))); + this.Messaging.Write(BurnBackendWarnings.FailedToExtractAttachedContainers(new SourceLineNumber(this.ExtractContainersPath), e.Message)); } } }