fathomnet / fathomnet-py

FathomNet Python client
https://fathomnet-py.readthedocs.io
MIT License
24 stars 3 forks source link

Check/correct datetime formatting in GeoImageConstraints #17

Open kevinsbarnard opened 1 year ago

kevinsbarnard commented 1 year ago

Date-time formatting is very strict in the FathomNet REST API. For example, 2007-08-02T00:00:00.000Z works while 2007-08-02 is rejected. This fact, in conjunction with #16, makes for some confusing error messages.

It would help users to add an explicit check or reformatting of date-time strings before sending them to the API.

Originated from #15