Skip to content

v10.0.0

Choose a tag to compare

@github-actions github-actions released this 19 Oct 08:06
· 151 commits to main since this release
d47d9a3

Nothing was removed or renamed. Some calls answer differently, and text PostgreSQL refuses is refused here too: Migration from v9.x.

Breaking

  • Ranges: IsUnboundedStart() and IsUnboundedEnd() return true for the infinite range (,), as PostgreSQL and RangeSet do, where they returned false in memory. Match IUnboundedStartRange<T> or IUnboundedEndRange<T> for the half-unbounded shape alone (Migration).
  • Ranges: RangeSet.Overlaps on a continuous domain returns true when the operand ends where a later element starts and shares values with an earlier one, as && does. {[1,4),[5,8)}.Overlaps([3,5)) returned false (Migration).
  • Ranges: a record derived from a range type throws InvalidOperationException when it is constructed, where it compiled and Contains and Overlaps answered false for it (Pattern matching).
  • Value sets: every core wrapper set checks that an element's text form reads back as the same element, and throws if it doesn't, where the element was stored as a different value (Value sets).
  • Literals: integer or decimal text with a NUL throws FormatException, in a range, a set and JSON, where a trailing NUL was ignored and 31\0 read as 31 (Migration).
  • Literals: StringSet and StringSet<T> refuse an element holding a NUL: From and Add throw ArgumentException and parsing fails, where the set was built and failed when saved (Value sets).
  • Literals: GuidSet and GuidSet<T> read PostgreSQL's uuid_in grammar. {6f96-19ff-8b86-d011-b42d-00c0-4fc9-64ff} parses, where it threw; {(6f9619ff-…)} and whitespace inside a quoted element throw FormatException, where they parsed (Value sets).
  • Literals: a DateTimeOffset offset other than Z, ±HH, ±HH:mm or ±HH:mm:ss throws FormatException, where +0530 and +5:30 were read (Migration).
  • Literals: decimal text with more precision than decimal holds, such as a 29th significant digit or 1e-30, throws FormatException, where it was rounded (Literals).
  • Literals: a range or multirange literal whose lower bound is above its upper bound, such as [5,1), throws FormatException, where it read as empty. CreateFinite still returns Empty (Literals).
  • JSON: the integer, decimal and Guid wrapper sets read only the JSON their plain sets read: a quoted number needs AllowReadingFromString, and a Guid is hyphenated (Value sets).
  • ASP.NET Core: a minimal-API parameter typed as one shape, such as DateRange.Finite, answers 400 for a literal of another shape, where it bound null and ran the handler (Binding).
  • EF Core: the packages support PostgreSQL 16 and later. 9.x said 14 or later, but nothing older than 16 was tested (Migration).
  • EF Core: Any and Count over a captured list of ranges return the in-memory answer, where a list with overlapping, adjacent or empty ranges answered differently. EF.Parameter(list) there throws (Migration).

Added

  • Float64Range, Float64Set and Float64Set<T> over finite double values. NaN and the infinities throw, and the text is what PostgreSQL's float8out prints (Why doubles are finite only).
  • Float32Range, Float32Set and Float32Set<T> over finite float values, with the text float4out prints. There is no Half family, as PostgreSQL has no two-byte float (Why doubles are finite only).
  • IComparable on every range type and on RangeSet, in PostgreSQL's range and multirange order: empty first, then by lower bound, then by upper bound (Sort ranges).
  • Parse and TryParse on every shape (Int32Range.Finite.TryParse, …), which accept only a literal of that shape (Binding).
  • A range with a RangeSet operand for Contains, Overlaps, IsAdjacentTo and the other range operators, and RangeSet.IsContainedBy (Compare a range with a set).
  • RangeAgg and RangeIntersectAgg over a sequence of RangeSet, as PostgreSQL's range_agg and range_intersect_agg over multiranges (Aggregates).
  • Gap between two ranges, and Gaps() and Gaps(window) on a RangeSet, in memory and in EF Core queries (Ranges).
  • Shift and Expand on every range type, which move a range by a step or grow it on both sides, in memory only (Ranges).
  • Split on every range type, by a step or at calendar period boundaries, and Values(step) on the discrete types, in memory only (Ranges).
  • DateRange.Month, Quarter, Year and IsoWeek, the same on LocalDateRange, and Quarter and Year on YearMonthRange. Weeks are ISO 8601 only, whatever the culture (Ranges).
  • EF Core: Float64Range and Float32Range map to custom float8range and float4range types through HasPostgresRange and EnableUnmappedTypes(), and their sets to double precision[] and real[] (Custom range types).
  • EF Core: CompareTo against 0 on a range or multirange runs as <, <=, >, >= or = (EF Core).
  • EF Core: a range with a multirange operand runs as the operator with the range on the left, and RangeSet.IsContainedBy as <@ (EF Core).
  • EF Core: RangeAgg and RangeIntersectAgg over a multirange column inside a GroupBy projection (EF Core).
  • Docs: PostgreSQL 18 temporal keys over a range column (WITHOUT OVERLAPS, PERIOD), declared through EFCore.ComplexIndexes.PostgreSQL (Temporal keys).

Fixed

  • Literals: integer text reads PostgreSQL 16's 0x, 0o and 0b prefixes and underscores between digits, where [0x1F,) and {1_000} threw FormatException (Literals).
  • Literals: value sets read a dimension decoration such as [0:1]={1,2}, and {{}} as {} as PostgreSQL 17 does, where both threw FormatException (Value sets).
  • Literals: DateTime and DateTimeOffset text reads an offset up to ±15:59:59, as PostgreSQL does, where +15:00 threw FormatException (Literals).
  • EF Core: Any or Count with a predicate over an empty captured list of value sets, or of ranges beside a Contains, returns false or 0, where it threw InvalidOperationException (EF Core).
  • NodaTime: LocalDateTimeRange and LocalDateTimeSet read Z or an offset and keep the wall clock, where they threw. InstantRange and InstantSet refuse an offset beyond ±15:59:59 (Literals).
  • Docs: an exclusive infinity date bound excludes the date extreme, so [2026-01-01,infinity) is [2026-01-01,9999-12-30] (Domain width).
  • Docs: a YearMonthRange column holding an exclusive infinity) or (-infinity throws when it loads. Ask other tools to write an absent or inclusive bound (EF Core).
  • Docs: a temporal literal with more than six fraction digits can be 1 µs from what PostgreSQL reads and the EF Core package stores (Literals).
  • Docs: a database query over a NaN or infinite float another tool stored answers in PostgreSQL's order, and a CHECK constraint keeps such values out (EF Core).

Published to nuget.org through Trusted Publishing by this run. The CycloneDX SBOM for each package is attached below.