#16718 closed Bug (duplicate)
check_for_language fails when django are imported from zip file
Reported by: | Owned by: | nobody | |
---|---|---|---|
Component: | Translations | Version: | 1.2 |
Severity: | Normal | Keywords: | egg zip |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
If you import django from a zip file and some i18n utils fail (i.e django.views.i18n.javascript_catalog)
Steps:
- import django as zip file
- setup a javascript translation different from default with some strings, i.e locale/es/LC_MESSAGES/djangojs.{po,mo}
- setup javascript_catalog view
- make a request like http://server/i18n/?language=es
- expected result:
spanish catalog should be returned in javascript file
- result:
default language catalog is returned in javascript file
Change History (2)
follow-up: 2 comment:1 by , 13 years ago
Resolution: | → duplicate |
---|---|
Status: | new → closed |
comment:2 by , 13 years ago
Keywords: | egg zip added |
---|
Replying to aaugustin:
it's a duplicate of #596.
I think it is actually a duplicate of #8280.
The Django installation docs make reference to installing as an egg, there are various accepted patches for running from a zip file (eg #8238 and the aforementioned #8280), and apparently it is (was?) the preferred (only?) way to run Django on Google App Engine. - see https://developers.google.com/appengine/articles/django10_zipimport as well as other comments in those bugs.
Django can't be packaged as a Python egg, in particular because it's hard to retrieve the templates and translation files.
If I understand correctly, by "importing from a zipfile", you mean "running from an egg", so it's a duplicate of #596.