Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#25812 closed Bug (fixed)

Cannot use custom formats after security fix in 1.8.7 (regression)

Reported by: Gagaro Owned by: Gagaro
Component: Internationalization Version: 1.8
Severity: Release blocker Keywords: formats
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by Gagaro)

Before the security fix in 1.8.7, we could have custom formats in formats.py files and used them. For example, if I have the following formats.py:

CUSTOM_DAY_FORMAT = 'd/m/Y CUSTOM'

I could used it:

>>> get_format('CUSTOM_DAY_FORMAT')
'd/m/Y CUSTOM'

But now it returns 'CUSTOM_DAY_FORMAT' instead.

https://github.com/django/django/pull/5719

Change History (7)

comment:1 Changed 5 years ago by Gagaro

Owner: changed from nobody to Gagaro
Status: newassigned

comment:3 Changed 5 years ago by Gagaro

Description: modified (diff)

comment:4 Changed 5 years ago by Tim Graham

Severity: NormalRelease blocker
Triage Stage: UnreviewedReady for checkin
Type: UncategorizedBug

comment:5 Changed 5 years ago by Tim Graham <timograham@…>

Resolution: fixed
Status: assignedclosed

In 34d8894:

Fixed #25812 -- Restored the ability to use custom formats with the date template filter.

comment:6 Changed 5 years ago by Tim Graham <timograham@…>

In 08e1c79f:

[1.9.x] Fixed #25812 -- Restored the ability to use custom formats with the date template filter.

Backport of 34d88944f46d3e2734488fd0ca3c2c24c15a0264 from master

comment:7 Changed 5 years ago by Tim Graham <timograham@…>

In 9582ba5:

[1.8.x] Fixed #25812 -- Restored the ability to use custom formats with the date template filter.

Backport of 34d88944f46d3e2734488fd0ca3c2c24c15a0264 from master

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