=== modified file 'django/core/management/__init__.py'
|
|
|
250 | 250 | """ |
251 | 251 | try: |
252 | 252 | app_name = get_commands()[subcommand] |
253 | | if isinstance(app_name, BaseCommand): |
254 | | # If the command is already loaded, use it directly. |
255 | | klass = app_name |
256 | | else: |
257 | | klass = load_command_class(app_name, subcommand) |
258 | 253 | except KeyError: |
259 | 254 | sys.stderr.write("Unknown command: %r\nType '%s help' for usage.\n" % \ |
260 | 255 | (subcommand, self.prog_name)) |
261 | 256 | sys.exit(1) |
| 257 | if isinstance(app_name, BaseCommand): |
| 258 | # If the command is already loaded, use it directly. |
| 259 | klass = app_name |
| 260 | else: |
| 261 | klass = load_command_class(app_name, subcommand) |
262 | 262 | return klass |
263 | 263 | |
264 | 264 | def autocomplete(self): |
=== modified file 'django/db/__init__.py'
|
|
|
35 | 35 | raise ImproperlyConfigured("You must default a '%s' database" % DEFAULT_DB_ALIAS) |
36 | 36 | |
37 | 37 | for alias, database in settings.DATABASES.items(): |
| 38 | if 'ENGINE' not in database: |
| 39 | raise ImproperlyConfigured("You must specify a 'ENGINE' in '%s' database setting" % alias) |
38 | 40 | if database['ENGINE'] in ("postgresql", "postgresql_psycopg2", "sqlite3", "mysql", "oracle"): |
39 | 41 | import warnings |
40 | 42 | if 'django.contrib.gis' in settings.INSTALLED_APPS: |