Skip to content

fix(install): defer success message until post-install checks#6098

Open
AMDphreak wants to merge 1 commit intomicrosoft:masterfrom
AMDphreak:fix/defer-install-success-after-checks
Open

fix(install): defer success message until post-install checks#6098
AMDphreak wants to merge 1 commit intomicrosoft:masterfrom
AMDphreak:fix/defer-install-success-after-checks

Conversation

@AMDphreak
Copy link
Copy Markdown

@AMDphreak AMDphreak commented Mar 21, 2026

Summary

Delays the Successfully installed / repair success line until after post-install work runs (ARP snapshot correlation, upgrade version verification, record install, installation notes).

Details

  • New context flags: DeferInstallSuccessMessage, PendingDeferredInstallSuccess, SuppressDeferredInstallSuccess.
  • InstallPackageInstaller sets defer, runs the existing pipeline, then ReportDeferredInstallSuccess.
  • ReportInstallerResult, MsixInstall, and Microsoft Store install/update/repair paths respect defer; MSIX registration-deferred suppresses generic success (warning already shown).
  • PendingDeferredInstallSuccess avoids printing success when the installer never completed (for example install lock cancelled before a success path).

Related

Complements accurate reporting after install (for example ARP / version checks); avoids claiming success before those steps finish.

Testing

CI build; manual install scenarios recommended.

Made with Cursor

Microsoft Reviewers: Open in CodeFlow

- Add DeferInstallSuccessMessage, PendingDeferredInstallSuccess, and
  SuppressDeferredInstallSuccess context flags.
- InstallPackageInstaller defers reporting until after ReportARPChanges,
  RecordInstall, and DisplayInstallationNotes.
- ReportInstallerResult, MsixInstall, and MS Store handlers honor defer;
  MSIX registration-deferred path suppresses generic success.
- ReportDeferredInstallSuccess avoids spurious success when the installer
  did not complete (e.g. lock cancellation).

Made-with: Cursor
@AMDphreak AMDphreak marked this pull request as ready for review March 21, 2026 09:54
@AMDphreak AMDphreak requested a review from a team as a code owner March 21, 2026 09:54
@JohnMcPMS
Copy link
Copy Markdown
Member

I don't agree with this change; the install was successful so we message that out. If we fail to do our own bookkeeping that can result in a failure of the overall operation, but the package install has already concluded. There can certainly be downstream problems created by that post-install failure, but any remediation would not involve re-running the package install.

If there is a real issue that arises here I would prefer to see a comprehensive solution to handling post-operation failures. This change will end up making it look like the user request was not satisfied, when it is instead much closer to not getting a receipt with your purchase.

@JohnMcPMS JohnMcPMS added the Needs-Author-Feedback Issue needs attention from issue or PR author label Mar 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Needs-Author-Feedback Issue needs attention from issue or PR author

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants