Netcore 2.1.1 release leads to app failing to run
the specified version of microsoft.netcore.app or microsoft.aspnetcore.app was not found.
http error 500.31 - ancm failed to find native dependencies
resolving conflicts for netcoreapp version v3 1
change the projects reference to the package to widen its version constraints
found conflicts between different versions of microsoft extensions configuration abstractions
install reference microsoft extensions configuration 2.2 0 directly to project
It seems there is suddenly something out of sync with asp.net core packages.
It looks like
Microsoft.AspNetCore.App 2.1.1 was released 16 hours ago on nuget.org but only 158 downloads, and apparently I'm one of the downloaders.
.csproj file is like this:
<Project Sdk="Microsoft.NET.Sdk.Web"> <PropertyGroup> <TargetFramework>netcoreapp2.1</TargetFramework> </PropertyGroup> <ItemGroup> <ProjectReference Include="..\cloudscribe.Web.Navigation\cloudscribe.Web.Navigation.csproj" /> <ProjectReference Include="..\cloudscribe.Web.SiteMap\cloudscribe.Web.SiteMap.csproj" /> <ProjectReference Include="..\cloudscribe.Web.SiteMap.FromNavigation\cloudscribe.Web.SiteMap.FromNavigation.csproj" /> </ItemGroup> <ItemGroup> <PackageReference Include="Microsoft.AspNetCore.App" Version="2.1.*" /> <PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="2.1.*" /> </ItemGroup> </Project>
It builds but when I try to run it I get:
It was not possible to find any compatible framework version The specified framework 'Microsoft.AspNetCore.App', version '2.1.1' was not found. - Check application dependencies and target a framework version installed at: C:\Program Files\dotnet\ - Installing .NET Core prerequisites might help resolve this problem: http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409 - The .NET Core framework and SDK can be installed from: https://aka.ms/dotnet-download - The following versions are installed: 2.1.0 at [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
If I change my version for Microsoft.AspNetCore.App to 2.1.0 and do dotnet restore I get this:
C:_c\cloudscribe.Web.Navigation\src\NavigationDemo.Web\NavigationDemo.Web.csproj : error NU1107: Version conflict detected for Microsoft.AspNetCore.Antiforgery. Reference the package directly from the project to resolve this issue. C:_c\cloudscribe.Web.Navigation\src\NavigationDemo.Web\NavigationDemo.Web.csproj : error NU1107: NavigationDemo.Web -> cloudscribe.Web.Navigation -> Microsoft.AspNetCore.Mvc.Razor 2.1.1 -> Microsoft.AspNetCore.Mvc.ViewFeatures 2.1.1 -> Microsoft.AspNetCore.Antiforgery (>= 2.1.1) C:_c\cloudscribe.Web.Navigation\src\NavigationDemo.Web\NavigationDemo.Web.csproj : error NU1107: NavigationDemo.Web -> Microsoft.AspNetCore.App 2.1.0 -> Microsoft.AspNetCore.Antiforgery (= 2.1.0). Restore failed in 3.54 sec for C:_c\cloudscribe.Web.Navigation\src\NavigationDemo.Web\NavigationDemo.Web.csproj.
I suppose that is partly due to the other projects in my solution with dependencies like this:
<PackageReference Include="Microsoft.AspNetCore.Mvc" Version="2.1.*" /> <PackageReference Include="Microsoft.Extensions.Caching.Abstractions" Version="2.1.*" /> <PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="2.1.*" /> <PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="2.1.*" /> <PackageReference Include="Microsoft.Extensions.Options" Version="2.1.*" /> <PackageReference Include="Newtonsoft.Json" Version="11.0.*" /> <PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="2.1.*" /> <PackageReference Include="Microsoft.AspNetCore.Mvc.Razor" Version="2.1.*" /> <PackageReference Include="Microsoft.AspNetCore.Mvc.Abstractions" Version="2.1.*" />
There does not seem to be an updated sdk for
2.1.1 but the availability of
Microsoft.AspNetCore.App 2.1.1 on GitHub seems to be breaking things for me.
Your problem is this line of your
<PackageReference Include="Microsoft.AspNetCore.App" Version="2.1.*" />
* is saying to pick the latest 2.1 version of that Nuget package. For many packages this would be perfectly fine. However, v2.1.1 of that package requires a matching v2.1.1 SDK to also be installed. As of right now it it not available (it's currently blocked).
However, if you read the Migrate from ASP.NET Core 2.0 to 2.1 docs, you will see this:
Replace the version specified "Microsoft.AspNetCore.All" package reference with the versionless "Microsoft.AspNetCore.App" package reference.
The version is now inferred by the version of the SDK you are targetting. This means your
csproj should now contain this:
<PackageReference Include="Microsoft.AspNetCore.App" />
After upgrading to ASP.NET Core 2.1, get error that project will use , App version 2.1.0, but with current settings, version would be used Please see attached a new project, that I want to use with .Net 2.1.1 then existing ( not changed) solution start to failed with the above error. following this pattern if you are upgrading from previous releases (1.x Linked pull requests. Azure DevOps VSTS .netcore build failing, but works fine on my PC. Netcore 2.1.1 release leads to app failing to run. 1. Target specific dependencies NuGet. 3.
The 2.1.1 (preview) SDK is available on their GitHub.
You can download directly here:
We are still waiting on the official SDK...
If you are having trouble building, add the following to your
<PropertyGroup> <TargetLatestAspNetCoreRuntimePatch>true</TargetLatestAspNetCoreRuntimePatch> </PropertyGroup>
Official 2.1.1 SDK now released: https://www.microsoft.com/net/download/thank-you/dotnet-sdk-2.1.301-windows-x64-installer
WARNING - updating to Microsoft.AspNetCore.App (2.1.1), @cocowalla you are running into a known issue with the 2.1.0 package and 2.1.300 SDK. I recommend installing the latest .NET Core SDK on any app built for the .app package <= 2.1.5 will run on the 2.1.5 runtime if it is installed. if you install a newer version, say 2.1.6, it will automatically use this one. there is no need to update the NuGet Package unless you specifically don't want an app to run on a version lower than the one selected.
In addition to other suggestions, I needed to up the Microsoft.NetCore.App to 2.1.1. Since I couldn't do it via the UI, adding the following to the .csproj worked.
<code> <PackageReference Include="Microsoft.NetCore.App" Version="2.1.1" /> </code>
Remove the .NET Core runtime and SDK, NET Core Runtime and SDK are currently installed, and then, how to Additionally, newer releases of the . NET CLI has options you can use to list the versions of the SDK and runtime that are installed on your machine. NET Core uses the Windows Apps & features dialog to remove versions of the . il semble qu'il y ait soudainement quelque chose de désynchronisé avec asp.net paquets de base. Il ressemble à Microsoft.AspNetCore.App 2.1.1 a été libéré il y a 16 heures nuget.org mais seulement 158 téléchargements, et apparemment je suis l'un des téléchargeurs.
I had the same issue. Another option is, in NuGet Package Manager, rollback Microsoft.AspNetCore.All, Microsoft.AspNetCore.Rewrite, and Microsoft.NETCore.App to versions 2.1.0.
Troubleshoot ASP.NET Core on Azure App Service and IIS , Provides troubleshooting advice for apps deployed to IIS or running on IIS NET Core preview releases aren't deployed to Azure App Service by default. Failure to disable the stdout log can lead to app or server failure. Failure to disable the stdout log can lead to app or server failure. There's no limit on log file size or the number of log files created. Only use stdout logging to troubleshoot app startup problems. For general logging in an ASP.NET Core app after startup, use a logging library that limits log file size and rotates logs.
The wildcard version number package references is weird to me. That doesn't happen by default, so either you or one of your team members did that. I don't know if that's the source of at least some of your issues or not, but I'd start by changing them to full version references. NuGet packages are not committed with your project, so having wildcards can lead to strange build issues, particularly in automated builds, when you're developing against one version but a different version is restored later. If you want to upgrade a package, that should be an explicit choice, so you can then verify that all your code still functions as it should post-upgrade.
Also worth noting, since 2.1, code generation has been rolled in, so you should not be explicitly referencing any CodeGen packages.
As far as solving the current issue goes. You may be having some issues with your package cache. In Visual Studio, go to Tools > NuGet Package Manager > Package Management Settings, and then click the "Clear All NuGet Cache(s)" button.
That should prompt a redownload of all your projects NuGet packages, and may be enough to solve the issue. If not, I'd recommend cleaning all your projects and then going into the directory for each and manually deleting both the
obj directories. Then, rebuild your solution.
Chapter 1. Using .NET Core 2.1 on Red Hat Enterprise Linux .NET , NET Core channel for Red Hat Enterprise 7 Server, Red Hat Enterprise 7 This may lead to issues in programs that do not expect a different version of libcurl . Use the following command to publish a framework-dependent application. $ dotnet dotnet restore -r rhel.7-x64 $ dotnet publish -f netcoreapp2.1 -c Release -r A given SDK will support a fixed set of frameworks, typically capped to the target framework of the runtime(s) it includes. For example, the .NET Core 2.0 SDK includes the .NET Core 2.0 runtime, which is an implementation of the netcoreapp2.0 target framework.
.NET Core Buildpack, Your app fails to stage because it runs out of space, exceeding the maximum allowable disk quota. You have added pre-release packages to test a new feature NETSDK1061: The project was restored using Microsoft.NETCore.App version 2.1.3, but with current settings, version 2.1.3-servicing-26724-03 would be used instead. To resolve this issue, make sure the same settings are used for restore and for subsequent operations such as build or publish.
Problems with .NET unit testing – JetBrains Rider Support, NET Core version in case you have . I tried creating a Fresh Unit Test project Using dotnet new xunit and wrote a Compression.dll in application domain 1:clrhost This leads me to believe that there must be something about this We are unable to run tests without rebuilding all dependencies for Hi, I am trying to build the cli and having one unit test failing, referencing 'Microsoft.NETCore.App' version '2.0.9' Steps to reproduce Check out release/2.1.2xx and build it on Amazon Linux: ./build.sh --linux-portable --configuration
Exploring the Microsoft.AspNetCore.App shared framework in ASP , NET Core apps, by moving to a system of shared frameworks instead But bug fixes arrived shortly after release, and individual packages evolved at different rates. slow NuGet restore times due to the sheer number of packages, and only rolls-forward when your app would otherwise be unable to run. The dotnet build command builds the project and its dependencies into a set of binaries. The binaries include the project's code in Intermediate Language (IL) files with a .dll extension. Depending on the project type and settings, other files may be included, such as: An executable that can be used to run the application, if the project type
- for the moment I can solve the problem by pinning all my packaged deps to 2.1.0 and close solution and delete the bin and obj folders. Then after re-opening my solution it builds and runs. As @khellang mentioned on gitter, maybe the 2.1.1 release is still in progress and not all ready yet.
- Nuget usually takes some time until the cache is updated and a new verision of a specific package is visible on Nuget, that may be causing the issue. What may help is to install the latest SDK which should contain the latest ASP.NET Core installed in the local package cache (which is then located in C:\Program Files\dotnet\shared\Microsoft.NETCore.App and C:\Program Files\dotnet\sdk\NuGetFallbackFolder respectively and used as fallback by nuget)
- @Tseng I think the problem may be because they haven't yet shipped a new sdk since the 2.1.0 release. The downloads don't show a new sdk version yet.
- It is failing because you don;t have a matching SDK installed. Unfortunately Microsoft release the Nuget packages before the SDK installer so you either have to target a specific framework version or be patient and wait for the SDK.
- Probably you need to wait until the .NET Core SDK 2.1.1 is available which u can find [here](microsoft.com/net/download/windows ). If u can't wait, check out the early access.
- This does not work with me, I get Version Conflict errors which asked me to reference packages directly like Microsoft.AspNetCore.Authentication, Microsoft.AspNetCore.Authentication.Cookies, etc. which eventually ended in a cycling reference error with Microsoft.AspNetCore.Cryptography.Internal requiring Microsoft.AspNetCore.Cryptography.KeyDerivation first and vice versa.
- No, that is a preview release only. The final release is not yet available. It is stuck in publishing for some technical reason. Do not install this on a production machine!
- I've given a more complete answer to this problem that will work for all future releases.
- No, don't do this please. For v2.1 and above you no longer specify a version number for
Microsoft.AspNetCore.App, it is automatically done for you.
- This is NOT true. Currently, without specifying a version, it pulls 2.1.0. IF you want to pull 2.1.1, you MUST specify the version. I've verified this on 10+ projects so far. This may change in the very near future, but today, it is the case. Please verify before you downvote.