#13575: nb/nn locale not a valid python locale
---------------------------------------------------+------------------------
 Reporter:  oyvind                                 |       Owner:  nobody    
   Status:  new                                    |   Milestone:            
Component:  Internationalization                   |     Version:  SVN       
 Keywords:  locale python nb nn norwegian nynorsk  |       Stage:  Unreviewed
Has_patch:  0                                      |  
---------------------------------------------------+------------------------
 If this code is run in the django shell:

 {{{
 #!python

 from django.utils.translation.trans_real import get_language_from_request

 g = get_language_from_request
 from django.http import HttpRequest

 r = HttpRequest()
 r.COOKIES = {}
 r.META = {'HTTP_ACCEPT_LANGUAGE': 'nb,nn;q=0.7,en;q=0.3'}

 g(r)

 }}}

 The returned language code is "en".

 The reason for this is that neither "no" or "nn" is in
 locale.locale_alias.

 Attaching temporary fix.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/13575>
Django <http://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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.

Reply via email to