← 输入框|github.com|刷新
Skip to content

Canadian locale doesn't support AM/PM? #102

Open

Description

@ronnyli

(local-date-time "M/d/yyyy h:mm:ss a" "1/3/2022 3:58:29 PM")

Execution error (DateTimeParseException) at java.time.format.DateTimeFormatter/parseResolved0 (DateTimeFormatter.java:2051).
Text '1/3/2022 3:58:29 PM' could not be parsed at index 17

Some sleuthing in the Clojurians slack discovered that it has to do with the Canadian locale (link)

Activity

  1. frenchy64 commented on Nov 16, 2023

    @frenchy64
    Collaborator

    Can you post your solution? I'm guessing you followed this advice?

    henryw374: Set the locale on the formatter itself rather than relying on ambient default

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions