Repository navigation
Description
Package
CodoMetis.TypeKit.EntityFrameworkCore
Version
2.3.1 from nuget.org. release/2.4.0 has the same line (ValueObjectMapping.cs:77), so it is in 2.4.0 as it stands.
How does it fail?
Loudly, but only at run time. Restore and build are clean: the package asks for Microsoft.EntityFrameworkCore.Relational 10.0.12 or later with no ceiling, so NuGet takes 11.0.0 without a warning (no NU1605, no NU1608). The first value object EF maps then throws.
What you ran
A net11.0 console project, measured 2026-11-28:
<PackageReference Include="CodoMetis.TypeKit" Version="2.3.1" />
<PackageReference Include="CodoMetis.TypeKit.Generators" Version="2.3.1" />
<PackageReference Include="CodoMetis.TypeKit.EntityFrameworkCore" Version="2.3.1" />
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="11.0.0" />var options = new DbContextOptionsBuilder<Db>().UseSqlite(connection).UseTypeKit().Options;
using var db = new Db(options);
db.Database.EnsureCreated(); // throws
public readonly partial record struct OrderId : IValue<Guid>;
public class Order { public required OrderId Id { get; init; } }What you got
System.MissingMethodException: Method not found: 'Void Microsoft.EntityFrameworkCore.Storage.ValueConversion.ConverterMappingHints..ctor(
System.Nullable`1<Int32>, System.Nullable`1<Int32>, System.Nullable`1<Int32>, System.Nullable`1<Boolean>,
System.Func`3<IProperty, IEntityType, ValueGenerator>)'.
at CodoMetis.TypeKit.EntityFrameworkCore.ValueObjectMapping.Of`2..ctor()
at CodoMetis.TypeKit.EntityFrameworkCore.ValueObjectMapping.Factory.Visit[TValueObject,T]()
at CodoMetis.TypeKit.CompilerServices.GeneratedValueObjectAttribute`2.Accept[TResult](IValueObjectVisitor`1 visitor)
at CodoMetis.TypeKit.EntityFrameworkCore.ValueObjectMapping.For(GeneratedValueObjectAttribute valueObject)
at CodoMetis.TypeKit.EntityFrameworkCore.ValueObjectTypeMappingSourcePlugin.FindMapping(RelationalTypeMappingInfo& mappingInfo)
EF Core 11 removed the valueGeneratorFactory parameter of ConverterMappingHints' constructor, and the ValueGeneratorFactory property with it (read from the XML documentation files of 10.0.12 and 11.0.0: five parameters, then four). ValueObjectMapping.Of<,>'s constructor calls it for a temporary number, and the JIT resolves the call for every value object, so the wrapped type doesn't matter.
What you expected
Either the package runs on EF Core 11, or restore says it can't.
Who it reaches
Every application that has this package and moves to EF Core 11, which has been generally available since 2026-11-10. That includes every consumer of CodoMetis.ValueRanges.EFCore.PostgreSQL 11 and CodoMetis.EFCore.SchemaKit 11: both require EF Core 11, so neither can be installed beside this package today. CodoMetis.EFCore.SchemaKit's design note (section 11) expects NU1605 here; there is none.
What it means for 2.4.0
- It is a source break too. The
net11.0asset (A net11.0 target beside net10.0 (decision 120) #208) doesn't compile against EF Core 11 until a temporary number for a value-object key is given another way. net11.0: the EF Core satellite on EF Core 11 (nested complex keys, CAST stripping, primitive collections) #215's checks don't name it. - The fix sits behind decision 129 as things stand: 2.4.0 is tagged on a stable Metalama 2027.0, and this package has no Metalama dependency.
To decide
- Fix it only in 2.4.0 with the
net11.0asset, and until then say in the 2.3.x README that EF Core 11 isn't supported. - A 2.3.2 that runs on both lines from one
net10.0build, without the removed constructor. - A 2.3.2 that declares the ceiling,
[10.0.12, 11.0.0), so restore refuses EF Core 11 where today the first query does.
Environment
macOS arm64, .NET SDK 11.0.100 (10.0.404 beside it), runtime 11.0.0, EF Core 11.0.0, Metalama 2026.1.30.
Activity
CaffeinatedCoder commentedon Nov 28, 2026
State 2026-11-28. Fixed on the
net11.0asset. Local branchbuild/metalama-2027-preview(fromrelease/2.4.0, with #282 merged in), not pushed on 2026-11-28.net10.0andnet11.0; thenet11.0group requires EF Core 11.0.0. One line did not compile against EF Core 11, the one in the stack trace above.ConverterMappingHintsand ofCoreTypeMapping, and the selector's read of it). With nothing in its place 18 key tests fail onnet11.0. Decision 132 (new, on the branch): a value object overulongorchargenerated on add getsWrappedTypeValueGeneratorFactoryon the property. All key tests then pass on both targets.ulongkey until the application clears the factory (one line, in the README, held by a test); a--nativeaotcompiled model and a converter named by hand get the temporary value they lacked.net11.0, which are net11.0: the EF Core satellite on EF Core 11 (nested complex keys, CAST stripping, primitive collections) #215's. The weaving review is not done.Of the three ways above, the maintainer chose the first on 2026-11-28: the fix ships in 2.4.0, whose previews build on the current Metalama 2027 preview (decision 130, on the branch).
test: no provider's query context takes EF's service-provider count f…
test: the EF Core tests answer for what EF Core 11 translates, with a…