NullReferenceException when trying to write class with nullable fields out to parquet.
// items is IEnumerable<MyClass>
using (var writer = new ChoParquetWriter<MyClass>(new ChoParquetRecordConfiguration
{
NullValueHandling = ChoNullValueHandling.Null
}))
{
writer.Write(items);
}
yields exception
System.NullReferenceException: 'Object reference not set to an instance of an object.'
Examples of field types that may be causing the issue are
bool?, decimal?, int?, DateTime?, TimeSpan?
I have previously created the writer with a null configuration class and still received the same result. Is there a way of getting this to happen or is there a more fundamental issue somewhere?
Not able to reproduce it. Wrote a sample fiddle
https://dotnetfiddle.net/TM2dW4
Pls review and share with more info.
You’ve used nullable long and double - simple number types. I suspect the issue may be related to handling of nullable datetime and timespan types which may be slightly less common
Added support for nullable datetime, timespan fields. Released v1.0.1.23-beta6.
Give it a try and let me know.