1

We did 9.2 upgrade on our website and since NoReferences packages are removed, we have started the install & upgrade these packages by using NuGet's builtin ability to Ignore Dependencies.

But after that, when we tried to install a package with its dependencies, NuGet shows the following(in short), wants us to resolve these:

Attempting to gather dependency information for package 'Microsoft.AspNet.Mvc.5.2.4' with respect to project 'TheReference.Site.Business', targeting '.NETFramework,Version=v4.7.1'
Gathering dependency information took 1.69 min
Attempting to resolve dependencies for package 'Microsoft.AspNet.Mvc.5.2.4' with DependencyBehavior 'Lowest'
One or more unresolved package dependency constraints detected in the existing packages.config file. All dependency constraints must be resolved to add or update packages. If these packages are being updated this message may be ignored, if not the following error(s) may be blocking the current package operation: 'Sitecore.Analytics 9.2.0 constraint: Sitecore.Marketing.Search (>= 9.2.0)', 'Sitecore.Analytics 9.2.0 constraint: Sitecore.Marketing.xMgmt.ReferenceData (>= 9.2.0)', 'Sitecore.Analytics 9.2.0 constraint: Sitecore.CES.DeviceDetection (>= 9.2.0)', 'Sitecore.Analytics.Core 9.2.0 constraint: Sitecore.Xdb.Configuration (>= 9.2.0)',

How can we solve this issue without using PackageReference(which is not well supported) or directly referencing those dlls?

1 Answer 1

2

The problem with Ignore Dependencies, as you point out, is that it is a global setting. While it can be fine to pick and choose from Sitecore assemblies, which ones you want in your project - it is not so easy and obvious when it comes to other third party libraries. Like for example MVC, as you state in your example.

If you don't want to move to PackageReferences, I suggest you bite the bullet and do a regular reference to the Sitecore packages instead. Yes, it will bring in a tonne of references, but at least you don't have to maintain them. Or worry about them.

1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.