Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#21258 closed Bug (invalid)

Spanish locale should accept %Y-%m-%d format for dates

Reported by: Matt Owned by: nobody
Component: Uncategorized Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

The Spanish formats file does not accept the YYYY-MM-DD format for dates. All the other language formats seem to accept this, as it is the ISO date format. Is there a reason for this, or simply overlooked?

https://github.com/django/django/blob/1dae4ac1778f04805c0ed62c8debb13b281ba02b/django/conf/locale/es/formats.py#L19

Change History (4)

comment:1 Changed 3 years ago by Matt

Version: 1.5master

comment:2 Changed 3 years ago by Claude Paroz

Resolution: needsinfo
Status: newclosed

get_format in django.utils.formats.py should automatically add ISO formats (hence %Y-%m-%d) in all localized formats. So if you think this doesn't work, could you please add some test or code snippet demonstrating the issue?

comment:3 Changed 3 years ago by Matt

Sorry, I mistakenly checked against 1.4, not master.

comment:4 Changed 3 years ago by Claude Paroz

Resolution: needsinfoinvalid

No problem, thanks for checking.

Note: See TracTickets for help on using tickets.
Back to Top