Add packaged source fallback for noninteractive runs#6347
Open
PrzemyslawKlys wants to merge 7 commits into
Open
Add packaged source fallback for noninteractive runs#6347PrzemyslawKlys wants to merge 7 commits into
PrzemyslawKlys wants to merge 7 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📖 Description
Fixes packaged source initialization for noninteractive runs where the MSIX source package cannot be deployed for the current user session.
In this case, opening the packaged source can fail before the source index is available, which leaves commands such as
winget listunable to query the defaultwingetsource.This change adds a local fallback copy of the packaged source index. When packaged deployment is blocked in a noninteractive context, winget can open the fallback source data instead of failing the source open completely.
The fallback is kept in sync after successful packaged source updates and is only preferred when it is newer or when the packaged source cannot be opened. Invalid or unusable fallback data is treated as missing so future source updates can repair it.
🔗 References
Fixes #6334.
🔍 Validation
Validated with focused repository-core build coverage and a live noninteractive Windows Server 2025 remoting scenario:
wingetsource resultswinget listsuccessfully using thewingetsourceAlso validated focused source fallback behavior around:
✅ Checklist
📋 Issue Type
Microsoft Reviewers: Open in CodeFlow