brianc / node-postgres

PostgreSQL client for node.js.
https://node-postgres.com
MIT License
12.04k stars 1.21k forks source link

fix devcontainer #3251

Closed nigrosimone closed 1 week ago

nigrosimone commented 3 weeks ago

Also fix https://github.com/brianc/node-postgres/issues/3049

brianc commented 2 weeks ago

Thanks! Will be a bit slow to follow up as I'm in the mountains for a few more days - will be home in a few in case I seem awol.

brianc commented 2 weeks ago

I'm a bit confused as to why the tests are failing? Nothing you changed should have impacted the tests at all afaict? any ideas?...

nigrosimone commented 2 weeks ago

@brianc

I'm a bit confused as to why the tests are failing?

Into the github action the database host is "localhost" https://github.com/brianc/node-postgres/blob/master/.github/workflows/ci.yml#L52, Instead into devcontainer is "db" https://github.com/nigrosimone/node-postgres/blob/patch-1/.devcontainer/docker-compose.yml#L44.

The test run successfully into devcontainer, but fail into github action. Simply need to use the same host name.

Nothing you changed should have impacted the tests at all afaict?

This is the commit of hostname change https://github.com/brianc/node-postgres/pull/3251/commits/fd1af11258a3333fb15636098adf267039a91fe2

brianc commented 2 weeks ago

k - should probably revert the changes to the native test or make it consistent everywhere - can't merge this w/o tests passing!

nigrosimone commented 1 week ago

@brianc I have reverted the failing test and made some other changes for latest vscode

brianc commented 1 week ago

@nigrosimone thanks for your help! Will run tests & then merge this. ❤️