From 2ddf06d5f867b0eacdd3d06536c374aa1272bd4b Mon Sep 17 00:00:00 2001 From: Keith Fiske Date: Fri, 29 Nov 2024 10:25:43 -0500 Subject: [PATCH] fix: correct error in 5.2.0 update file --- CHANGELOG.md | 6 ++++++ META.json | 6 +++--- pg_partman.control | 2 +- updates/pg_partman--5.1.0--5.2.0.sql | 7 ++++--- updates/pg_partman--5.2.0--5.2.1.sql | 1 + 5 files changed, 15 insertions(+), 7 deletions(-) create mode 100644 updates/pg_partman--5.2.0--5.2.1.sql diff --git a/CHANGELOG.md b/CHANGELOG.md index 2e7df0b..37b9bc0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +5.2.1 +===== +BUG FIXES +--------- + - Corrected a syntax error in the 5.1.0 to 5.2.0 update file. There are no problems with a direct install of 5.2.0 and there is no technical need to update to 5.2.1. The issue was encountered only when updating from any prior version to 5.2.0. New release was tagged to ease rolling out the fix for package managers. + 5.2.0 ===== diff --git a/META.json b/META.json index 1ad237a..26c699f 100644 --- a/META.json +++ b/META.json @@ -1,7 +1,7 @@ { "name": "pg_partman", "abstract": "Extension to manage partitioned tables by time or ID", - "version": "5.2.0", + "version": "5.2.1", "maintainer": [ "Keith Fiske " ], @@ -20,9 +20,9 @@ }, "provides": { "pg_partman": { - "file": "sql/pg_partman--5.2.0.sql", + "file": "sql/pg_partman--5.2.1.sql", "docfile": "doc/pg_partman.md", - "version": "5.2.0", + "version": "5.2.1", "abstract": "Extension to manage partitioned tables by time or ID" } }, diff --git a/pg_partman.control b/pg_partman.control index 2b0e400..0cad8bd 100644 --- a/pg_partman.control +++ b/pg_partman.control @@ -1,4 +1,4 @@ -default_version = '5.2.0' +default_version = '5.2.1' comment = 'Extension to manage partitioned tables by time or ID' relocatable = false superuser = false diff --git a/updates/pg_partman--5.1.0--5.2.0.sql b/updates/pg_partman--5.1.0--5.2.0.sql index ef17425..cf50000 100644 --- a/updates/pg_partman--5.1.0--5.2.0.sql +++ b/updates/pg_partman--5.1.0--5.2.0.sql @@ -4250,6 +4250,10 @@ END LOOP; EXECUTE format('ANALYZE %I.%I', v_parent_schema, v_parent_tablename); +PERFORM pg_advisory_unlock(hashtext('pg_partman reapply_constraints')); +END +$$; + CREATE FUNCTION @extschema@.uuid7_time_encoder(ts TIMESTAMPTZ) RETURNS UUID @@ -4287,9 +4291,6 @@ BEGIN RETURN to_timestamp(ts_millis / 1000.0); END; $$; -PERFORM pg_advisory_unlock(hashtext('pg_partman reapply_constraints')); -END -$$; -- Restore dropped object privileges diff --git a/updates/pg_partman--5.2.0--5.2.1.sql b/updates/pg_partman--5.2.0--5.2.1.sql new file mode 100644 index 0000000..c68a712 --- /dev/null +++ b/updates/pg_partman--5.2.0--5.2.1.sql @@ -0,0 +1 @@ +-- NOTE: No changes to the sql extension code contained in this update. This file is only here for version upgrade continuity.