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
Hold the timerange claim: the generated create script contains CREATE TYPE timerange AS RANGE and the multirange exists #155
area/range-setRangeSet and multirange algebraarea/rangesRange unions, variants and the shape enginespackage/efcoreAffects CodoMetis.ValueRanges.EFCore.PostgreSQLtestsAdds or changes tests only (oracles, harnesses); no library code
docs/efcore.md promises that HasPostgresRange("timerange", "time") "generates CREATE TYPE timerange AS RANGE (SUBTYPE = time) in your migrations" and that PostgreSQL 14+ auto-creates timemultirange. Verified 2026-10-18 that it holds: Npgsql's NpgsqlDatabaseCreator.CreateTables (what EnsureCreated calls) runs the model differ through the migrations SQL generator, the same generator migrations use, and the integration suite round-trips TimeRange columns and a RangeSet<TimeRange> as timemultirange. But no test states it: nothing asserts the script text or the pg_type rows, so the sentence is held only indirectly.
Preferred: scaffold the migration operations for the model through the design-time services and assert the generated SQL contains CREATE TYPE … AS RANGE ahead of the tables (an independent review scaffolded and applied a real migration on 2026-10-18 and confirmed the statement and the catalogue rows). Fallback, if hosting the design-time services is not cheap: Database.GenerateCreateScript() (translation-test project, no database).
Assert pg_type has timerange and timemultirange after EnsureCreated (integration).
Name both in claims.json as the holders of the doc sentence; a seed that drops the HasPostgresRange call must fail both.
An independent review (GPT 6 Astra, 2026-10-18) scaffolded a real EF migration from a consumer project, applied it to PostgreSQL 17, and confirmed CREATE TYPE timerange AS RANGE in the migration SQL and timerange → timemultirange in the catalogue. So the stronger form of this test is available: a design-time migration scaffold assertion, not only GenerateCreateScript. Prefer it if the translation-test project can host the design-time services cheaply.
Implemented in #158. The scaffold assertion is the design-time form: DesignTimeServicesBuilder, the same services dotnet ef migrations add builds, hosted in the translation-test project through one test-only Microsoft.EntityFrameworkCore.Design 10.0.0 reference. So there is no GenerateCreateScript fallback. CustomRangeCatalogueTests reads pg_type/pg_range and the column types after EnsureCreated in a database of its own. Both hold E39.
One deviation from the issue text. A seed may only change src/ (OracleSeedTests.EverySeed_TouchesOnlySource), and the HasPostgresRange call lives in test models. So the kept seed (timerange-store-type-not-created.patch) renames TimeRange's store types to time_range/time_multirange, which HasPostgresRange never creates. oracles.cs seeds reports it CAUGHT by both classes. Dropping HasPostgresRange itself was run once by hand: both classes fail (no annotation and no CREATE TYPE; 42704: type "timerange" does not exist).
area/range-setRangeSet and multirange algebraarea/rangesRange unions, variants and the shape enginespackage/efcoreAffects CodoMetis.ValueRanges.EFCore.PostgreSQLtestsAdds or changes tests only (oracles, harnesses); no library code
Activity
CaffeinatedCoder commentedon Oct 18, 2026
An independent review (GPT 6 Astra, 2026-10-18) scaffolded a real EF migration from a consumer project, applied it to PostgreSQL 17, and confirmed
CREATE TYPE timerange AS RANGEin the migration SQL andtimerange→timemultirangein the catalogue. So the stronger form of this test is available: a design-time migration scaffold assertion, not onlyGenerateCreateScript. Prefer it if the translation-test project can host the design-time services cheaply.CaffeinatedCoder commentedon Oct 18, 2026
Implemented in #158. The scaffold assertion is the design-time form:
DesignTimeServicesBuilder, the same servicesdotnet ef migrations addbuilds, hosted in the translation-test project through one test-onlyMicrosoft.EntityFrameworkCore.Design10.0.0 reference. So there is noGenerateCreateScriptfallback.CustomRangeCatalogueTestsreadspg_type/pg_rangeand the column types afterEnsureCreatedin a database of its own. Both hold E39.One deviation from the issue text. A seed may only change
src/(OracleSeedTests.EverySeed_TouchesOnlySource), and theHasPostgresRangecall lives in test models. So the kept seed (timerange-store-type-not-created.patch) renamesTimeRange's store types totime_range/time_multirange, whichHasPostgresRangenever creates.oracles.cs seedsreports it CAUGHT by both classes. DroppingHasPostgresRangeitself was run once by hand: both classes fail (no annotation and noCREATE TYPE;42704: type "timerange" does not exist).