Re: DJANGO_SETTINGS_FILE

2017-04-06 Thread Chris Church
Look through https://code.djangoproject.com/wiki/SplitSettings for many different approaches to loading settings from files that aren't importable as Python modules. My personal favorite is django-split-settings, which would let you accomplish exactly what you're trying to do. On Thu, Apr 6, 201

Re: manage.py and pyc's

2013-07-23 Thread Chris Church
It looks like this issue has been marked as wontfix in https://code.djangoproject.com/ticket/14952 However, I've used the following in manage.py to support running management commands when distributing only .pyc files: https://gist.github.com/cchurch/6067733 On Tue, Jul 23, 2013 at 6:29 PM, J

Re: secret key from file...

2011-03-22 Thread Chris Church
I've used the execfile approach in my settings.py like so: # Include any local settings that override the defaults. try: execfile('local_settings.py') # Hack so that the autoreload will detect changes to local_settings.py. class dummymodule(str): __file__ = property(lambda self