efcore
efcore copied to clipboard
Xamarin.Forms App for Android crashes with disabled Shared Mono runtime
I use EntityFramework.Sqlite in my Xamarin.Forms project. It work fine in debug mode (Shared Mono runtime is enabled) But when i archive the release for Android without Shared Mono runtime - application crashes on first operations with context.
Exception message:
"The type initializer for 'Microsoft.EntityFrameworkCore.Sqlite.Query.ExpressionTranslators.Internal.SqliteCompositeMethodCallTranslator' threw an exception.
Value cannot be null.
Parameter name: key
Steps to reproduce
Buid in release with disabled "Shared Mono runtime"
context.Database.EnsureCreated(); threw an exception
Further technical details
Microsoft.EntityFrameworkCore.Sqlite.Core 2.2.4 Xamarin.Forms 4.0.0 (or 3.6.0)
Duplicate of #12460