Force PostGIS backend using dictionary spread syntax

- Use **db_config spread syntax to ensure PostGIS engine override takes effect
- This prevents dj_database_url from overriding the PostGIS backend setting
This commit is contained in:
pacnpal
2025-08-19 19:00:50 -04:00
parent d9fc13f350
commit 74b45aa143

View File

@@ -93,18 +93,19 @@ WSGI_APPLICATION = "thrillwiki.wsgi.application"
# Database
# Parse database URL but use PostGIS engine
# Parse database URL but force PostGIS engine
db_config = dj_database_url.config(
default="[DATABASE-URL-REMOVED]
conn_max_age=600,
conn_health_checks=True,
)
# Override engine to use PostGIS
db_config["ENGINE"] = "django.contrib.gis.db.backends.postgis"
# Force PostGIS engine - override any parsed engine
DATABASES = {
"default": db_config
"default": {
**db_config,
"ENGINE": "django.contrib.gis.db.backends.postgis",
}
}
# Cache settings