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.96) (envelope-from ) id 1wFTpd-005Ays-2j for pgsql-hackers@arkaria.postgresql.org; Wed, 22 Apr 2026 09:25:18 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wFTpc-00ChPF-2Y for pgsql-hackers@arkaria.postgresql.org; Wed, 22 Apr 2026 09:25:16 +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.96) (envelope-from ) id 1wFTpc-00ChP6-1e for pgsql-hackers@lists.postgresql.org; Wed, 22 Apr 2026 09:25:16 +0000 Received: from mail-pj1-x102d.google.com ([2607:f8b0:4864:20::102d]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wFTpa-00000002ECq-0vTq for pgsql-hackers@lists.postgresql.org; Wed, 22 Apr 2026 09:25:15 +0000 Received: by mail-pj1-x102d.google.com with SMTP id 98e67ed59e1d1-35fbca04006so2713346a91.1 for ; Wed, 22 Apr 2026 02:25:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1776849914; x=1777454714; darn=lists.postgresql.org; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:from:to:cc:subject:date:message-id:reply-to; bh=sXfpckHrZ7I0ODaxJrMG6jUZ1vLqFkAdDDlG3+/2/ZI=; b=lGNip5Zmhkt9bQzWKE9yBk7iWCTnURoD2lwA+jTdbjpBEOjS7rAB3cRgoUEMJJ1ap+ 82MCqUGccjaG7LmlpGcg1NCRdg3VrYF0SC0HD93tE1lxVbn4wVFOJr0HoBOPXV0EqbYH 3vL+S2nG9mvrpVDJ6ZIYiuGkEohROeTmr4RD1UTKCRq2TLiPdlrt9r1zySXyjZdFJVUJ kb7wkIkhTIvqMk4tRb3NQYA4BGop5/BHzBVnlqAtIP1pg8WPjm/cV8GSM8X0PfeRxAYy XZY0aEv/CcwqfXS/MNYAB5Gx1pmfS4ZBPuTutTht/iKOdHqgu8ccMmBbnJafc8zCLWSa ayBA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1776849914; x=1777454714; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=sXfpckHrZ7I0ODaxJrMG6jUZ1vLqFkAdDDlG3+/2/ZI=; b=OVSn41s9+KrgH1FNJ0bGv1qhST6gAIUV1NE/kQHqOBi8ZzTOQq2pqNq00KRh5+z0xO MndORYlmDadLjrB2OFG+3Nr+2m93QjeFhvvoklhDOyqWoC3O3GphvqJZZXup99YO+UZP d3y635gvnThKBFvbJErnRTKnTqkqG8nRuaebN0fxesmH+ulShtl/nKY13xjEpz4KQkC7 A8wefX+OPBZr/Bx2KV/s52qfvsOKS8A5OAen8aAgCCITdVodXPWzbeNkUzOY8vnbaYxs vvQNYYkiSh9s3xn5Bw/5/auLx+5yzE3sAUhxRSI8MWjpQ3GBnT/6L+aViaGSu+Wf5zhb g0dQ== X-Gm-Message-State: AOJu0YwXZyGeK5RhVPZHSdkKQZGOrUWZMfn4VL2f6vKkfQCE/EEKqYZg YQTBRnaxD1RNNf8z2kcHKFCQJe4ZyW4RJK9ddcfwFHBG11JmGkM4jRAF9opYrZoA X-Gm-Gg: AeBDiesIV+H16lLFAMuEbihvs6COWpo5rJiECQGvOMHDd7yAnbNs7lTsD/3/m36uuYu cb6pPkXVEYkaH15Q1vuMgBxCatD6Ihsg9b/Aiszj6ldc+QKByPQJfkf+P16YEEi5yRMwFy0F4ub fOjor9s8VN62oGDFMaMn28t+1LkOPNqRBXomcq85ErpUOZYQViE/yHMDagPFQNYieHHmT7yRyCZ 3EFZCLNnS+IhBKyJD18h61+P/5ibcCpBWZRlbGtDr+bBqq+C2v+h1QrjuWhrg3mMDT4nSbe0bcz QgYZTVSahLfAAWSKtbQXZg21ERhJKZ3K2CC7M5Z1I4VtZ9aK0M75lWy3SRnbOuH3oRQw3KEXJra fP5QHa2WfvkpRZGMh+M0ayM7juJj82QBPF1BQI+jWVDwXaG4RRfcUcY7ItFeTa3V4G8Kid1aINe Fd+3r1DffxZdGMcHJ62MAIgcj/+hstf5/MYP6iKIDrbA== X-Received: by 2002:a17:90b:3cc3:b0:35f:b69d:7292 with SMTP id 98e67ed59e1d1-3614046c8b0mr22127081a91.15.1776849913741; Wed, 22 Apr 2026 02:25:13 -0700 (PDT) Received: from smtpclient.apple ([45.32.121.103]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-36143b0dc2fsm16167431a91.3.2026.04.22.02.25.11 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 22 Apr 2026 02:25:13 -0700 (PDT) From: Chao Li Message-Id: Content-Type: multipart/mixed; boundary="Apple-Mail=_8583CE95-0BF4-430D-BD8E-42677058ED6F" Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3864.400.21\)) Subject: Re: Cleanup explain_memoize function after test Date: Wed, 22 Apr 2026 17:24:33 +0800 In-Reply-To: Cc: PostgreSQL Hackers To: Kirill Reshke References: X-Mailer: Apple Mail (2.3864.400.21) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --Apple-Mail=_8583CE95-0BF4-430D-BD8E-42677058ED6F Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Apr 22, 2026, at 14:49, Kirill Reshke = wrote: >=20 > Hi! >=20 > I was doing some hacking today, when I noticed that the memoize > regression test does not clean up the explain_memoize function after > its end. I checked other regression tests and they tend to do it. So, > I am not sure if there is a rule about `you should drop all objects > that you create in regression test`, but if there is such a rule, PFA. >=20 >=20 >=20 > --=20 > Best regards, > Kirill Reshke > Good catch. You also need to update the corresponding out file, otherwise the test = will fail. I have helped update the out file in v2, now =E2=80=9Cmake = check=E2=80=9D passes with v2 applied. Best regards, -- Chao Li (Evan) HighGo Software Co., Ltd. https://www.highgo.com/ --Apple-Mail=_8583CE95-0BF4-430D-BD8E-42677058ED6F Content-Disposition: attachment; filename=v2-0001-Cleanup-explain_memoize-after-resgression-test.patch Content-Type: application/octet-stream; x-unix-mode=0644; name="v2-0001-Cleanup-explain_memoize-after-resgression-test.patch" Content-Transfer-Encoding: quoted-printable =46rom=20695443e50e522453f11c442fef6f025e29a0a2e3=20Mon=20Sep=2017=20= 00:00:00=202001=0AFrom:=20reshke=20=0ADate:=20Wed,=20= 22=20Apr=202026=2006:46:25=20+0000=0ASubject:=20[PATCH=20v2]=20Cleanup=20= explain_memoize=20after=20resgression=20test=0A=0A---=0A=20= src/test/regress/expected/memoize.out=20|=201=20+=0A=20= src/test/regress/sql/memoize.sql=20=20=20=20=20=20|=202=20++=0A=202=20= files=20changed,=203=20insertions(+)=0A=0Adiff=20--git=20= a/src/test/regress/expected/memoize.out=20= b/src/test/regress/expected/memoize.out=0Aindex=20= 218972dfab8..199ef15920a=20100644=0A---=20= a/src/test/regress/expected/memoize.out=0A+++=20= b/src/test/regress/expected/memoize.out=0A@@=20-561,4=20+561,5=20@@=20= SELECT=20*=20FROM=20tab_anti=20t1=20WHERE=20t1.a=20IN=0A=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20->=20=20Seq=20Scan=20on=20= tab_anti=20t3=0A=20(10=20rows)=0A=20=0A+DROP=20FUNCTION=20= explain_memoize;=0A=20DROP=20TABLE=20tab_anti;=0Adiff=20--git=20= a/src/test/regress/sql/memoize.sql=20b/src/test/regress/sql/memoize.sql=0A= index=20e39bbb65391..4774d20c624=20100644=0A---=20= a/src/test/regress/sql/memoize.sql=0A+++=20= b/src/test/regress/sql/memoize.sql=0A@@=20-272,4=20+272,6=20@@=20SELECT=20= *=20FROM=20tab_anti=20t1=20WHERE=20t1.a=20IN=0A=20=20(SELECT=20a=20FROM=20= tab_anti=20t2=20WHERE=20t2.b=20IN=0A=20=20=20(SELECT=20t1.b=20FROM=20= tab_anti=20t3=20WHERE=20t2.a=20>=201=20OFFSET=200));=0A=20=0A+DROP=20= FUNCTION=20explain_memoize;=0A+=0A=20DROP=20TABLE=20tab_anti;=0A--=20=0A= 2.50.1=20(Apple=20Git-155)=0A=0A= --Apple-Mail=_8583CE95-0BF4-430D-BD8E-42677058ED6F--