#11637 closed (fixed)
Formats missing for most locales
Reported by: | Marc Garcia | Owned by: | Jannis Leidel |
---|---|---|---|
Component: | Internationalization | Version: | dev |
Severity: | Keywords: | i18n-rf | |
Cc: | Triage Stage: | Accepted | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | yes |
Easy pickings: | no | UI/UX: | no |
Pull Requests: | How to create a pull request | ||
Change History (30)
by , 16 years ago
Attachment: | no_format.diff added |
---|
comment:1 by , 16 years ago
comment:2 by , 16 years ago
Attached the Korean patch formats-ko-11034.py, based on revision [source:root/django/branches/soc2009/i18n-improvements/django/conf/locale/ko/formats.py]
by , 16 years ago
Attachment: | formats-ko-11304.py added |
---|
comment:3 by , 16 years ago
Triage Stage: | Unreviewed → Accepted |
---|
by , 15 years ago
Attachment: | 01-formats_sr_and_sr-latn.diff added |
---|
formats for Serbian and Serbian latin
comment:4 by , 15 years ago
Keywords: | i18n-rf added |
---|---|
milestone: | → 1.2 |
Owner: | changed from | to
Status: | new → assigned |
comment:5 by , 15 years ago
Patch needs improvement: | set |
---|---|
Summary: | [soc2009/i18n] Formats missing for most locales → Formats missing for most locales |
comment:6 by , 15 years ago
I've added all formats up to 01-formats_sr_and_sr-latn.diff to trunk in r11964.
by , 15 years ago
Attachment: | 11637-es-ar-deactivate-tests.diff added |
---|
Argentinina formats, plus other test changes
comment:7 by , 15 years ago
Week starts on Sundays on Argentina, that's the only item that differs from the 'es'
formats.py but warrants creation of a es_AR/formats.py
.
This led to the following sequence:
- Now that
es_AR/formats.py exists
, [source:trunk/tests/regressiontests/i18n/tests.py?rev=11964#L287 this test] (test_dates_and_numbers
) can't usees-ar
anymore to verify the fallback toes
. Changed it toes-us
(just like we are doing in the tests for theAccept-Language
HTTP header tests.) - This led to this test failure:
====================================================================== FAIL: test_dates_and_numbers (regressiontests.i18n.tests.TranslationTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/r/django/es_ar_fmts/tests/regressiontests/i18n/tests.py", line 288, in test_dates_and_numbers self.assertEqual(u'31 de Diciembre de 2009', date_format(d)) AssertionError: u'31 de Diciembre de 2009' != u'31 de diciembre de 2009'
This is because previously even when the es_AR formats file didn't exist and the formats machinery was falling back to es
, the 'F'
format specifier still used the es_AR
translation (Django es
translation of December is diciembre', es_AR
translation is 'Diciembre'). I don't know if this can be considered a bug and didn't pursue it further. I corrected the test by just changing the expected string to contain 'diciembre'.
- The above test failure causes also this other one:
====================================================================== FAIL: test_lazy_objects (regressiontests.i18n.tests.TranslationTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/r/django/es_ar_fmts/tests/regressiontests/i18n/tests.py", line 13, in test_lazy_objects self.assertEqual(u'Add Ringo', s % d) AssertionError: u'Add Ringo' != u'A\xf1adir Ringo'
This is because the assertEqual
-generated exception left an activate()
call not paired with a deactivate()
call and the next test (in this case test_lazy_objects
) got an unclean environment. I solved this by putting the assert*
calls after an activate()
call inside try blocks with deactivate
in the finally
branch.
I can split the patch in two if needed and put the 'non-es-ar formats' part on another ticket.
by , 15 years ago
Attachment: | 11637-cs.diff added |
---|
comment:8 by , 15 years ago
comment:9 by , 15 years ago
comment:10 by , 15 years ago
comment:11 by , 15 years ago
Have just tried uploading en_GB patch, but am getting Internal Server Errors! Will keep trying...
It includes formats for British English (and therefore Australian, etc) and necessary code to initialise the new locale.
by , 15 years ago
Test upload; ignore. Debugging Internal Server Error in djangoproject.com.
by , 15 years ago
Attachment: | en_GB.diff added |
---|
British English (and therefore Australian, etc) formats (+ locale init)
comment:15 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Closing this now since we are close to the 1.2 rc. Format updates should be dealt with like any other contribution.
Norwegian (bokmal) formats