Upgrade to linq2db v6 / EF Core 10#2282
Conversation
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
linq2db.AspNet+linq2db.EntityFrameworkCore 9.0.0 (v5 API) → linq2db.Extensions 6.2.1 + linq2db.EntityFrameworkCore 10.3.0 (v6 API). EF Core 9.0.x → 10.0.7, Npgsql 9→10, NeinLinq 7.3→7.4, OpenIddict 7.1→7.5, Gridify 2.17→2.19. Robin's PR #2264 handled everything else in the .NET 10 bump; this PR covers only the linq2db/EF Core upgrade and its specific workarounds. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
linq2db v6 changed how json_each expressions are translated: it now fires ExpressionMethodAttribute substitutions at materialization time as well as in queries, which breaks the IList<T> jsonb columns (SemanticDomains, PublishIn). Shadow EF Core properties carry the raw JSON value into the linq2db query layer so json_each rewrites work without affecting entity materialization. See LINQ2DB-V6-NOTES.md for the full investigation and attempt history. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
linq2db v6's SqlTransparentExpression has a broken static constructor that crashes on Android at startup (AOT static-ctor ordering issue). A Cecil-based MSBuild build task patches the IL at build time to nop out the offending ctor. SqlTransparentExpressionCctorRepro.cs documents the crash-reproduction test. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…dates RichMultiString gains an explicit null-setter so the typed IDictionary<,> implementation satisfies EF Core 10's stricter property requirements. Entry and Sense get minor model adjustments. Snapshot/test expectations updated for EF Core 10 query output changes. FluentAssertions global config pinned to alpha.5 to avoid the 8.x O(N!) BeEquivalentTo regression in CI. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Advances from 50b0e2da (Robin's PR #2264 base) to 96a75b26 which adds the HasCommit TOCTOU fix: the commit-presence check now happens inside the lock in DataModel.Add, preventing a race where two concurrent callers could both pass the check and then collide on insert. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
8367545 to
c687e40
Compare
|
The latest updates on your projects. Learn more about Argos notifications ↗︎
|
C# Unit Tests165 tests 165 ✅ 26s ⏱️ Results for commit 713bafc. ♻️ This comment has been updated with latest results. |
Extract ReplaceBodyWith helper, use Type.EmptyTypes ctor lookup for NotImplementedException, drop a duplicate <IsPackable>, fill in the upstream PR URL (linq2db/linq2db#5546). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The linq2db v6 + EF Core 10 work in 8d2b22a and 525cfd7 accidentally reverted PR #2278 ('Use named GUIDs for predefined-data seed commits'). This restores PreDefinedData, CrdtProjectsService, CurrentProjectService, the MiniLcmApiFixture call site, and the UUIDNext PackageReference, while keeping the intended linq2db.AspNet -> linq2db.Extensions rename.
EF Core 10's Model.ToDebugString output drops empty 'DiscriminatorProperty:' annotations, emits explicit Required/Optional on navigations, and reports its own version. All cosmetic; no model change.
- Drop a stale TODO and a "v6 dropped MakeTryConvert" comment that don't earn their keep - Tighten the Sql.Alias / ExposeExpressionVisitor comment to name the specific linq2db version it describes - Reword the RichMultiString JsonPatch repro test comment to focus on what it actually covers (Entry-routed patch via IDictionary.Add) - Swap RichMultiString.CopyTo / Remove back to their original order
10.0.7 -> 10.0.8 across AspNetCore / EntityFrameworkCore / Extensions / System.* / OpenApi, and 10.5.0 -> 10.6.0 for the Extensions rolling packages (Caching.Hybrid, Http.Resilience, ServiceDiscovery, TimeProvider.Testing). DbModel snapshot follows EF Core's ProductVersion. Held back deliberately: - linq2db 6.2.1 / linq2db.EntityFrameworkCore 10.3.0 — upstream PR #5546 (SqlTransparentExpression cctor fix that would let us drop the IL patcher) targets linq2db 6.4.0 and is not yet merged. 10.4.0 ships 6.3.0 and still has the buggy reflection, so bumping buys nothing. - FluentAssertions 7.0.0-alpha.5 — pinned to dodge an 8.x BeEquivalentTo perf regression that pushes FwLite CI past its 60-min timeout.
Upgrades linq2db v5→v6 (linq2db.EntityFrameworkCore 9.0.0→10.3.0) and EF Core 9→10. The general .NET 10 package bump (MAUI, Quartz migration, routes, WritingSystemId TypeConverter, RichMultiString IDictionary<,>, harmony to 50b0e2da) was already merged by PR #2264. This PR adds only what Robin did not do.
Key changes:
Directory.Packages.props)SqlTransparentExpressionhas a broken static ctor that crashes Android on first CRDT save; a Cecil-based MSBuild task nops it out at build time