NuGet shows updates for MVC, Web Pages, Razor, but won't install them
asp.net-mvc, nuget
Solution
After two months, I have found the solution. The "packages" folder of my solution contained multiple versions of the problematic packages. For example, I had "Newtonsoft.Json.4.5.1" AND "Newtonsoft.Json.5.0.3" AND "Newtonsoft.Json.5.0.4" in there.
Manually deleting all the old versions, solved my problem.
In my opinion, this is really not something that should be happening in a released product. I would expect problems like this in alpha versions...
Problem
When I go into "Updates", I see updates are offered for Microsoft ASP.NET Razor (3.0.0), Microsoft ASP.NET Web Pages (3.0.0) and Microsoft ASP.NET MVC (5.0.0). This is weird, because those are the versions that are currently installed. When I press the "Update" button, I get asked which projects need to be updated (the solution contains 2 projects), both are selected AND grayed out. I press "OK", and nothing happens, I am just returned to the updates screen. Writing "update-package microsoft.aspnet.mvc" in the console just returns "No updates available for 'microsoft.aspnet.mvc' in project ''." for both projects. How can I install these supposed updates, or remove them from the available updates? Here are the packages.config files for the two projects: ``` <?xml version="1.0" encoding="utf-8"?> <packages> <package id="EntityFramework" version="6.0.1" targetFramework="net45" /> <package id="Microsoft.AspNet.Mvc" version="5.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.Razor" version="3.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebPages" version="3.0.0" targetFramework="net45" /> <package id="Microsoft.Bcl" version="1.1.6" targetFramework="net45" /> <package id="Microsoft.Bcl.Build" version="1.0.13" targetFramework="net45" /> <package id="Microsoft.Net.Http" version="2.2.18" targetFramework="net45" /> <package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net45" /> </packages> ``` . ``` <?xml version="1.0" encoding="utf-8"?> <packages> <package id="EntityFramework" version="6.0.1" targetFramework="net45" /> <package id="Microsoft.AspNet.Mvc" version="5.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.Razor" version="3.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebApi" version="5.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebApi.Client" version="5.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebApi.Core" version="5.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebApi.OData" version="5.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebApi.WebHost" version="5.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebPages" version="3.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebPages.Data" version="3.0.0" targetFramework="net45" /> <package id="Microsoft.AspNet.WebPages.WebData" version="3.0.0" targetFramework="net45" /> <package id="Microsoft.Data.Edm" version="5.6.0" targetFramework="net45" /> <package id="Microsoft.Data.OData" version="5.6.0" targetFramework="net45" /> <package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net45" /> <package id="Newtonsoft.Json" version="5.0.8" targetFramework="net45" /> <package id="System.Spatial" version="5.6.0" targetFramework="net45" /> </packages> ```