Bug in parsing format string %T in function strptime in Miller 6? #882
Replies: 15 comments 13 replies
-
Function strptime also cannot parse time zone name or abbreviations:
|
Beta Was this translation helpful? Give feedback.
-
It looks like a similar issue I found with number formatting:
According to the manual page of the C |
Beta Was this translation helpful? Give feedback.
-
@derekmahar @Poshi indeed. In the C implementation (Miller 5 and below) In both C and Go I happily/glibly thought Hey cool there's this library I can use and gosh they thought of ever so many things! -- and I never made a catalog of all possible syntaxes. It all seemed like more choices than I would ever want or need. Which isn't entirely wrong, but, as you're both seeing, there's a regression when the catalog-of-all-supported-options changes from C to Go, and when one of the things in the old catalog ( (Aside: What we can do here:
|
Beta Was this translation helpful? Give feedback.
-
Maybe this is just a documentation issue: the help for |
Beta Was this translation helpful? Give feedback.
-
@derekmahar going through a checklist now -- this isn't answers, just a few for now:
I've always just used
I may be able to map But there's something else going on here. The timezone-related testing I did which was rather extensive during the Miller 6 implementation (https://github.com/johnkerl/miller/tree/main/test/cases/dsl-local-date-time-functions) was involving the 👀 |
Beta Was this translation helpful? Give feedback.
-
Re |
Beta Was this translation helpful? Give feedback.
-
This one has a straightforward explanation: the result of If we use 6-decimal output formatting we get
|
Beta Was this translation helpful? Give feedback.
-
@derekmahar in summary so far:
|
Beta Was this translation helpful? Give feedback.
-
@derekmahar re your original ask:
This was fixed by #944. There were two issues: one, |
Beta Was this translation helpful? Give feedback.
-
@derekmahar #944 and #951 contain what I think resolves all issues raised in this discussion. See also:
Please let me know if this covers all concerns, or if I've missed anything. |
Beta Was this translation helpful? Give feedback.
-
@all-contributors please add @derekmahar for ideas |
Beta Was this translation helpful? Give feedback.
-
@all-contributors please add @derekmahar for documentation |
Beta Was this translation helpful? Give feedback.
-
@derekmahar can you mark this as answered (unless I missed something) -- ? |
Beta Was this translation helpful? Give feedback.
-
Hello team. Great work with Miller! Thanks. Is the combination of %f and %z in strptime possible? With Miller 6.13:
Applying mlr -n put 'end {
print strptime("2012-06-15 11:38:33.160001+0100", "%Y-%m-%d %H:%M:%S.%f%z") ;
print strptime("2012-06-15 11:38:33+0100", "%Y-%m-%d %H:%M:%S%z") ;
print strptime("2012-06-15 11:38:33.160001", "%Y-%m-%d %H:%M:%S.%f")
} '
(error)
1339756713
1339760313.160001 |
Beta Was this translation helpful? Give feedback.
-
Looks like a bug to me! #1702 |
Beta Was this translation helpful? Give feedback.
-
Is the following a bug in the parsing of the %T format string in function strptime in Miller 6.0.0?
Compare the former result to the results of the following commands:
Do functions strftime and strptime in Miller 6.0.0 still use the format strings in function strftime in the C library?
Beta Was this translation helpful? Give feedback.
All reactions