Skip to content

winget uninstall Microsoft.Aspire fails on dogfood LocalManifestFiles installs (exit -1978335212) #17944

@radical

Description

@radical

Summary

winget uninstall --id Microsoft.Aspire and eng/winget/dogfood.ps1 -Uninstall both fail with exit code -1978335212 (APPINSTALLER_CLI_ERROR_NO_APPLICABLE_INSTALLER / "the input value is invalid") when the Aspire install was created via the dogfood LocalManifestFiles path. The recorded source for a dogfood install ends with __DefaultSource rather than _Microsoft.Winget.Source_8wekyb3d8bbwe, and winget's uninstall lookup doesn't resolve Microsoft.Aspire against that source identifier the same way.

Manual cleanup currently requires removing three pieces by hand:

Remove-Item $pkgDir -Recurse -Force      # %LOCALAPPDATA%\Microsoft\WinGet\Packages\Microsoft.Aspire__DefaultSource
Remove-Item $link -Force                 # %LOCALAPPDATA%\Microsoft\WinGet\Links\aspire.exe
Remove-Item $arpKey -Recurse -Force      # HKCU:\Software\Microsoft\Windows\CurrentVersion\Uninstall\Microsoft.Aspire__DefaultSource

This is awkward for anyone running the dogfood path repeatedly (PR validation, CI runs of prepare-installer-artifacts.yml, developer iteration). It also leaves contributors who attempt winget uninstall confused about why it didn't work.

What should happen

eng/winget/dogfood.ps1 -Uninstall should detect the __DefaultSource install shape and tear it down via the same three-step manual cleanup, rather than relying on winget uninstall. If winget itself has a documented way to uninstall a LocalManifestFiles install in newer releases, prefer that.

Possibly out of our control

The root cause may be in winget-cli rather than in our scripts — winget uninstall arguably should work against any package it can find in the ARP registry regardless of source identifier. If so, file upstream at https://github.com/microsoft/winget-cli and have dogfood.ps1 -Uninstall work around it in the meantime.

Context

Surfaced while writing the Windows test runbook for #17919. The full followups doc is at PR #17919 comment.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-engineering-systemsinfrastructure helix infra engineering repo stufftriage:bot-seenAspire triage bot has seen this issue

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions