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
but when I add fractions of a second the code breaks:
DateTimeoriginal=new DateTime(1969,12,31,23,59,59).AddTicks(1);// 100nsMessagePackSerializer<DateTime>ser= MessagePackSerializer.Get<DateTime>();byte[]b= ser.PackSingleObject(original);---> System.ArgumentOutOfRangeException : nanoseconds must be non negative value and lessor than 999,999,999.
Parameter name: nanoseconds
at MsgPack.Timestamp.FromDateTime(DateTime value)
at MsgPack.Serialization.DefaultSerializers.TimestampDateTimeMessagePackSerializer.PackToCore(Packer packer, DateTime objectTree)
at MsgPack.Serialization.MessagePackSerializer`1.PackTo(Packer packer, T objectTree)
at MsgPack.Serialization.MessagePackSerializer`1.PackSingleObjectAsBytes(T objectTree)
at MsgPack.Serialization.MessagePackSerializer`1.PackSingleObject(T objectTree)
As far as I can tell this should be serialising to the Timestamp 96 format which supports pre-epoch timestamps and fractional seconds, but this seems to be a bug in the serialisation to Timestamp 96.
The text was updated successfully, but these errors were encountered:
adamrodger
changed the title
Pre-Epoch DateTimes With Milliseconds Can't Be Serialized
Pre-Epoch DateTimes With Fractional Seconds Can't Be Serialized
Jan 15, 2019
I forgot that it should be released as 1.0.1, but I also found that the released process failed. I will fix the pipeline and release it to the NuGet soon.
This code works fine:
but when I add fractions of a second the code breaks:
As far as I can tell this should be serialising to the Timestamp 96 format which supports pre-epoch timestamps and fractional seconds, but this seems to be a bug in the serialisation to Timestamp 96.
The text was updated successfully, but these errors were encountered: