Closed rockethacker closed 7 years ago
Comment: I also have multiple packages that try to use ISO-8601 for timestamps (SQLite Library, for example) and it would be nice if there was a common ISO-8601 parser that we could all use. Currently I just use trial-and-error with a number of common specific formats.
For what it's worth @rockethacker @drjdpowell, the JKI EasyXML library has a ISO-8601 converter that seems to work pretty well for the 2016-12-22 string, but not the more complex ones:
vi.lib\addons_JKI Toolkits\EasyXML\JKI_EasyXML.llb\Parse XML dateTime String__JKI EasyXML.vi
I've implemented a fix for supporting date strings without time (e.g. "2016-12-22")
Your timestamp serialization/deserialization fucntions mention that they convert "ISO" timestamps, but they only provide partial coverage of the ISO-8601 standard. The 1.1.7.33 release addresses a little more of the spec, but it still isn't enough for my use case (JIRA API) where a date but not a time is provided:
According to the wikipedia page, this should be valid ISO-8601 https://en.wikipedia.org/wiki/ISO_8601
Optimally, you should use an off the shelf ISO-8601 converter that supports more of the spec, but it doesn't appear that one exists (maybe a good candidate for an OpenG function?).