0

My problem is as such -

I have a .NET core webapi project [targeting 2.2]. Now while trying to run it, I get the following error as shown in the image -

enter image description here

I consulted this link --> HTTP Error 500.30 - ANCM In-Process Start Failure and https://github.com/aspnet/AspNetCore/issues/8980

tried by editing the .csproj file. Tried downgrading to netcoreapp2.1. Downgrading the assembly versions. Did not work. SO reverted back again.

Changed to 'InProcess' and 'Everyone'. But that did not work either. The same error message shows.

My .csproj file right now:

<Project Sdk="Microsoft.NET.Sdk.Web">

  <PropertyGroup>
    <TargetFramework>netcoreapp2.2</TargetFramework>
    <AspNetCoreHostingModel>Everyone</AspNetCoreHostingModel>
  </PropertyGroup>

  <ItemGroup>
    <PackageReference Include="Microsoft.AspNetCore.App" />
    <PackageReference Include="Microsoft.AspNetCore.Cors" Version="2.2.0" />
    <PackageReference Include="Microsoft.AspNetCore.Razor.Design" Version="2.2.0" PrivateAssets="All" />
    <PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="2.2.3" />
  </ItemGroup>

</Project>

Fact of the matter is I have .NET Core SDK and Runtimes upto version 3.1 installed on the environment. But still. I have tried several perms/combs of changing settings and sdk etc for the project so far. But it is eluding me. What is exactly the problem? I have a hunch it is something minute but crucial and it is eluding me. If you need farther details about project version/settings pl do let know, will share.

1 Answers1

0

Right now, this is my .csproj latest --

<Project Sdk="Microsoft.NET.Sdk.Web">

  <PropertyGroup>
    <TargetFramework>netcoreapp2.2</TargetFramework>
    <AspNetCoreHostingModel>Everyone</AspNetCoreHostingModel>
  </PropertyGroup>

  <ItemGroup>
    <PackageReference Include="Microsoft.AspNetCore.App" />
    <PackageReference Include="Microsoft.AspNetCore.Cors" Version="2.2.0" />
    <PackageReference Include="Microsoft.AspNetCore.Razor.Design" Version="2.2.0" PrivateAssets="All" />
    <PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="2.2.3" />
  </ItemGroup>

</Project>

Coincidentally or what I don't know, I seems to have stumbled upon the solution and the ideal settings myself and it is working now. Although I don't have the exact logical answer as to what and why, but yeah. The error is no more.

Thanks anyway,