Search code examples
azure-service-fabric

Unable to locate Dependency Microsoft.AspNet.Server.WebListener >= 1.0.0-rc1-final


I'm using the very latest ServiceFabric SDK (v1.4.87.9494) with VS2015 Update1 and the latest ASP.NET 5 RC1 update (v1.0.11125.0).

When I add an ASP.NET 5 WebApp to my ServiceFabric solution I am seeing an error in project.json that looks like this:

Unable to locate Dependency Microsoft.AspNet.Server.WebListener >= 1.0.0-rc1-final

I'm a super noob to ServiceFabric and ASP.NET 5, how do I go about debugging this?


Solution

  • This is a known (intermittent) issue that will be fixed in an upcoming SDK refresh. In the meantime, you should be able to work around it in one of two ways:

    Option 1: In the web project, open project.json, make some kind of cosmetic change (add a space or a newline) and save it. This will force a package restore, which should bring down the WebListener.

    Option 2: Explicitly add the WebListener package to the web project. Right-click on the web project, choose Manage NuGet Packages, then search for Microsoft.AspNet.Server.WebListener and install it.

    If neither of those work, we've occasionally seen cases where having numerous NuGet package sources exacerbates this problem. You can try de-selecting all sources except nuget.org and that generally fixes it.