redundant error messages

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема redundant error messages
Дата
Msg-id 3e937641-88a1-e697-612e-99bba4b8e5e4@enterprisedb.com
обсуждение исходный текст
Ответы Re: redundant error messages
Re: redundant error messages
Список pgsql-hackers
A few client tools duplicate error messages already provided by libpq, 
such as

pg_rewind: fatal: could not connect to server: could not connect to 
server: No such file or directory

pg_basebackup: error: could not connect to server: could not connect to 
server: No such file or directory

psql: error: could not connect to server: could not connect to server: 
No such file or directory

The psql case is actually a regression introduced in PG12, but the other 
two appear to be ancient.

Other client tools provide a different error message so in aggregate it 
looks like this:

createdb: error: could not connect to database template1: could not 
connect to server: No such file or directory

The attached patch removes the redundant message from the client tools. 
I suppose it's a bit dubious because there is no guarantee what the 
level of detail the message supplied by libpq has.  But I think these 
few cases are not particularly hard to keep in sync.

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Daniel Gustafsson
Дата:
Сообщение: Re: Move OpenSSL random under USE_OPENSSL_RANDOM
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: Move OpenSSL random under USE_OPENSSL_RANDOM