Re: psql tests hangs

Pavel Stehule <pavel.stehule@gmail.com>

From: Pavel Stehule <pavel.stehule@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>, Kirk Wolak <wolakk@gmail.com>, Daniel Gustafsson <daniel@yesql.se>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>, Andrey Borodin <x4mmm@yandex-team.ru>
Date: 2023-05-12T19:17:00Z
Lists: pgsql-hackers
pá 12. 5. 2023 v 21:08 odesílatel Tom Lane <tgl@sss.pgh.pa.us> napsal:

> I wrote:
> > Pavel Stehule <pavel.stehule@gmail.com> writes:
> >> Except for testing, using pager in non-interactive mode makes no sense.
>
> > Agreed.  Let's solve this by inserting isatty tests in psql, rather
> > than hacking the test environment.
>
> Here's a proposed patch for this.  I noticed that another memo the
> PSQL_WATCH_PAGER patch had not gotten was the lesson learned in
> commit 18f8f784c, namely that it's a good idea to ignore empty
> or all-blank settings.
>

+1

Pavel


>                         regards, tom lane
>
>

Commits

  1. Tighten usage of PSQL_WATCH_PAGER.

  2. Add tab-completion for newly added SUBSCRIPTION options.

  3. psql: add an optional execution-count limit to \watch.

  4. Handle empty or all-blank PAGER setting more sanely in psql.