tumtumtum / Shaolinq

ORM for .NET with full LINQ support for Postgres, Sqlite, MySql and SqlServer
Other
127 stars 19 forks source link

Shaolinq broken with NpgSql > 6.0 #117

Open almostEric opened 2 years ago

almostEric commented 2 years ago

Getting an error now, related to this: daterange columns are scaffolded as DateInterval properties of NpgsqlRange ( #1998 ). Date/time min/max values are now converted to PostgreSQL infinity values by default PostgreSQL has special infinity and -infinity values for timestamps and dates, which are later and earlier than other value. Npgsql has supported mapping DateTime.MaxValue and MinValue to these infinity values via an Convert Infinity DateTime connection string parameter, which was disabled by default. This behavior is now on by default, since DateTime.MaxValue and MinValue are very rarely used as actual timestamps/dates, and the Convert Infinity DateTime parameter has been removed. To disable infinity conversions, add the following at the start of your application: AppContext.SetSwitch("Npgsql.DisableDateTimeInfinityConversions", true); See the date/time documentation for more details. Value converters for array/list pr...

As an aside, It would be great if you could coordinate your npgsql and shaolinq releases. This isn't the first time an npgsql update has broken things, and since you manage both projects...