NuGet / Home

Repo for NuGet Client issues
Other
1.5k stars 252 forks source link

Latest NuGet Version not displaying correctly in Visual Studio Code #13704

Open Kesavaraman123 opened 2 months ago

Kesavaraman123 commented 2 months ago

Impact

Other

Describe the bug

Hi Team,

In Visual Studio Code, our Syncfusion NuGet packages are not displaying the correct latest version number. For example, the latest version of the Syncfusion.Blazor (https://www.nuget.org/packages/Syncfusion.Blazor/26.2.9) NuGet package is 26.2.9, but it is incorrectly showing 18.1.0.42 as the latest version in Visual Studio Code.

We discovered that when retrieving the version list using the NuGet Extension in Visual Studio Code (via NuGet API - https://api.nuget.org/v3-flatcontainer/syncfusion.blazor/index.json), the versions are fetched in the wrong order, leading to the incorrect version (18.1.0.42) being marked as the latest. This issue is affecting various Syncfusion NuGet packages, each showing different incorrect versions as the latest. Could you please investigate and resolve this issue as soon as possible? image

Regards, V. Kesavaraman

Repro Steps

  1. Open Visual Studio Code
  2. Open Blazor Project
  3. Install Syncfusion.Blazor NuGet package in Lower version (eg; 25.1.35)
  4. Try to update Syncfusion.Blazor NuGet package to latest version.
  5. 18.1.0.42 is showing as latest version but actual latest version is 26.2.9 image

Expected Behavior

For Syncfusion.Blazor NuGet package 26.2.9 version has to be shown as latest version. image

Screenshots

image

Additional Context and logs

No response

joelverhagen commented 2 months ago

The V3 protocol does not document which order the versions are returned in. NuGet.org' sorts them in ascending order (lowest to highest, by SemVer). https://learn.microsoft.com/en-us/nuget/api/package-base-address-resource

It appears either VS Code uses the original order or also sorts them in ascending order, based on your screenshot.

It does appear wrong that the "latest" word is next to the lowest version 18.1.0.42. That looks like a bug. Moving to NuGet/Home which is where we track client issues.

jeffkl commented 1 month ago

Team Triage: @jebriede should we move this to the backlog?