Permalink
Browse files

Merge pull request #1269 from edx/db/clarify-debug

Clarify USE_I18N settings
  • Loading branch information...
2 parents d42a350 + cbaa308 commit 838f4df6b5e539f003c85be8fb81f2b05d103181 @singingwolfboy singingwolfboy committed Oct 9, 2013
Showing with 24 additions and 8 deletions.
  1. +5 −0 cms/envs/acceptance.py
  2. +6 −4 cms/envs/common.py
  3. +1 −0 cms/envs/dev.py
  4. +5 −0 lms/envs/acceptance.py
  5. +6 −4 lms/envs/common.py
  6. +1 −0 lms/envs/dev.py
View
@@ -82,6 +82,11 @@ def seed():
# Use the auto_auth workflow for creating users and logging them in
MITX_FEATURES['AUTOMATIC_AUTH_FOR_TESTING'] = True
+# HACK
+# Setting this flag to false causes imports to not load correctly in the lettuce python files
+# We do not yet understand why this occurs. Setting this to true is a stopgap measure
+USE_I18N = True
+
# Include the lettuce app for acceptance testing, including the 'harvest' django-admin command
INSTALLED_APPS += ('lettuce.django',)
LETTUCE_APPS = ('contentstore',)
View
@@ -218,10 +218,12 @@
TIME_ZONE = 'America/New_York' # http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
LANGUAGE_CODE = 'en' # http://www.i18nguy.com/unicode/language-identifiers.html
-# We want i18n to be turned off in production, at least until we have full
-# localizations. It's disconcerting for everything on the page to be in English
-# except for one or two strings like "login" which are correctly localized.
-USE_I18N = DEBUG
+# We want i18n to be turned off in production, at least until we have full localizations.
+# Thus we want the Django translation engine to be disabled. Otherwise even without
+# localization files, if the user's browser is set to a language other than us-en,
+# strings like "login" and "password" will be translated and the rest of the page will be
+# in English, which is confusing.
+USE_I18N = False
USE_L10N = True
# Localization strings (e.g. django.po) are under this directory
View
@@ -9,6 +9,7 @@
from logsettings import get_logger_config
DEBUG = True
+USE_I18N = True
TEMPLATE_DEBUG = DEBUG
LOGGING = get_logger_config(ENV_ROOT / "log",
logging_env="dev",
View
@@ -109,6 +109,11 @@ def seed():
CC_PROCESSOR['CyberSource']['SERIAL_NUMBER'] = "0123456789012345678901"
CC_PROCESSOR['CyberSource']['PURCHASE_ENDPOINT'] = "/shoppingcart/payment_fake"
+# HACK
+# Setting this flag to false causes imports to not load correctly in the lettuce python files
+# We do not yet understand why this occurs. Setting this to true is a stopgap measure
+USE_I18N = True
+
MITX_FEATURES['ENABLE_FEEDBACK_SUBMISSION'] = True
FEEDBACK_SUBMISSION_EMAIL = 'dummy@example.com'
View
@@ -455,10 +455,12 @@
TIME_ZONE = 'America/New_York' # http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
LANGUAGE_CODE = 'en' # http://www.i18nguy.com/unicode/language-identifiers.html
-# We want i18n to be turned off in production, at least until we have full
-# localizations. It's disconcerting for everything on the page to be in English
-# except for one or two strings like "login" which are correctly localized.
-USE_I18N = DEBUG
+# We want i18n to be turned off in production, at least until we have full localizations.
+# Thus we want the Django translation engine to be disabled. Otherwise even without
+# localization files, if the user's browser is set to a language other than us-en,
+# strings like "login" and "password" will be translated and the rest of the page will be
+# in English, which is confusing.
+USE_I18N = False
USE_L10N = True
# Localization strings (e.g. django.po) are under this directory
View
@@ -16,6 +16,7 @@
from logsettings import get_logger_config
DEBUG = True
+USE_I18N = True
TEMPLATE_DEBUG = True

0 comments on commit 838f4df

Please sign in to comment.