Home: Nuget packages version conflict

Created on 11 Dec 2017  路  2Comments  路  Source: NuGet/Home

I have a project, which references the nuget package Xamarin.Forms(2.5.0.121934), and also references another project, which references the package Xamarin.Android.Support.v4(26.1.0.1)

I'm having this conflict

NU1107: Version conflict detected for Xamarin.Android.Support.Compat. Reference the package directly from the project to resolve this issue.
ProjectX -> ProjectY -> Xamarin.Android.Support.v4 26.1.0.1 -> Xamarin.Android.Support.Compat (= 26.1.0.1)
ProjectX -> Xamarin.Forms 2.5.0.121934 -> Xamarin.Android.Support.Design 25.4.0.2 -> Xamarin.Android.Support.Compat (= 25.4.0.2).

But Xamarin.Forms dependency to Xamarin.Android.Support.Design (>= 25.4.0.2) can be a greater package than version 25.4.0.2, and obviously the version 26.1.0.1 meets those requirements.

This conflict shouldn't happen as there is an obvious way to resolve it.

ByDesign

Most helpful comment

I know it is by design, but the design is horrible and should be changed. Having to add a lot of extra packages to the project and every project which uses this project is such an inconvenient solution, and one that makes no sense as this should work fine if nuget were designed correctly.

All 2 comments

Thanks for the feedback and suggestion, this is currently by design, the resolver fails with a helpful message letting the user select the appropriate package.

You can find more on the resolver here: https://docs.microsoft.com/en-us/nuget/consume-packages/dependency-resolution

I know it is by design, but the design is horrible and should be changed. Having to add a lot of extra packages to the project and every project which uses this project is such an inconvenient solution, and one that makes no sense as this should work fine if nuget were designed correctly.

Was this page helpful?
0 / 5 - 0 ratings