Upgrade to ASP.NET Core 3.1
See original GitHub issueI tried creating a brand new web app with asp.net core 3 and adding in Piranha, but it will not work. I believe it is the same issue as references here: https://github.com/aspnet/AspNetCore/issues/8254
During startup the app throws the exception below. Any idea when ASP.NET Core 3 will be supported?
Exception has occurred: CLR/System.TypeLoadException
An unhandled exception of type 'System.TypeLoadException' occurred in WebForm.dll: 'Could not load type 'Microsoft.AspNetCore.Mvc.MvcJsonOptions' from assembly 'Microsoft.AspNetCore.Mvc.Formatters.Json, Version=3.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'.'
at ManagerModuleExtensions.AddPiranhaManagerOptions(IMvcBuilder builder)
at WebForm.Startup.ConfigureServices(IServiceCollection services) in /media/data/CrossBound Technology/Clients/Portage/WebForm/WebForm/Startup.cs:line 24
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.InvokeCore(Object instance, IServiceCollection services)
at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass9_0.<Invoke>g__Startup|0(IServiceCollection serviceCollection)
at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.Invoke(Object instance, IServiceCollection services)
at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass8_0.<Build>b__0(IServiceCollection services)
at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.UseStartup(Type startupType, HostBuilderContext context, IServiceCollection services)
at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass12_0.<UseStartup>b__0(HostBuilderContext context, IServiceCollection services)
at Microsoft.Extensions.Hosting.HostBuilder.CreateServiceProvider()
at Microsoft.Extensions.Hosting.HostBuilder.Build()
at WebForm.Program.Main(String[] args) in /media/data/CrossBound Technology/Clients/Portage/WebForm/WebForm/Program.cs:line 10
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (5 by maintainers)
Top Results From Across the Web
Migrate from ASP.NET Core 3.0 to 3.1
In this article Prerequisites Update .NET Core SDK version in global.json Update the target framework Update package references Update Docker images React to...
Read more >How To Upgrade ASP.NET Core 2.1 To ASP.NET Core 3.1 ...
The very first step for migration is changing the target framework. For this: right-click on Project-> properties and then in project properties ...
Read more >The Obligatory "How I Upgraded To .NET Core 3.1" Post
The very first step was to update the project files to target netcoreapp31 . You can also remove the explicit references to the...
Read more >Migrating from 2.1 to 3.1 .Net Core, What is the ...
I am upgrading my project from 2.1 to 3.1 .Net Core. I have updated all the dependencies but facing issues in following dependencies....
Read more >Reasons to Upgrade .NET Core 2.1 to 3.1 Version
NET Core, you can update to the latest version using a few simple steps. First, check to see what version of .NET Core...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi there. There are several issues with running Piranha in .NET Core 3. First off, like you noticed, you have to replace the new JSON serializer with Newtonsoft as the new serializer can’t serialize/deserialize abstract classes. Secondly there’s a difference in how the change tracker of Entity Framework Core 3 works which breaks the application.
We have a separate branch where we’re almost done with the 3.0 upgrade but it’s decided when it will be released as it’s not backwards compatible.
Regards
Hi @rengert 8.0 will be released in the next day or two. We’re just finalizing some things