Skip to content

Audit Sources Changed event triggers Package Manager UI to refresh#7022

Merged
donnie-msft merged 6 commits intodevfrom
dev-donnie-msft-auditPmuiRefresh
Jan 16, 2026
Merged

Audit Sources Changed event triggers Package Manager UI to refresh#7022
donnie-msft merged 6 commits intodevfrom
dev-donnie-msft-auditPmuiRefresh

Conversation

@donnie-msft
Copy link
Copy Markdown
Contributor

@donnie-msft donnie-msft commented Jan 1, 2026

Bug

Fixes: NuGet/Home#14688

Description

The Package Manager UI now automatically refreshes and correctly reflects vulnerability data with the new state of the vulnerability resources.
For example, adding/deleting an Audit Source from VS Options will now either show/not-show package vulnerabilities (if that audit source was the sole provider of vulnerability data for the solution).

  1. Removes the legacy PackageSourcesChanged event from the SourcesService and the listener from the PM UI PackageManagerControl.

  2. Settings.SettingsChanged triggers a new RefreshAfterSettingsChanged event which covers the previous PackageSourcesChanged event (now removed) and the new behavior around changes to audit sources.

  3. UI Refresh Behavior:

    • Saves UserSettings and reads the selected package source to ensure its maintained after refresh (Or the first package source is selected if the user's selected package source got deleted).
    • Vulnerability service is recreated with new audit sources
    • Packages list is refreshed after any NuGet.Config change via FileWatcher events.
  4. This PR moves us closer towards completing Remove or improve configuration change events Home#8479

PR Checklist

@donnie-msft donnie-msft requested a review from a team as a code owner January 1, 2026 01:56
Comment thread src/NuGet.Core/NuGet.Configuration/PackageSource/PackageSourceProvider.cs Outdated
Comment thread src/NuGet.Clients/NuGet.PackageManagement.UI/Xamls/PackageManagerControl.xaml.cs Outdated
@donnie-msft donnie-msft force-pushed the dev-donnie-msft-auditPmuiRefresh branch from 44fb822 to 24615bf Compare January 14, 2026 00:09
@donnie-msft donnie-msft force-pushed the dev-donnie-msft-auditPmuiRefresh branch 2 times, most recently from 65ea9b8 to 27a8a90 Compare January 15, 2026 17:39
Comment thread src/NuGet.Clients/NuGet.PackageManagement.UI/Xamls/PackageManagerControl.xaml.cs Outdated
@donnie-msft donnie-msft force-pushed the dev-donnie-msft-auditPmuiRefresh branch from 27a8a90 to 1c7c9c7 Compare January 16, 2026 01:58
Copy link
Copy Markdown
Member

@zivkan zivkan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

customer experience improvement, with 60 fewer lines. Fantastic! 👍

@donnie-msft donnie-msft merged commit 0dc743a into dev Jan 16, 2026
17 of 18 checks passed
@donnie-msft donnie-msft deleted the dev-donnie-msft-auditPmuiRefresh branch January 16, 2026 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Ensure PM UI refreshes when audit sources are updated

3 participants