From 753942c8c0f05d270957c776ce55f6b8d2a4b90e Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 26 Jul 2025 13:28:28 +0530 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A7=20Fix=20PostgreSQL=20connection=20?= =?UTF-8?q?error=20-=20remove=20invalid=20MAX=5FCONNS=20option?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Remove invalid MAX_CONNS option causing psycopg2.ProgrammingError - Keep CONN_MAX_AGE for connection pooling (valid Django option) - Fix Railway PostgreSQL database configuration Error resolved: invalid connection option "MAX_CONNS" 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- netcop_hub/settings.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/netcop_hub/settings.py b/netcop_hub/settings.py index e61cc44..2aa47ea 100644 --- a/netcop_hub/settings.py +++ b/netcop_hub/settings.py @@ -311,9 +311,6 @@ if config('RAILWAY_ENVIRONMENT', default=''): # Database connection optimization for Railway PostgreSQL if 'default' in DATABASES: DATABASES['default']['CONN_MAX_AGE'] = 600 # 10 minutes connection pooling - if 'OPTIONS' not in DATABASES['default']: - DATABASES['default']['OPTIONS'] = {} - DATABASES['default']['OPTIONS']['MAX_CONNS'] = 20 SECURE_PROXY_SSL_HEADER = ('HTTP_X_FORWARDED_PROTO', 'https')