From 9d5a32545ad71cfe7d71376ad7e7cb98967c9b52 Mon Sep 17 00:00:00 2001 From: Mehmet YILMAZ Date: Mon, 3 Nov 2025 15:59:00 +0300 Subject: [PATCH] =?UTF-8?q?PG18=20-=20Normalize=20PG18=20EXPLAIN:=20hide?= =?UTF-8?q?=20=E2=80=9CStorage=20=E2=80=A6=20Maximum=20Storage=20=E2=80=A6?= =?UTF-8?q?=E2=80=9D=20line=20(#8292)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fixes #8267 * Extend `src/test/regress/bin/normalize.sed` to drop the new PG18 EXPLAIN instrumentation line: ``` Storage: Maximum Storage: ``` which appears under `Materialize`, some `CTE Scan`s, etc. when `ANALYZE` is on. **Why** * PG18 added storage usage reporting for materialization/tuplestore nodes. It’s useful for humans but creates noisy, non-semantic diffs in regression output. There’s no EXPLAIN flag to suppress it, so we normalize in tests instead. This PR wires that normalization into our sed pipeline. https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=1eff8279d **How** * Add a narrowly scoped sed rule that matches only lines starting with `Storage:` (keeping `Sort Method`, `Hash`, `Buffers`, etc. intact). Use ERE compatible with `sed -Ef` and Python `re` (no POSIX character classes), e.g.: ``` /^[ \t]*Storage:[ \t].*$/d ``` --- src/test/regress/bin/normalize.sed | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/test/regress/bin/normalize.sed b/src/test/regress/bin/normalize.sed index 06729bd16..e3df83fa4 100644 --- a/src/test/regress/bin/normalize.sed +++ b/src/test/regress/bin/normalize.sed @@ -378,3 +378,7 @@ s/\/is still referenced from table/g # PG18: EXPLAIN ANALYZE prints "Index Searches: N" for index scans — remove it /^\s*Index Searches:\s*\d+\s*$/d + +# EXPLAIN (PG18+): hide Materialize storage instrumentation +# this rule can be removed when PG18 is the minimum supported version +/^[ \t]*Storage:[ \t].*$/d