New instability in stats regression test

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-hackers@lists.postgresql.org
Cc: Andres Freund <andres@anarazel.de>, Michael Paquier <michael@paquier.xyz>
Date: 2023-11-25T18:08:54Z
Lists: pgsql-hackers
In the past few days we've had two buildfarm failures[1][2] in the
stats regression test that look like

@@ -1582,7 +1582,7 @@
 SELECT :io_stats_post_reset < :io_stats_pre_reset;
  ?column? 
 ----------
- t
+ f
 (1 row)
 
 -- test BRIN index doesn't block HOT update

I'm a bit mystified by this.  This test was introduced in Andres'
commit 10a082bf7 of 2023-02-11, and it seems to have been stable
since then.  I trawled the buildfarm logs going back three months
and found no similar failures.  So why's it failing now?  The
most plausible theory seems to be that Michael's recent commits
adding pg_stat_reset_xxx features destabilized the test somehow ...
but I sure don't see how/why.

Failure [1] was on my own animal longfin, so I tried to reproduce
it on that animal's host, but no luck so far.

Thoughts?

			regards, tom lane

[1] https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=longfin&dt=2023-11-21%2001%3A55%3A00
[2] https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=guaibasaurus&dt=2023-11-25%2016%3A20%3A04



Commits

  1. Remove test for pg_stat_reset_shared() in stats.sql

  2. Add ability to reset all shared stats types in pg_stat_reset_shared()

  3. Add tests for pg_stat_io