Changes between Initial Version and Version 1 of Ticket #28403, comment 2
- Timestamp:
- Jul 24, 2017, 8:18:43 AM (7 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #28403, comment 2
initial v1 1 to be specific, with "locale path" i meant the [https://docs.djangoproject.com/en/dev/ref/settings/#locale-paths LOCALE_PATHS setting] as far as i understand, the [ 2 https://github.com/django/django/blob/550cb3a365dee4edfdd1563224d5304de2a57fda/django/utils/formats.py#L62 code for determining the format locale locations] does not look into LOCALE_PATHS. so yes, as far as i understand one has to specify FORMAT_MODULE_PATH besides LOCALE_PATHS. 1 To be specific, with "locale path" I meant the [https://docs.djangoproject.com/en/dev/ref/settings/#locale-paths LOCALE_PATHS setting] as far as I understand, the [https://github.com/django/django/blob/550cb3a365dee4edfdd1563224d5304de2a57fda/django/utils/formats.py#L62 code for determining the format locale locations] does not look into LOCALE_PATHS. So yes, as far as I understand one has to specify FORMAT_MODULE_PATH besides LOCALE_PATHS. 3 2 4 i'm using LOCALE_PATHS for translations. initially i though that any project using FORMAT_MODULE_PATH also has translations and therefore uses LOCALE_PATHS anyways, but from a quick github search that doesn't seem to be the case. so now i wouldn't replace {{{formats}}} by {{{locale}}}, but rather simply mention that the locale structure can be used.3 I'm using LOCALE_PATHS for translations. Initially I though that any project using FORMAT_MODULE_PATH also has translations and therefore uses LOCALE_PATHS anyways, but from a quick github search that doesn't seem to be the case. so now I wouldn't replace `formats`} by `locale`, but rather simply mention that the locale structure can be used. 5 4 6 actually from my point of view it would make sense to merge these settings. you specify where the locales are, and in there there might be translations and/or formats. or, one could at least make FORMAT_MODULE_PATH look into LOCALE_PATHS by default. however, the former is a python path while the latter is a normal path with slashes. but maybe, since this has been like that for 8 years according to git blame, maybe this doesn't need fixing :)5 Actually from my point of view it would make sense to merge these settings. You specify where the locales are, and in there there might be translations and/or formats. Or, one could at least make FORMAT_MODULE_PATH look into LOCALE_PATHS by default. However, the former is a python path while the latter is a normal path with slashes. But maybe, since this has been like that for 8 years according to git blame, maybe this doesn't need fixing :) 7 6 https://github.com/django/django/blob/550cb3a365dee4edfdd1563224d5304de2a57fda/django/utils/formats.py#L62