Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ugyvC-009Hgs-SJ for pgsql-hackers@arkaria.postgresql.org; Wed, 30 Jul 2025 05:00:11 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1ugyvB-006o4k-KE for pgsql-hackers@arkaria.postgresql.org; Wed, 30 Jul 2025 05:00:09 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ugyvB-006o4c-6T for pgsql-hackers@lists.postgresql.org; Wed, 30 Jul 2025 05:00:09 +0000 Received: from mail-wr1-x42e.google.com ([2a00:1450:4864:20::42e]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1ugyv8-001UwT-2G for pgsql-hackers@postgresql.org; Wed, 30 Jul 2025 05:00:08 +0000 Received: by mail-wr1-x42e.google.com with SMTP id ffacd0b85a97d-3b783d851e6so3233090f8f.0 for ; Tue, 29 Jul 2025 22:00:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1753851603; x=1754456403; darn=postgresql.org; h=in-reply-to:from:content-language:references:to:subject:user-agent :mime-version:date:message-id:from:to:cc:subject:date:message-id :reply-to; bh=JbZtMlRRVYj418DkzoctaJbeG2Sl3HdpQXtKgb7SucE=; b=NNVK9/DCwcZ9NLQUsWZ9C4C+6HyzUxBo2jTvtu7aCuFXvQyNTNGU9kgfNFNgRG5KLs pv1rUWXMxssHD/hHk7GXP3qlYhIas/PO8ADyQnljoscTHmQZ/bLF/d4iu3b/D3ufMJCY ljxHCnNx3SEXPPRQNDi6dGg75lB1Fdpp6rveFH5UseRic5wORxjK/Y3i5r7SO/+gt9IV 25kV+hm4gSO/kdv0rBRZSBlButnXP9OuX170A5FLtN37/BfeQH/kadV5GvCveyPcUT5a 408q6mBRZ9tlxjwVIGeLmI3gjt650ky2i8YfvUpRTfg2EPkCyy6P0DAYmqrk1Z/wJT8+ vMgg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1753851603; x=1754456403; h=in-reply-to:from:content-language:references:to:subject:user-agent :mime-version:date:message-id:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to; bh=JbZtMlRRVYj418DkzoctaJbeG2Sl3HdpQXtKgb7SucE=; b=Jw46YnGn44tctM7HQFWe1c671BUDYv/IllRkRfQEEIOggKK8GKApq/G4VwCkLDvawG 7zFnT7XtOkKhHwbhuCPkFTMI0k5hYLz0N+5KEmM+5LcF4iegPiEIJap0S32wTXiLvY3b gTN6hnx2YWY75o8f94NyShJF21FIBpjjdleSfnV3S79u4vzG81XxKZWA6MWsCQ+r3qCC 7wWXHjahTTRmKNTQFi4c0fHvsJC5/L96W7WWN438RqOOxli+qGYPGYavGYiIqAm39LhK WMDWkV/uf7T5FaqB+jAyDJi0uepTdRS9bs2LHwiQLataGTZRe1y2rKt3Kvn52ifEHUon arCA== X-Forwarded-Encrypted: i=1; AJvYcCU1XHMbANZBuCuFc28Hlmo7EqblslZAxg5Hg9De70XZGtZ6xlA/YpFQeyIkOAGLk0f4e78IdJy0T+IvgeaO@postgresql.org X-Gm-Message-State: AOJu0Yw9m8+uq+0lQ24wOh66gBEcbuCI2w0IMbirQkhhCKbtc008IrFx vk6AxiHsOMQVLh6MKb8t5CcMAgJ4kcUVpKVeX3orWVyJPeNPGP+1LiWihRQi+g== X-Gm-Gg: ASbGnctUIFnK9+hZvLSdDg2dPWIeAH2a3CrYNuO1i+HU94ZJANbuSEocEaFADzSuWvb ZAm3QGarut+LWx0JGqw9WunNJyzXWLDmg7xg8oYGqcXLDFpdZkWNhJpgDdgSl1rz9JIIxlUcxza hJYtZJ5EapXBdgGAyP6z3BPTjgH31CiktZN3RatdN6S1XOw1RaujPJlmxKBEVHijNafBgFXFKhV nZimcbWJgySZtf2KhKfHgL1/TleQjpF/Qfkmyyb9NSCKy4s6faVgRxffe2Dt/mpBQM8QGtr91Ol ixYq84Haf11Cq6LCQf7oscuvPzDzYL3n7Mn2PPY5C2MdhOxQUKx1jdi/NvcZ1zXFytyTfJFa4zW ZYc9z9xv5HRvC9Fp77EyO4Ccb X-Google-Smtp-Source: AGHT+IE3XjFmvsQJ7EDgF6IkZ3dZTs7u6cU6/X67NX0ZPideEP1+6BqD4G2bQmITMsUeOxZ9w0o00A== X-Received: by 2002:a05:6000:26ca:b0:3b7:82d3:ff90 with SMTP id ffacd0b85a97d-3b794fd654cmr1655178f8f.15.1753851602871; Tue, 29 Jul 2025 22:00:02 -0700 (PDT) Received: from [192.168.0.50] ([89.149.93.128]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-3b7973a9422sm160029f8f.21.2025.07.29.22.00.01 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 29 Jul 2025 22:00:02 -0700 (PDT) Content-Type: multipart/alternative; boundary="------------0YjNwxwrYZflN27WkLnKapT3" Message-ID: <47cdad4a-1bb3-4280-8dae-1980d2681b0e@gmail.com> Date: Wed, 30 Jul 2025 08:00:01 +0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Test instability when pg_dump orders by OID To: Noah Misch , pgsql-hackers@postgresql.org References: <20250707192654.9e.nmisch@google.com> Content-Language: en-US From: Alexander Lakhin In-Reply-To: <20250707192654.9e.nmisch@google.com> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk This is a multi-part message in MIME format. --------------0YjNwxwrYZflN27WkLnKapT3 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Hello Noah, 07.07.2025 22:26, Noah Misch wrote: > A 002_pg_upgrade.pl run got swapped order of tags "notnull_tbl1_upg nn" and > "notnull_parent_upg nn" for the schema diff test that commit > 172259afb563d35001410dc6daad78b250924038 added in v18: > > @@ -436873,14 +436873,14 @@ > ALTER TABLE public.insert_tbl > ADD CONSTRAINT ne_insert_tbl_con CHECK (((x + z) = 1)) NOT ENFORCED; > -- > --- Name: notnull_tbl1_upg nn; Type: CONSTRAINT; Schema: public; Owner: nm > +-- Name: notnull_parent_upg nn; Type: CONSTRAINT; Schema: public; Owner: nm > -- > -ALTER TABLE public.notnull_tbl1_upg > +ALTER TABLE public.notnull_parent_upg > ADD CONSTRAINT nn NOT NULL a NOT VALID; > -- > --- Name: notnull_parent_upg nn; Type: CONSTRAINT; Schema: public; Owner: nm > +-- Name: notnull_tbl1_upg nn; Type: CONSTRAINT; Schema: public; Owner: nm > -- > -ALTER TABLE public.notnull_parent_upg > +ALTER TABLE public.notnull_tbl1_upg It's rather funny that a few days before the fix is going to be pushed, hippopotamus proved the need for it [1] (I saw no such failures on the buildfarm before): ... [17:09:56.372](2.577s) not ok 8 - dump outputs from original and restored regression databases match [17:09:56.372](0.000s) [17:09:56.372](0.000s) #   Failed test 'dump outputs from original and restored regression databases match' [17:09:56.372](0.000s) #   at /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/../../../src/test/perl/PostgreSQL/Test/Utils.pm line 800. [17:09:56.373](0.000s) #          got: '1' #     expected: '0' === diff of /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/tmp_check/tmp_test_v61D/src_dump.sql_adjusted and /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/tmp_check/tmp_test_v61D/dest_dump.sql_adjusted === stdout === --- /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/tmp_check/tmp_test_v61D/src_dump.sql_adjusted 2025-07-28 17:09:55.040029896 +0200 +++ /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/tmp_check/tmp_test_v61D/dest_dump.sql_adjusted 2025-07-28 17:09:56.208057237 +0200 @@ -436960,14 +436960,14 @@  ALTER TABLE public.insert_tbl      ADD CONSTRAINT ne_insert_tbl_con CHECK (((x + z) = 1)) NOT ENFORCED;  -- --- Name: notnull_tbl1_upg nn; Type: CONSTRAINT; Schema: public; Owner: buildfarm +-- Name: notnull_parent_upg nn; Type: CONSTRAINT; Schema: public; Owner: buildfarm  -- -ALTER TABLE public.notnull_tbl1_upg +ALTER TABLE public.notnull_parent_upg      ADD CONSTRAINT nn NOT NULL a NOT VALID;  -- --- Name: notnull_parent_upg nn; Type: CONSTRAINT; Schema: public; Owner: buildfarm +-- Name: notnull_tbl1_upg nn; Type: CONSTRAINT; Schema: public; Owner: buildfarm  -- -ALTER TABLE public.notnull_parent_upg +ALTER TABLE public.notnull_tbl1_upg      ADD CONSTRAINT nn NOT NULL a NOT VALID;  --  -- Name: notnul Thank you for working on the fix! [1] https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=hippopotamus&dt=2025-07-28%2015%3A05%3A11 Best regards, Alexander --------------0YjNwxwrYZflN27WkLnKapT3 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit
Hello Noah,

07.07.2025 22:26, Noah Misch wrote:
A 002_pg_upgrade.pl run got swapped order of tags "notnull_tbl1_upg nn" and
"notnull_parent_upg nn" for the schema diff test that commit
172259afb563d35001410dc6daad78b250924038 added in v18:

@@ -436873,14 +436873,14 @@
 ALTER TABLE public.insert_tbl
     ADD CONSTRAINT ne_insert_tbl_con CHECK (((x + z) = 1)) NOT ENFORCED;
 --
--- Name: notnull_tbl1_upg nn; Type: CONSTRAINT; Schema: public; Owner: nm
+-- Name: notnull_parent_upg nn; Type: CONSTRAINT; Schema: public; Owner: nm
 --
-ALTER TABLE public.notnull_tbl1_upg
+ALTER TABLE public.notnull_parent_upg
     ADD CONSTRAINT nn NOT NULL a NOT VALID;
 --
--- Name: notnull_parent_upg nn; Type: CONSTRAINT; Schema: public; Owner: nm
+-- Name: notnull_tbl1_upg nn; Type: CONSTRAINT; Schema: public; Owner: nm
 --
-ALTER TABLE public.notnull_parent_upg
+ALTER TABLE public.notnull_tbl1_upg

It's rather funny that a few days before the fix is going to be pushed,
hippopotamus proved the need for it [1] (I saw no such failures on the
buildfarm before):
...
[17:09:56.372](2.577s) not ok 8 - dump outputs from original and restored regression databases match
[17:09:56.372](0.000s)
[17:09:56.372](0.000s) #   Failed test 'dump outputs from original and restored regression databases match'
[17:09:56.372](0.000s) #   at /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/../../../src/test/perl/PostgreSQL/Test/Utils.pm line 800.
[17:09:56.373](0.000s) #          got: '1'
#     expected: '0'
=== diff of /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/tmp_check/tmp_test_v61D/src_dump.sql_adjusted and /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/tmp_check/tmp_test_v61D/dest_dump.sql_adjusted
=== stdout ===
--- /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/tmp_check/tmp_test_v61D/src_dump.sql_adjusted    2025-07-28 17:09:55.040029896 +0200
+++ /home/buildfarm/hippopotamus/buildroot/REL_18_STABLE/pgsql.build/src/bin/pg_upgrade/tmp_check/tmp_test_v61D/dest_dump.sql_adjusted    2025-07-28 17:09:56.208057237 +0200
@@ -436960,14 +436960,14 @@
 ALTER TABLE public.insert_tbl
     ADD CONSTRAINT ne_insert_tbl_con CHECK (((x + z) = 1)) NOT ENFORCED;
 --
--- Name: notnull_tbl1_upg nn; Type: CONSTRAINT; Schema: public; Owner: buildfarm
+-- Name: notnull_parent_upg nn; Type: CONSTRAINT; Schema: public; Owner: buildfarm
 --
-ALTER TABLE public.notnull_tbl1_upg
+ALTER TABLE public.notnull_parent_upg
     ADD CONSTRAINT nn NOT NULL a NOT VALID;
 --
--- Name: notnull_parent_upg nn; Type: CONSTRAINT; Schema: public; Owner: buildfarm
+-- Name: notnull_tbl1_upg nn; Type: CONSTRAINT; Schema: public; Owner: buildfarm
 --
-ALTER TABLE public.notnull_parent_upg
+ALTER TABLE public.notnull_tbl1_upg
     ADD CONSTRAINT nn NOT NULL a NOT VALID;
 --
 -- Name: notnul

Thank you for working on the fix!

[1] https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=hippopotamus&dt=2025-07-28%2015%3A05%3A11

Best regards,
Alexander
--------------0YjNwxwrYZflN27WkLnKapT3--