#35306: Localisation of dates very confusing - why can't it be turned off 
anymore?
-------------------------------------+-------------------------------------
               Reporter:             |          Owner:  nobody
  richardthegit                      |
                   Type:  Bug        |         Status:  new
              Component:             |        Version:  5.0
  Internationalization               |       Keywords:  LANGUAGE_CODE,
               Severity:  Normal     |  DATE_FORMAT
           Triage Stage:             |      Has patch:  0
  Unreviewed                         |
    Needs documentation:  0          |    Needs tests:  0
Patch needs improvement:  0          |  Easy pickings:  0
                  UI/UX:  0          |
-------------------------------------+-------------------------------------
 The doc:

 https://docs.djangoproject.com/en/5.0/ref/settings/#language-code

 specifically states:

 "USE_I18N must be active for this setting to have any effect."

 This is not true. If `USE_I18N` is `False` and a language can not be
 determined (e.g. the locale middleware is not active), the `date` template
 filter will use the value of `LANGUAGE_CODE`.

 I think the handling of date formatting is now very confusing, and the doc
 for `DATE_FORMAT`, `DATETIME_FORMAT`, etc is at best incomplete because
 it's very difficult to understand when (if ever) these settings are
 actually used now that the `USE_L10N` setting has been fully deprecated.

 I'm not raising this as a doc issue because I think this system is now
 somewhat broken. Personally I think that `USE_L10N` should be brought
 back; there needs to be a way to turn off localisation of dates (and
 numbers) separately to translations - they're not the same thing.

 I know I can force a particular locale to be used via `LANGUAGE_CODE`, but
 I specifically want my format to be used, and the existing `DATE_FORMAT`,
 etc settings seems like the right way to do that. I just need a way to
 force their use, which used to be simply setting `USE_L10N = True`.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/35306>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018e4345b9b5-549931c7-e97a-4786-a71a-1bc0a0c74098-000000%40eu-central-1.amazonses.com.

Reply via email to