[gdal-dev] Odd date conversion from geojson file in OGR - rounding up to invalid value

Andrew C Aitchison andrew at aitchison.me.uk
Thu Jun 26 15:58:46 PDT 2025


On Thu, 26 Jun 2025, Smith, Michael ERDC-RDE-CRREL-NH CIV via gdal-dev wrote:

> I have a geojson file that has a date field that is:
> "AOI_TASKING_DATE_END": "2025-11-30T23:59:59.999999Z",
>
> Gdal vector info is reporting this as:
>  AOI_TASKING_DATE_END (DateTime) = 2025/11/30 23:59:60+00
>
> Is this a gdal bug that is rounding the date up to an invalid value? Is there a way to control this?

I believe that there is an agreement to discontinue leap-seconds by 2035,
but the last second of any month *can* be 23:59:60 UTC !
(In practice all leap seconds so far have been June or December)

-- 
Andrew C. Aitchison                      Kendal, UK
                    andrew at aitchison.me.uk


More information about the gdal-dev mailing list