Repository navigation
Conversation
Member
|
Not sure about this one. If we really want to enforce DATE_ORDER with ISO, which may make no sense to begin with, should we not fail on 2026 as day? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
dateparser already forced month-day ordering after a leading 4-digit year, but only when DATE_ORDER wasn't explicitly set. So an explicit DATE_ORDER=DMY/YDM (needed for a source's genuinely ambiguous dates) still broke unambiguous ISO strings:
This drops that guard, so a leading year always fixes the remaining order as month-then-day, regardless of DATE_ORDER. Ambiguous non-ISO strings without a leading year (e.g. "03-12-2026") still honor DATE_ORDER as before.