Open leberechtreinhold opened 1 week ago
Hi I'm an AI powered bot that finds similar issues based off the issue title.
Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one and thumbs upping the other issue to help us prioritize it. Thank you!
Note: You can give me feedback by thumbs upping or thumbs downing this comment.
^ That crash happens with the package itself being null, here's the FindProvisionedPackages call.
Brief description of your issue
When running winget --list with scope machine on a Windows 10x86 build 17763, it crashes.
The reason is because PopulateIndexFromMSIX (https://github.com/microsoft/winget-cli/blob/6c54251308f91125f8fc8044f70fac69459295fe/src/AppInstallerRepositoryCore/Microsoft/PredefinedInstalledSourceFactory.cpp#L61) calls FindProvisionedPackages. This however seems to return a null value which is not catch by the catch hresult and is therefore a nullptr.
Looking at documentation, it does seem the minimum build would be 19041, not 17763, as stated in docs.
https://learn.microsoft.com/en-us/uwp/api/windows.management.deployment.packagemanager.findprovisionedpackages?view=winrt-22621
Steps to reproduce
Run winget --list with scope machine
Expected behavior
Not crash, return the base products. Since that specific os didnt have MSStore, it should be empty.
Actual behavior
Crash
Environment