IntArrayConverter and StringArrayConverter return null for anything they cannot read, but only on the string-literal path. On the JSON path a failing element leaves the reader half way through the array, and an object in place of the array is never consumed, so System.Text.Json throws "read too much or not enough" after Read returns and the whole record fails in Model<T>().
{"favorite_numbers":[1,"x"]} // JsonException, record lost
{"favorite_numbers":{}} // same
{"favorite_numbers":"{1,x}"} // null, as intended
Fix is the one PostgresNestedArrayConverter got in #436: copy the reader before the try, and in the catch rewind it and Skip(); Skip() in the default branch too.
IntArrayConverterandStringArrayConverterreturn null for anything they cannot read, but only on the string-literal path. On the JSON path a failing element leaves the reader half way through the array, and an object in place of the array is never consumed, so System.Text.Json throws "read too much or not enough" afterReadreturns and the whole record fails inModel<T>().Fix is the one
PostgresNestedArrayConvertergot in #436: copy the reader before the try, and in the catch rewind it andSkip();Skip()in the default branch too.