ruby / csv

CSV Reading and Writing
https://ruby.github.io/csv/
BSD 2-Clause "Simplified" License
178 stars 113 forks source link

Add support for RFC 3339 style time #248

Closed thyresias closed 2 years ago

thyresias commented 2 years ago

fix #247

ISO 8601 uses "T" for separator of date and time. RFC 3339 also accepts a space for separator of date and time.

kou commented 2 years ago

@ericgpks Do you want to review this?

ericgpks commented 2 years ago

I would like to try review.

thyresias commented 2 years ago

@kou I made the changes you requested, I hope it is now ok. I pushed them, do I need to do something else? And yes, I chose "the latter approach not the former" because it was simplifying the regexp, and the resulting format was recognized by Datetime.parse not only for the case I reported, but for all cases where a T is replaced by a space. So I thought it was eventually better to do it this way, despite your initial preference.

kou commented 2 years ago

Thanks!