What problem does it solve? Database connection failures in the kaupamex-api project often look like credential errors but are actually socket-versus-TCP misconfigurations, peer authentication mismatches, or missing CREATEDB role attributes. This Skill provides an executable gate that reveals which connection mode Django is actually using before you touch any code. ## Core Features & Use Cases - Executable Connection Gate: Runs a Django shell command that prints the real ENGINE, HOST, and PORT so you can tell a Unix socket connection (HOST starting with /) from TCP (127.0.0.1) before running migrations or pytest. - Peer Authentication Diagnosis: Explains why the same password works over TCP but fails over the socket on Debian, and how pg_hba.conf rule ordering fixes it. - CREATEDB and Cluster Operations: Covers the global CREATEDB role attribute needed for test database provisioning and how to start PostgreSQL via pg_ctlcluster on Debian. - Use Case: A pytest run fails with "FATAL: Peer authentication failed for user django_user". Run the gate first, confirm the socket path is active, then fix the pg_hba.conf rule ordering instead of changing passwords. ## Quick Start Ask the assistant to run the database connection gate and diagnose why my Django migration or pytest run is failing to connect to PostgreSQL.