Skip to content

NuGet claims downgrades (NU1605) for packages brought in through lineup #3541

Closed

Description

@ericstj

Copied from https://github.com/dotnet/corefx/issues/12114

Consider the following project.json:

{
  "dependencies": {
    "Newtonsoft.Json": "9.0.1"
   },
   "frameworks": {
     "netcoreapp1.0": {}
   },
   "runtimes": {
     "win7-x64": {}
   }
}

This restores without error. Now change it by updating the lineup for corefx packages (using source https://dotnet.myget.org/F/dotnet-core/api/v3/index.json)

{
  "dependencies": {
    "Newtonsoft.Json": "9.0.1",
    "Microsoft.NETCore.Targets": "1.0.3-preview1-24528-02"
   },
   "frameworks": {
     "netcoreapp1.0": {}
   },
   "runtimes": {
     "win7-x64": {}
   }
}

Restoring this results in downgrade warnings from NuGet

Detected package downgrade: System.Runtime from 4.3.0-preview1-24528-02 to 4.1.0
warn :  foo (>= 1.0.0) -> Newtonsoft.Json (>= 9.0.1) -> System.Collections (>= 4.0.11) -> runtime.any.System.Collections (>= 4.3.0-preview1-24528-02) -> System.Runtime (>= 4.3.0-preview1-24528-02)
warn :  foo (>= 1.0.0) -> Newtonsoft.Json (>= 9.0.1) -> System.Runtime (>= 4.1.0)
warn : Detected package downgrade: Microsoft.NETCore.Platforms from 1.0.2-preview1-24528-02 to 1.0.1
warn :  foo (>= 1.0.0) -> Newtonsoft.Json (>= 9.0.1) -> System.Runtime (>= 4.1.0) -> runtime.any.System.Runtime (>= 4.3.0-preview1-24528-02) -> System.Private.Uri (>= 4.3.0-preview1-24528-02) -> Microsoft.NETCore.Platforms (>= 1.0.2-preview1-24528-02)
warn :  foo (>= 1.0.0) -> Newtonsoft.Json (>= 9.0.1) -> System.Runtime (>= 4.1.0) -> Microsoft.NETCore.Platforms (>= 1.0.1)
warn : Detected package downgrade: Microsoft.NETCore.Platforms from 1.0.2-preview1-24528-02 to 1.0.1
warn :  foo (>= 1.0.0) -> Newtonsoft.Json (>= 9.0.1) -> System.Runtime.Extensions (>= 4.1.0) -> runtime.win.System.Runtime.Extensions (>= 4.3.0-preview1-24528-02) -> System.Private.Uri (>= 4.3.0-preview1-24528-02) -> Microsoft.NETCore.Platforms (>= 1.0.2-preview1-24528-02)
warn :  foo (>= 1.0.0) -> Newtonsoft.Json (>= 9.0.1) -> System.Runtime.Extensions (>= 4.1.0) -> Microsoft.NETCore.Platforms (>= 1.0.1)

I don't believe those should be considered downgrades given how the runtime packages are pulled in. /cc @davidfowl @rrelyea

Activity

  1. added this to the milestone on Feb 16, 2017
  2. Mohammed-El-Nabulsi commented on Oct 15, 2017

    @Mohammed-El-Nabulsi

    I'm having exactly the same issues but only when running the following command:

    dotnet publish --self-contained --runtime win-x64

  3. jainaashish commented on Oct 17, 2017

    @jainaashish

    @ericstj is this still a valid issue?

    @Mohammed-El-Nabulsi can you tell us more about your issue? and probably a repro solution?

  4. modified the milestones: Future-0, Backlog on Oct 17, 2017
  5. added
    Area:ErrorHandling
    and removed on Oct 17, 2017
  6. ericstj commented on Oct 17, 2017

    @ericstj
    Author

    Yes it is still valid. It'll be less prevalent moving forward (netcoreapp2.0 and later) as we are only using runtime.json to bring in our own private runtime packages with no dependencies, but the problem still exists for UAP10.0 and NETCoreApp 1.x.

  7. removed their assignment
    on Feb 14, 2018
  8. added
    Priority:3
    and removed on Apr 9, 2020
  9. changed the title [-]NuGet claims downgrades for packages brought in through lineup[/-] [+]NuGet claims downgrades (NU1605) for packages brought in through lineup[/+] on Jun 26, 2021
  10. added
    Status:Inactive
    on Apr 15, 2026
  11. dotnet-policy-service commented on Apr 15, 2026

    @dotnet-policy-service
    Contributor

    Due to lack of recent activity, this issue has been marked as a candidate for icebox cleanup. It will be closed if no further activity occurs within 14 more days. If the issue receives enough upvotes, it will be flagged with Triage:NeedsTriageDiscussion for team review.
    This process is part of the experimental Stale icebox issues cleanup we are currently trialing. Please share any feedback you might have in the linked issue.

  12. dotnet-policy-service commented on Apr 30, 2026

    @dotnet-policy-service
    Contributor

    This issue will now be closed since it had been marked Icebox cleanup candidate, but received no further activity in the past 14 days.

  13. removed this from the Backlog milestone on Apr 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Area:ErrorHandlingFunctionality:RestoreIcebox cleanup candidatePriority:3Status:InactiveStyle:PackageReferenceType:Bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions