Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating FlexibleDateTimeFormatter to cover edge cases #770

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

arp-0984
Copy link
Collaborator

@arp-0984 arp-0984 commented May 3, 2024

Adding extra date format patterns to cover edge cases and updating characters to remove from dates.

Attempting these formats is optional and specified with a boolean passed to the parse() function. The basic set of formats (FORMAT_DATETIME_MAIN) are attempted first to parse the date, and if none of them are successful, then the more comprehensive set of date formats (FORMAT_DATETIME_EXTRA) are attempted.

Testing with the new patterns covers all the edge cases I could find. I attempted to explain the new patterns in the config file. Utilizing DateTimeFormatter is tricky because it requires an exact match of a pattern to the provided date string. The goal here is not to be able to literally parse any date, but just match the behavior of the existing DateTimeFormatterLegacy class.

@arp-0984 arp-0984 changed the title DRAFT Updating FlexibleDateTimeFormatter to cover edge cases Updating FlexibleDateTimeFormatter to cover edge cases May 9, 2024
@arp-0984 arp-0984 marked this pull request as ready for review May 9, 2024 18:05
@jpdahlke jpdahlke added the rebase Things have happened and now a rebase is needed label May 10, 2024
@jpdahlke jpdahlke added this to the v8.4.0 milestone May 13, 2024
@arp-0984 arp-0984 removed the rebase Things have happened and now a rebase is needed label May 13, 2024
@jpdahlke jpdahlke modified the milestones: v8.4.0, v8.5.0 May 23, 2024
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.

None yet

2 participants