We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 58fd2c4 commit dd94c19Copy full SHA for dd94c19
pg_database/conf.py
@@ -193,6 +193,10 @@ def _init_database_info(self):
193
elif not self._database_config or self._database_config.get("django-db-key") != DEFAULT_DJANGO_DB:
194
logger.debug("Applying Django database configuration")
195
196
+ from django.db import connections
197
+
198
+ django_databases = connections.settings
199
200
django_db_key = self._database_config.get("django-db-key") or "default"
201
if django_db_key not in django_databases:
202
raise EnvironmentError(f'No Django database configured for: "{django_db_key}"')
0 commit comments