Skip to content

Commit bf57083

Browse files
jeff-davishari90
authored andcommitted
Trial fix for old cross-version upgrades.
Per buildfarm and reports, it seems that 9.X to 18 upgrades were failing after commit 1fd1bd8 due to an incorrect regex. Loosen the regex to accommodate older versions. Reported-by: vignesh C <vignesh21@gmail.com> Reported-by: Andrew Dunstan <andrew@dunslane.net> Discussion: https://postgr.es/m/CALDaNm3GUs+U8Nt4S=V5zmb+K8-RfAc03vRENS0teeoq0Lc6Tw@mail.gmail.com Discussion: https://postgr.es/m/ea4cbbc1-c5a5-43d1-9618-8ff3f2155bfe@dunslane.net (cherry picked from commit ab84d0f)
1 parent 2a5f853 commit bf57083

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/test/perl/PostgreSQL/Test/AdjustUpgrade.pm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ sub adjust_old_dumpfile
257257

258258
# Same with version argument to pg_restore_relation_stats() or
259259
# pg_restore_attribute_stats().
260-
$dump =~ s ['version', '${old_version}\d{4}'::integer,]
260+
$dump =~ s ['version', '\d+'::integer,]
261261
['version', '000000'::integer,]mg;
262262

263263
if ($old_version < 14)
@@ -444,7 +444,7 @@ sub adjust_new_dumpfile
444444

445445
# Same with version argument to pg_restore_relation_stats() or
446446
# pg_restore_attribute_stats().
447-
$dump =~ s ['version', '\d{6}'::integer,]
447+
$dump =~ s ['version', '\d+'::integer,]
448448
['version', '000000'::integer,]mg;
449449

450450
if ($old_version < 14)

0 commit comments

Comments
 (0)