Re: BUG #15827: Unable to connect on Windows using pg_services.conf using Python psycopg2
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Jorge Gustavo Rocha <jgr@geomaster.pt>
Cc: pgsql-bugs@lists.postgresql.org
Date: 2019-06-01T18:06:28Z
Lists: pgsql-bugs
Jorge Gustavo Rocha <jgr@geomaster.pt> writes: > Hi Tom, > Thanks for looking at this. > I've tried with \n and \r\n separators to make sure it wasn't the > problem. I did a od -c to make sure the endings were the expected ones, > and I found no difference between just \n or \r\n. > The psql is able to deal with service=pg_trabalho, so I think libpq is > reading the file without line end issues. Yeah, that seems like it puts libpq in the clear, but then where are things going wrong? I wonder if psycopg2 is not just "passing the connection parameters down to libpq", but is reading the service file for itself (and failing to take care about newlines). regards, tom lane
Commits
-
Fix failures to ignore \r when reading Windows-style newlines.
- 8c52b77ddea7 9.4.24 landed
- 6266654db7fa 9.5.19 landed
- ba27151d1eb0 9.6.15 landed
- cb65b454f87b 10.10 landed
- 11a0a4db3cdb 11.5 landed
- c58cf97f2fc4 12.0 landed
- b654714f9bcf 13.0 landed