Re: KeyError: u"Unknown language code 'en-us'."
There is no language code "en-us" in django. `from django.conf.global_settings import LANGUAGES` to get a list of all languages.
On Monday, 20 January 2014 23:52:37 UTC+11, Geotribu wrote:
Hi all,
I've developed a multi-language application with Django.
Everything works fine except I receive regularly this message by email:
8<--------------------------------------------------------------
Traceback (most recent call last): File "/home/users/avandecastee/osmq/lib/python2.6/site-packages/django/core/handlers/base.py", line 140, in get_response response = response.render() File "/home/users/avandecastee/osmq/lib/python2.6/site-packages/django/template/response.py", line 105, in render self.content = self.rendered_content
......
File "/home/users/avandecastee/osmq/lib/python2.6/site-packages/django/utils/translation/__init__.py", line 150, in get_language_info raise KeyError("Unknown language code %r." % lang_code) KeyError: u"Unknown language code 'en-us'."
-------------------------------------------------------------->8
Could you tell me what I must change to avoid this message ?
Thanks for your help
Arnaud
-- On Monday, 20 January 2014 23:52:37 UTC+11, Geotribu wrote:
Hi all,
I've developed a multi-language application with Django.
Everything works fine except I receive regularly this message by email:
8<--------------------------------------------------------------
Traceback (most recent call last): File "/home/users/avandecastee/osmq/lib/python2.6/site-packages/django/core/handlers/base.py", line 140, in get_response response = response.render() File "/home/users/avandecastee/osmq/lib/python2.6/site-packages/django/template/response.py", line 105, in render self.content = self.rendered_content
......
File "/home/users/avandecastee/osmq/lib/python2.6/site-packages/django/utils/translation/__init__.py", line 150, in get_language_info raise KeyError("Unknown language code %r." % lang_code) KeyError: u"Unknown language code 'en-us'."
-------------------------------------------------------------->8
Could you tell me what I must change to avoid this message ?
Thanks for your help
Arnaud
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/0992ba14-4b0a-492e-857a-3efd4e2b7d7c%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home