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
Same scenario as #29789, except that this also did not work in EF Core 6.0 and uses the in-memory provider.
Microsoft.EntityFrameworkCore.DbUpdateConcurrencyException
Attempted to update or delete an entity that does not exist in the store.
at Microsoft.EntityFrameworkCore.InMemory.Storage.Internal.InMemoryTable`1.Delete(IUpdateEntry entry, IDiagnosticsLogger`1 updateLogger) in C:\github\efcore\src\EFCore.InMemory\Storage\Internal\InMemoryTable.cs:line 229
at Microsoft.EntityFrameworkCore.InMemory.Storage.Internal.InMemoryStore.ExecuteTransaction(IList`1 entries, IDiagnosticsLogger`1 updateLogger) in C:\github\efcore\src\EFCore.InMemory\Storage\Internal\InMemoryStore.cs:line 179
at Microsoft.EntityFrameworkCore.InMemory.Storage.Internal.InMemoryDatabase.SaveChangesAsync(IList`1 entries, CancellationToken cancellationToken) in C:\github\efcore\src\EFCore.InMemory\Storage\Internal\InMemoryDatabase.cs:line 67
at Microsoft.EntityFrameworkCore.ChangeTracking.Internal.StateManager.SaveChangesAsync(IList`1 entriesToSave, CancellationToken cancellationToken) in C:\github\efcore\src\EFCore\ChangeTracking\Internal\StateManager.cs:line 1264
at Microsoft.EntityFrameworkCore.ChangeTracking.Internal.StateManager.SaveChangesAsync(StateManager stateManager, Boolean acceptAllChangesOnSuccess, CancellationToken cancellationToken) in C:\github\efcore\src\EFCore\ChangeTracking\Internal\StateManager.cs:line 1363
at Microsoft.EntityFrameworkCore.DbContext.SaveChangesAsync(Boolean acceptAllChangesOnSuccess, CancellationToken cancellationToken) in C:\github\efcore\src\EFCore\DbContext.cs:line 771
at Microsoft.EntityFrameworkCore.DbContext.SaveChangesAsync(Boolean acceptAllChangesOnSuccess, CancellationToken cancellationToken) in C:\github\efcore\src\EFCore\DbContext.cs:line 793
at Microsoft.EntityFrameworkCore.UpdatesTestBase`1.<>c__DisplayClass6_0.<<Can_change_type_of_pk_to_pk_dependent_by_replacing_with_new_dependent>b__1>d.MoveNext() in C:\github\efcore\test\EFCore.Specification.Tests\UpdatesTestBase.cs:line 78
--- End of stack trace from previous location ---
at Microsoft.EntityFrameworkCore.TestUtilities.TestHelpers.<>c__DisplayClass35_0`1.<<ExecuteWithStrategyInTransactionAsync>b__0>d.MoveNext() in C:\github\efcore\test\EFCore.Specification.Tests\TestUtilities\TestHelpers.cs:line 361
--- End of stack trace from previous location ---
at Microsoft.EntityFrameworkCore.ExecutionStrategyExtensions.<>c__7`1.<<ExecuteAsync>b__7_0>d.MoveNext() in C:\github\efcore\src\EFCore\Storage\ExecutionStrategyExtensions.cs:line 238
--- End of stack trace from previous location ---
at Microsoft.EntityFrameworkCore.TestUtilities.TestHelpers.ExecuteWithStrategyInTransactionAsync[TContext](Func`1 createContext, Action`2 useTransaction, Func`2 testOperation, Func`2 nestedTestOperation1, Func`2 nestedTestOperation2, Func`2 nestedTestOperation3) in C:\github\efcore\test\EFCore.Specification.Tests\TestUtilities\TestHelpers.cs:line 343
at Microsoft.EntityFrameworkCore.UpdatesInMemoryTestBase`1.ExecuteWithStrategyInTransactionAsync(Func`2 testOperation, Func`2 nestedTestOperation1, Func`2 nestedTestOperation2) in C:\github\efcore\test\EFCore.InMemory.FunctionalTests\UpdatesInMemoryTestBase.cs:line 42
at Microsoft.EntityFrameworkCore.UpdatesTestBase`1.Can_change_type_of_pk_to_pk_dependent_by_replacing_with_new_dependent(Boolean async) in C:\github\efcore\test\EFCore.Specification.Tests\UpdatesTestBase.cs:line 66
at Xunit.Sdk.TestInvoker`1.<>c__DisplayClass48_0.<<InvokeTestMethodAsync>b__1>d.MoveNext() in /_/src/xunit.execution/Sdk/Frameworks/Runners/TestInvoker.cs:line 264
--- End of stack trace from previous location ---
at Xunit.Sdk.ExecutionTimer.AggregateAsync(Func`1 asyncAction) in /_/src/xunit.execution/Sdk/Frameworks/ExecutionTimer.cs:line 48
at Xunit.Sdk.ExceptionAggregator.RunAsync(Func`1 code) in /_/src/xunit.core/Sdk/ExceptionAggregator.cs:line 90
The text was updated successfully, but these errors were encountered:
We recommend against using the in-memory provider for testing--see Testing EF Core Applications. While we have no plans to remove the in-memory provider, we will not be adding any new features to this provider because we believe valuable development time is better spent in other areas. When feasible, we plan to still fix regressions in existing behavior.
Same scenario as #29789, except that this also did not work in EF Core 6.0 and uses the in-memory provider.
The text was updated successfully, but these errors were encountered: