brianc / node-postgres

PostgreSQL client for node.js.

Home Page:https://node-postgres.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`await client.connect()` hangs forever

trusktr opened this issue · comments

Any ideas why client.connect() may hang forever?

Code:

	const client = new Client({
	  user: session.username,
	  host: session.host,
	  database: session.database,
	  password: session.password,
	  port: session.port,
	  ssl : true
	})

	console.log(' ---------- connect', session)
	await client.connect()

await client.connect() stays hung indefinitely.

I'm on "pg": "^7.4.3",

Anything I should look out for with the options passed to Client?

I updated to "pg": "^8.11.3", and the issue went away.