﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
24332	Sites migration fails when DATABASES['default'] = {}	Thomas Recouvreux	nobody	"
{{{

}}}
On Django 1.7.4 the management command `migrate --database=xxx` fails when `DATABASES['default'] = {}` with `django.core.exceptions.ImproperlyConfigured: settings.DATABASES is improperly configured. Please supply the ENGINE value. Check settings documentation for more details.`.
On Django 1.7.3 it works fine.
More details can be found on https://code.djangoproject.com/ticket/24298.

To reproduce the problem:

1. Create a new project
2. Edit the settings.py this way:


{{{
DATABASES = {
    'default': {},
    'mysite': {
        'ENGINE': 'django.db.backends.sqlite3',
        'NAME': os.path.join(BASE_DIR, 'db_mysite.sqlite3'),
    }
}
}}}

3. Run python manage.py migrate --database=mysite

Problem:
It seems Django tries to access the default connection. 


I am attaching an output log of the command.
Here is a sample project to reproduce the behaviour: ​https://github.com/trecouvr/test_dj_migrate_174."	Bug	new	Migrations	1.7	Normal		migrate post_migrate		Unreviewed	0	0	0	0	0	0
