So Ive managed to screw something up between my production database settings for heroku.
Running the production settings locally I receive the error,
ImproperlyConfigured at /
settings.DATABASES is improperly configured. Please supply the ENGINE value. Check settings documentation for more details.
And I get the following error when deployed to Heroku seen here: http://tulsa-staging.herokuapp.com
Exception Value:
cannot concatenate 'str' and 'NoneType' objects
It appears that it has to do with my Database settings but I'm just not sure how to resolve this.
prod.py database settings for Heroku
urlparse.uses_netloc.append('postgres')
urlparse.uses_netloc.append('mysql')
try:
if 'DATABASE_URL' in os.environ:
url = urlparse.urlparse(os.environ['DATABASE_URL'])
DATABASES = {
'default':{
'ENGINE':'django.db.backends.postgresql_psycopg2',
'NAME': url.path[1:],
'USER': url.username,
'PASSWORD': url.password,
'HOST': url.hostname,
'PORT': url.port
}
}
except Exception:
print 'Unexpected error:', sys.exc_info()
Any thoughts on how to resolve this?