Re: BUG: Postgres 14 + vacuum_defer_cleanup_age + FOR UPDATE + UPDATE

From: Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Mark Dilger <mark(dot)dilger(at)enterprisedb(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: BUG: Postgres 14 + vacuum_defer_cleanup_age + FOR UPDATE + UPDATE
Date: 2023-05-12 08:28:00
Message-ID: 01bd779a-87a2-7217-a1ff-4f6d6727819a@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 10.05.23 20:04, Andres Freund wrote:
>> This commit adds a test
>>
>> is(scalar @lp_off, $ROWCOUNT, "acquired row offsets");
>>
>> *before* that skip_all call. This appears to be invalid. If the skip_all
>> happens, you get a complaint like
>>
>> t/004_verify_heapam.pl (Wstat: 0 Tests: 1 Failed: 0)
>> Parse errors: Bad plan. You planned 0 tests but ran 1.
>>
>> We could move the is() test after all the skip_all's. Any thoughts?
>
> I think the easiest fix is to just die if we can't get the offsets - it's not
> like we can really continue afterwards...

This should do it:

-is(scalar @lp_off, $ROWCOUNT, "acquired row offsets");
+scalar @lp_off == $ROWCOUNT or BAIL_OUT("row offset counts mismatch");

But I'm not sure what the latest thinking on BAIL_OUT is. It is used
nearby in a similar way though.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2023-05-12 08:31:01 Re: psql tests hangs
Previous Message Peter Eisentraut 2023-05-12 08:04:50 Re: Add standard collation UNICODE