You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
AssemblyLoadContext.Resolving handler may not be thread safe #2134
We've started seeing occasional failures in our tests with the following exception:
Microsoft.EntityFrameworkCore.Scaffolding.Internal.CSharpRuntimeModelCodeGeneratorTest.Sqlite [FAIL]
System.TypeInitializationException : The type initializer for 'Microsoft.Data.Sqlite.SqliteConnection' threw an exception.
---- System.IO.FileLoadException : Could not load file or assembly 'Microsoft.Windows.SDK.NET, Culture=neutral, PublicKeyToken=null'. An operation is not legal in the current state. (0x80131509)
-------- System.InvalidOperationException : Operations that change non-concurrent collections must have exclusive access. A concurrent update was performed on this collection and corrupted its state. The collection's state is no longer correct.
Stack Trace:
D:\a\_work\1\s\src\Microsoft.Data.Sqlite.Core\SqliteConnection.cs(95,0): at Microsoft.Data.Sqlite.SqliteConnection..ctor()
As far as we can tell, this is being caused by your Microsoft.Data.SqlClient.SqlConfigurableRetryLogicLoader.Default_Resolving() handler not being thread safe.
changed the title [-]AssemblyLoadContext.Resolving handler not thread safe[/-][+]AssemblyLoadContext.Resolving handler may not be thread safe[/+]on Aug 22, 2023
Activity
bricelam commentedon Aug 22, 2023
Not, we're still not 100% sure it's your implementation. We're also following up in dotnet/runtime#90415
[-]AssemblyLoadContext.Resolving handler not thread safe[/-][+]AssemblyLoadContext.Resolving handler may not be thread safe[/+]JRahnama commentedon Aug 22, 2023
@bricelam is this M.D.SqlClient related issue or Sqlite?
jkotas commentedon Aug 22, 2023
This issue can be closed.
The EFCore problem is a bug in xunit: dotnet/runtime#90415 (comment).
Fix | Scope configurable retry logic assembly resolution to opt-in ca…
Fix | Scope configurable retry logic assembly resolution to opt-in ca…