Skip to content

Accept ISO 8601 date/time forms in infer-moment - #20

Merged
otherjoel merged 1 commit into
mainfrom
fix-infer-moment
Sep 26, 2026
Merged

otherjoel merged 1 commit into
mainfrom
fix-infer-moment

Conversation

@otherjoel

Copy link
Copy Markdown
Owner

infer-moment now accepts T between the date and time, an hour without minutes, fractional seconds, and a UTC offset (Z or ±hh:mm). Previously it ignored anything it could not parse after the date: "2012-09-14 12" and "2012-09-14T10:30" were both read as midnight. It now reads these as 12:00 and 10:30, and raises an exception for strings with trailing characters.

@otherjoel
otherjoel merged commit d8e7be3 into main Sep 26, 2026
2 checks passed
@otherjoel
otherjoel deleted the fix-infer-moment branch September 26, 2026 19:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant