I am trying to update a package known as ClientDependency
, which is needed for a Umbraco-built website's security feature. This has to be updated to the latest version 1.9.9
, which however cannot be found in NuGet.
I can only find 1.8.4
as the latest stable version in my solution, which is what I have been using for quite some time now.
Is there anyway I can update the package to the latest version? I'd prefer to have it updated via the package manager console, so that some automatic code updates can be applied, rather than copy-paste the dll manually from it source.
1) First,check whether you have
nuget.org
enabled as the data source of the package source. TheClientDependency
nuget package is undernuget.org
.Tools-->Options-->Nuget Package Manager-->Package Sources--> and make sure that you enable that link.
Also, check nuget.org in nuget package management UI.
2) Second, unload your project and enter
xxxx.csproj
file, please check whether your reference xml elements haveallowedVersions
node like this:allowedVersions
specifies the version range of this nuget package,[]
is equivalent to=
, which means that the current nuget can only be this version.(,12.0.3]
means version<=12.0.3
.So please check your
xxxx.csproj
file. I suggest you could deleteallowedVersions
node if not necessary.3) Third, I found that ClientDependency nuget package only has one version
1.9.9
and it seems that it abandons1.8.4
and in my side, l cannot get version1.8.4
.Perhaps it is because
ClientDependency
already exists as a brand new version1.9.9
. As for the old1.8.4
package, it may be broken, and the1.9.9
version package cannot be captured.So please search
ClientDependency
in the nuget package management UI and find out whether you can get version1.9.9
. After it, please uninstallClientDependency 1.8.4
and then install the new version1.9.9
.In addition, if you want to install the package version
1.9.9
by Package Manager Console. You can try these:1) If your issue is as tip one and two said, you can use this in Package Manager Console:
Update-Package ClientDependency -Version 1.9.9
2) If as tip 3 said:
You should first uninstall the old version and then install this new package: