I'm trying to figure out a really weird problem with this django program. Basically we have a django based app thats been split into a second app, mainly by loading the settings_sis.py file instead of the settings.py file, in the relevant site's /etc/httpd/conf.d/002-blah.conf file. This is set with the line "DJANGO_SETTINGS_MODULE=settings_sis" Anyway, completely randomly when I refresh the site, around 50% of time time the site errors out. When that happens I can see the following in the debug error message:
SESSION_FILE_PATH None
SESSION_SAVE_EVERY_REQUEST False
SETTINGS_MODULE 'settings'
SITE_ID 100
So I'm making the assumption that SETTINGS_MODULE is the same thing as the DJANGO_SETTINGS_MODULE which I don't see in the list. Why on earth would this be set to the wrong thing at a completely random 50% of the time?
Apache configuration excerpt:
PythonHandler core.handlers.production
PythonInterpreter citizen
SetEnv DJANGO_SETTINGS_MODULE settings_sis
SetEnv PYTHON_EGG_CACHE /tmp