[Fixed]-DATABASES is improperly configured, NAME value, Heroku issue

1👍

You define DATABASES twice

DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.postgresql_psycopg2',
        'NAME': '',
        'USER': '',
        'PASSWORD': '',
        'HOST': '',
        'POST': '',
    }
}

...

DATABASE = {'default': dj_database_url.config()}

Second time (for Heroku) has typo. Correct is:

DATABASES = {'default': dj_database_url.config()}

Leave a comment