chore(deps): update dependency community.postgresql to v5 #1019

Open
renovate-bot wants to merge 1 commit from renovate/community.postgresql-5.x into main
Collaborator

This PR contains the following updates:

Package Type Update Change
community.postgresql galaxy-collection major 4.2.0 -> 5.1.3

⚠️ Warning

Some dependencies could not be looked up. Check the Dependency Dashboard for more information.


Release Notes

ansible-collections/community.postgresql (community.postgresql)

v5.1.3

Compare Source

======

Release Summary

This is a patch release of the community.postgresql collection.
This changelog contains all changes to the modules and plugins in this collection
that have been made after the previous release.

Bugfixes

  • postgresql_alter_system - compare boolean values in every spelling PostgreSQL accepts, such as true, yes or 1, and enum values case-insensitively, so setting the same value again in another spelling or case, such as WARNING for log_min_messages, no longer reports a change (https://github.com/ansible-collections/community.postgresql/pull/998).
  • postgresql_alter_system - compare values of parameters of type real as floating point numbers with the 6 significant digits shown by pg_settings. Values such as 1.0 failed with cannot be converted to int, and so did every run for a parameter whose current value is shown in scientific notation, such as 1e-05. Parameters of type real with a time unit, such as vacuum_cost_delay, accept fractional values too (https://github.com/ansible-collections/community.postgresql/pull/997).
  • postgresql_alter_system - treat output_plugin_libraries (PostgreSQL 14.24, 15.19, 16.15, 17.11, 18.6 and later) and oauth_validator_libraries (PostgreSQL 18+) as GUC_LIST_QUOTE list parameters, so setting the same list again no longer reports a change (https://github.com/ansible-collections/community.postgresql/pull/996).
  • postgresql_alter_system - when a parameter is set for the role or the database the module connects to (ALTER ROLE/DATABASE ... SET), for all roles (ALTER ROLE ALL ... SET), for the connection or for the session, compare the desired value with the value in the configuration files instead of the session value shown by pg_settings. Previously the module could report no change and leave the server configuration untouched (https://github.com/ansible-collections/community.postgresql/pull/999).
  • postgresql_db - when restoring a compressed dump, report the error of psql or pg_restore if it fails. Before, a restore program that exited early (for example on an unknown option in target_opts or a failed login) made the decompressor die of SIGPIPE, and the module returned rc=-13 with an empty message (https://github.com/ansible-collections/community.postgresql/issues/916).
  • postgresql_publication - fix change detection for publish_via_partition_root (https://github.com/ansible-collections/community.postgresql/pull/984)
  • postgresql_query, postgresql_script - when a list of strings is passed in positional_args or named_args, quote its elements as PostgreSQL array elements instead of passing Python's single quotes as part of each element (https://github.com/ansible-collections/community.postgresql/issues/411).
  • postgresql_query, postgresql_script - when a list passed in positional_args or named_args contains None, send that element as SQL NULL instead of the text None, which was stored as a string in a text array and failed for other array types such as int[].

v5.1.2

Compare Source

======

Release Summary

This is a patch release of the community.postgresql collection.
This changelog contains all changes to the modules and plugins in this collection
that have been made after the previous release.

Bugfixes

v5.1.1

Compare Source

======

Release Summary

This is a patch release of the community.postgresql collection.
This changelog contains all changes to the modules and plugins in this collection
that have been made after the previous release.

Bugfixes

  • postgresql_alter_system - consistently quote configuration parameter name components in ALTER SYSTEM SET and RESET, preserving case and supporting quoted and unquoted names containing SQL keywords such as online_analyze.verbose (https://github.com/ansible-collections/community.postgresql/issues/940).
  • postgresql_db - keep the inherited environment (for example PGSSLMODE, PGSSLROOTCERT or PATH) when restoring a compressed dump with login_password set. Before, the environment of the restore command was replaced by PGPASSWORD alone, so it differed from the uncompressed restore path.
  • postgresql_ping - Handle beta and release-candidate server versions when parsing the version number.
  • postgresql_table - change the persistence of an existing table with ALTER TABLE ... SET UNLOGGED or ALTER TABLE ... SET LOGGED when unlogged is set explicitly and differs from the current state. unlogged no longer defaults to false, so existing tables are left as they are when the option is not set (https://github.com/ansible-collections/community.postgresql/issues/878).

v5.1.0

Compare Source

======

Release Summary

This is a minor release of the community.postgresql collection.
This changelog contains all changes to the modules and plugins in this collection
that have been made after the previous release.

Minor Changes

  • postgresql_user - the role name in O(name) is now taken literally, the way every other module in this collection treats a role name. The value "foo" creates a role called "foo" rather than foo, and the value we""ird creates we""ird rather than we"ird. Pass the literal role name in both cases.

Bugfixes

  • postgres module_utils - fix session_role containing a double quote producing invalid SQL in the SET ROLE issued on connect, which affects every module in this collection.
  • postgres module_utils - fix set_comment interpolating the object name into COMMENT ON unquoted, so a name containing a double quote produced invalid SQL or, under psycopg2, executed the rest of the name as SQL. Affects postgresql_user, postgresql_db, postgresql_schema, postgresql_ext, postgresql_publication, postgresql_subscription and postgresql_tablespace.
  • postgresql_db - fix a database, owner or tablespace name containing a double quote producing invalid SQL in ALTER DATABASE and DROP DATABASE.
  • postgresql_db - fix the database, owner, template and tablespace names in CREATE DATABASE being interpolated unquoted, so that a name containing a double quote produced invalid SQL. They are now quoted as single identifiers.
  • postgresql_ext - fix an extension or schema name containing a double quote producing invalid SQL in CREATE EXTENSION, ALTER EXTENSION and DROP EXTENSION. A per cent sign in such a name also broke CREATE EXTENSION and ALTER EXTENSION, which carry query parameters.
  • postgresql_idx - fix an index, schema, table or tablespace name containing a double quote producing invalid SQL in CREATE INDEX and DROP INDEX. The schema-qualified names are quoted per part, so a dot in either name stays part of that name.
  • postgresql_info - fix the module failing with 'bool' object is not iterable when a database has no extensions installed. A query that returns no rows now gives an empty result instead of False (https://github.com/ansible-collections/community.postgresql/issues/959).
  • postgresql_owner - fix a database, tablespace or language name containing a double quote producing invalid SQL in ALTER DATABASE, ALTER TABLESPACE and ALTER LANGUAGE. The language name was interpolated unquoted and is now quoted as a single identifier.
  • postgresql_owner - fix a role whose name contains a double quote producing invalid SQL. The name is now quoted as a single identifier with embedded quotes doubled, in the OWNER TO and REASSIGN OWNED BY statements alike.
  • postgresql_privs - fix a name containing a double quote in objs producing invalid SQL for object types that are not schema qualified, which covers type=group as well as database, schema, language, tablespace, foreign_server, foreign_data_wrapper and parameter.
  • postgresql_privs - fix a role named in target_roles whose name contains a double quote producing invalid SQL in the generated ALTER DEFAULT PRIVILEGES FOR ROLE statement.
  • postgresql_privs - fix an object name containing a double quote producing invalid SQL for schema-qualified types, and session_role containing one producing invalid SQL in SET ROLE.
  • postgresql_publication - fix an owner name containing a double quote producing invalid SQL in ALTER PUBLICATION ... OWNER TO.
  • postgresql_schema - fix an owner name containing a double quote producing invalid SQL in CREATE SCHEMA ... AUTHORIZATION and ALTER SCHEMA ... OWNER TO.
  • postgresql_sequence - fix a sequence, schema or owner name containing a double quote producing invalid SQL in ALTER SEQUENCE.
  • postgresql_subscription - fix a subscription, publication or owner name containing a double quote producing invalid SQL in CREATE SUBSCRIPTION, ALTER SUBSCRIPTION and DROP SUBSCRIPTION.
  • postgresql_table - fix an owner or tablespace name containing a double quote producing invalid SQL in CREATE TABLE and ALTER TABLE.
  • postgresql_tablespace - fix a tablespace or owner name containing a double quote producing invalid SQL in CREATE TABLESPACE, ALTER TABLESPACE and DROP TABLESPACE.
  • postgresql_user - fix a key in O(configuration) containing a double quote producing invalid SQL in ALTER ROLE ... SET and ALTER ROLE ... RESET when O(quote_configuration_values=false). The key is now quoted as a single identifier.
  • postgresql_user - fix a role whose name contains a double quote being rejected with User escaped identifiers must escape extra quotes. Such a name is now escaped and accepted, and a name that is not a balanced pair of quotes no longer fails.
  • postgresql_user, postgresql_db, postgres module_utils - fix a name containing a per cent sign breaking CREATE USER, ALTER USER, CREATE DATABASE and COMMENT ON, which also carry query parameters. Such a name either failed with unsupported format character or had a parameter interpolated into it; a name of the form x%(password)sy put the password into the role name.

v5.0.0

Compare Source

======

Release Summary

This is a major release of the community.postgresql collection.
This changelog contains all changes to the modules and plugins in this collection
that have been made after the previous release.

Minor Changes

  • Replace the deprecated ansible.module_utils.six compatibility shims with their Python standard library equivalents. ansible.module_utils.six is deprecated in ansible-core 2.21 and is scheduled for removal in 2.24.
  • postgresql_membership - add granted_by_any, at the top level and per memberships row, to manage every grant of a membership whoever made it, as the deprecated groups option does. GRANT then names no granting role, and state=absent and state=exact revoke every grant of the membership. On every version, groups of x is granted_by_any set with a memberships row of x.
  • postgresql_membership - add the grants and effective_options return values, listing every grant of the requested pairs and the options the target role effectively holds.
  • postgresql_membership - add the memberships option, one membership per row with its own target_roles, granted_by, admin_option, inherit_option and set_option, applied in one transaction. Mutually exclusive with groups; the top-level target_roles is the default for rows that name none (https://github.com/ansible-collections/community.postgresql/issues/757).
  • postgresql_membership - move PgMembership from the postgres module_utils into a new membership module_utils, split into PgMembershipByPair (the groups model) and PgMembershipByGrantor (the memberships model). External importers have to follow the move.
  • postgresql_membership - with memberships, check before emitting a GRANT that the connecting role has the privileges of the granting role and that the granting role holds ADMIN OPTION on the group, and fail naming the roles that do hold it. The deprecated groups option gets the privilege check for every granting role it finds recorded before it revokes. A task with nothing left to do is not checked.

Breaking Changes / Porting Guide

  • postgresql_membership - state=exact now reports granted with an entry for every requested group, as state=present does, so result.granted == {} no longer holds on an unchanged run.
  • postgresql_membership - a memberships row must set granted_by when the connecting role holds ADMIN OPTION on a group only through another role, since PostgreSQL refuses a grant recorded under a role without the option. The deprecated groups option is not affected.
  • postgresql_membership - on PostgreSQL 16 and later a memberships row manages the one grant recorded under its granting role, which is the bootstrap superuser when the connecting role is a superuser, the connecting role otherwise, or the role named by granted_by. state=present makes that grant even when another role has granted the membership, and state=absent and state=exact neither revoke nor report a grant recorded under another role. A task that was unchanged may report changed on its first run and fire its handlers. The deprecated groups option keeps treating the (group, target role) pair as the membership, whoever granted it (https://github.com/ansible-collections/community.postgresql/issues/757).

Deprecated Features

  • postgresql_membership - the top-level groups option is deprecated and will be removed in community.postgresql 6.0.0. granted_by_any with the groups key of memberships behaves the same on every version; target_roles stays at the top level, and an empty memberships list with state=exact replaces an empty groups list.

Removed Features (previously deprecated)

Bugfixes

  • postgresql_membership - fix state=absent and state=exact not removing a membership on PostgreSQL 16 and later when another role had granted it, and reporting a change on every run. The deprecated groups option now revokes every grant of the pair, one REVOKE per granting role, and fails naming the granting role when the connecting role lacks its privileges, where it used to succeed without revoking anything (https://github.com/ansible-collections/community.postgresql/issues/757).
  • postgresql_membership - fix a group named more than once being granted or revoked twice.
  • postgresql_membership - fix a group or role name containing a quote producing invalid SQL.
  • postgresql_membership - fix an empty target_roles list failing with a SQL syntax error; it is now a no-op.

v4.2.2

Compare Source

See stable-4/CHANGELOG for all changes

v4.2.1

Compare Source

See stable-4/CHANGELOG for all changes


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

♻️ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Renovate Bot.

This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [community.postgresql](https://github.com/ansible-collections/community.postgresql) | galaxy-collection | major | `4.2.0` -> `5.1.3` | --- > :warning: **Warning** > > Some dependencies could not be looked up. Check the Dependency Dashboard for more information. --- ### Release Notes <details> <summary>ansible-collections/community.postgresql (community.postgresql)</summary> ### [`v5.1.3`](https://github.com/ansible-collections/community.postgresql/blob/HEAD/CHANGELOG.rst#v513) [Compare Source](https://github.com/ansible-collections/community.postgresql/compare/5.1.2...5.1.3) \====== ## Release Summary This is a patch release of the `community.postgresql` collection. This changelog contains all changes to the modules and plugins in this collection that have been made after the previous release. ## Bugfixes - postgresql_alter_system - compare boolean values in every spelling PostgreSQL accepts, such as `true`, `yes` or `1`, and enum values case-insensitively, so setting the same value again in another spelling or case, such as `WARNING` for `log_min_messages`, no longer reports a change (https://github.com/ansible-collections/community.postgresql/pull/998). - postgresql_alter_system - compare values of parameters of type real as floating point numbers with the 6 significant digits shown by `pg_settings`. Values such as `1.0` failed with `cannot be converted to int`, and so did every run for a parameter whose current value is shown in scientific notation, such as `1e-05`. Parameters of type real with a time unit, such as `vacuum_cost_delay`, accept fractional values too (https://github.com/ansible-collections/community.postgresql/pull/997). - postgresql_alter_system - treat `output_plugin_libraries` (PostgreSQL 14.24, 15.19, 16.15, 17.11, 18.6 and later) and `oauth_validator_libraries` (PostgreSQL 18+) as GUC_LIST_QUOTE list parameters, so setting the same list again no longer reports a change (https://github.com/ansible-collections/community.postgresql/pull/996). - postgresql_alter_system - when a parameter is set for the role or the database the module connects to (`ALTER ROLE/DATABASE ... SET`), for all roles (`ALTER ROLE ALL ... SET`), for the connection or for the session, compare the desired value with the value in the configuration files instead of the session value shown by `pg_settings`. Previously the module could report no change and leave the server configuration untouched (https://github.com/ansible-collections/community.postgresql/pull/999). - postgresql_db - when restoring a compressed dump, report the error of `psql` or `pg_restore` if it fails. Before, a restore program that exited early (for example on an unknown option in `target_opts` or a failed login) made the decompressor die of `SIGPIPE`, and the module returned `rc=-13` with an empty message (https://github.com/ansible-collections/community.postgresql/issues/916). - postgresql_publication - fix change detection for publish_via_partition_root (https://github.com/ansible-collections/community.postgresql/pull/984) - postgresql_query, postgresql_script - when a list of strings is passed in `positional_args` or `named_args`, quote its elements as PostgreSQL array elements instead of passing Python's single quotes as part of each element (https://github.com/ansible-collections/community.postgresql/issues/411). - postgresql_query, postgresql_script - when a list passed in `positional_args` or `named_args` contains `None`, send that element as SQL `NULL` instead of the text `None`, which was stored as a string in a text array and failed for other array types such as `int[]`. ### [`v5.1.2`](https://github.com/ansible-collections/community.postgresql/blob/HEAD/CHANGELOG.rst#v512) [Compare Source](https://github.com/ansible-collections/community.postgresql/compare/5.1.1...5.1.2) \====== ## Release Summary This is a patch release of the `community.postgresql` collection. This changelog contains all changes to the modules and plugins in this collection that have been made after the previous release. ## Bugfixes - postgresql_alter_system - compare the desired value with the value pending in the configuration files when a parameter waits for a restart, so running the same task again no longer reports a change (https://github.com/ansible-collections/community.postgresql/issues/597). - postgresql_privs - fixed revocation of default privileges to respect the requested `privs` and `objs` when `state: absent` is used (https://github.com/ansible-collections/community.postgresql/issues/582). To retain the previous behavior of revoking all default privileges on TABLES, FUNCTIONS, SEQUENCES and TYPES, use `objs: ALL_DEFAULT` with `privs: ALL`. ### [`v5.1.1`](https://github.com/ansible-collections/community.postgresql/blob/HEAD/CHANGELOG.rst#v511) [Compare Source](https://github.com/ansible-collections/community.postgresql/compare/5.1.0...5.1.1) \====== ## Release Summary This is a patch release of the `community.postgresql` collection. This changelog contains all changes to the modules and plugins in this collection that have been made after the previous release. ## Bugfixes - postgresql_alter_system - consistently quote configuration parameter name components in ALTER SYSTEM SET and RESET, preserving case and supporting quoted and unquoted names containing SQL keywords such as `online_analyze.verbose` (https://github.com/ansible-collections/community.postgresql/issues/940). - postgresql_db - keep the inherited environment (for example `PGSSLMODE`, `PGSSLROOTCERT` or `PATH`) when restoring a compressed dump with `login_password` set. Before, the environment of the restore command was replaced by `PGPASSWORD` alone, so it differed from the uncompressed restore path. - postgresql_ping - Handle beta and release-candidate server versions when parsing the version number. - postgresql_table - change the persistence of an existing table with `ALTER TABLE ... SET UNLOGGED` or `ALTER TABLE ... SET LOGGED` when `unlogged` is set explicitly and differs from the current state. `unlogged` no longer defaults to `false`, so existing tables are left as they are when the option is not set (https://github.com/ansible-collections/community.postgresql/issues/878). ### [`v5.1.0`](https://github.com/ansible-collections/community.postgresql/blob/HEAD/CHANGELOG.rst#v510) [Compare Source](https://github.com/ansible-collections/community.postgresql/compare/5.0.0...5.1.0) \====== ## Release Summary This is a minor release of the `community.postgresql` collection. This changelog contains all changes to the modules and plugins in this collection that have been made after the previous release. ## Minor Changes - postgresql_user - the role name in O(name) is now taken literally, the way every other module in this collection treats a role name. The value `"foo"` creates a role called `"foo"` rather than `foo`, and the value `we""ird` creates `we""ird` rather than `we"ird`. Pass the literal role name in both cases. ## Bugfixes - postgres module_utils - fix `session_role` containing a double quote producing invalid SQL in the `SET ROLE` issued on connect, which affects every module in this collection. - postgres module_utils - fix `set_comment` interpolating the object name into `COMMENT ON` unquoted, so a name containing a double quote produced invalid SQL or, under psycopg2, executed the rest of the name as SQL. Affects `postgresql_user`, `postgresql_db`, `postgresql_schema`, `postgresql_ext`, `postgresql_publication`, `postgresql_subscription` and `postgresql_tablespace`. - postgresql_db - fix a database, owner or tablespace name containing a double quote producing invalid SQL in `ALTER DATABASE` and `DROP DATABASE`. - postgresql_db - fix the database, owner, template and tablespace names in `CREATE DATABASE` being interpolated unquoted, so that a name containing a double quote produced invalid SQL. They are now quoted as single identifiers. - postgresql_ext - fix an extension or schema name containing a double quote producing invalid SQL in `CREATE EXTENSION`, `ALTER EXTENSION` and `DROP EXTENSION`. A per cent sign in such a name also broke `CREATE EXTENSION` and `ALTER EXTENSION`, which carry query parameters. - postgresql_idx - fix an index, schema, table or tablespace name containing a double quote producing invalid SQL in `CREATE INDEX` and `DROP INDEX`. The schema-qualified names are quoted per part, so a dot in either name stays part of that name. - postgresql_info - fix the module failing with `'bool' object is not iterable` when a database has no extensions installed. A query that returns no rows now gives an empty result instead of `False` (https://github.com/ansible-collections/community.postgresql/issues/959). - postgresql_owner - fix a database, tablespace or language name containing a double quote producing invalid SQL in `ALTER DATABASE`, `ALTER TABLESPACE` and `ALTER LANGUAGE`. The language name was interpolated unquoted and is now quoted as a single identifier. - postgresql_owner - fix a role whose name contains a double quote producing invalid SQL. The name is now quoted as a single identifier with embedded quotes doubled, in the `OWNER TO` and `REASSIGN OWNED BY` statements alike. - postgresql_privs - fix a name containing a double quote in `objs` producing invalid SQL for object types that are not schema qualified, which covers `type=group` as well as `database`, `schema`, `language`, `tablespace`, `foreign_server`, `foreign_data_wrapper` and `parameter`. - postgresql_privs - fix a role named in `target_roles` whose name contains a double quote producing invalid SQL in the generated `ALTER DEFAULT PRIVILEGES FOR ROLE` statement. - postgresql_privs - fix an object name containing a double quote producing invalid SQL for schema-qualified types, and `session_role` containing one producing invalid SQL in `SET ROLE`. - postgresql_publication - fix an owner name containing a double quote producing invalid SQL in `ALTER PUBLICATION ... OWNER TO`. - postgresql_schema - fix an owner name containing a double quote producing invalid SQL in `CREATE SCHEMA ... AUTHORIZATION` and `ALTER SCHEMA ... OWNER TO`. - postgresql_sequence - fix a sequence, schema or owner name containing a double quote producing invalid SQL in `ALTER SEQUENCE`. - postgresql_subscription - fix a subscription, publication or owner name containing a double quote producing invalid SQL in `CREATE SUBSCRIPTION`, `ALTER SUBSCRIPTION` and `DROP SUBSCRIPTION`. - postgresql_table - fix an owner or tablespace name containing a double quote producing invalid SQL in `CREATE TABLE` and `ALTER TABLE`. - postgresql_tablespace - fix a tablespace or owner name containing a double quote producing invalid SQL in `CREATE TABLESPACE`, `ALTER TABLESPACE` and `DROP TABLESPACE`. - postgresql_user - fix a key in O(configuration) containing a double quote producing invalid SQL in `ALTER ROLE ... SET` and `ALTER ROLE ... RESET` when O(quote_configuration_values=false). The key is now quoted as a single identifier. - postgresql_user - fix a role whose name contains a double quote being rejected with `User escaped identifiers must escape extra quotes`. Such a name is now escaped and accepted, and a name that is not a balanced pair of quotes no longer fails. - postgresql_user, postgresql_db, postgres module_utils - fix a name containing a per cent sign breaking `CREATE USER`, `ALTER USER`, `CREATE DATABASE` and `COMMENT ON`, which also carry query parameters. Such a name either failed with `unsupported format character` or had a parameter interpolated into it; a name of the form `x%(password)sy` put the password into the role name. ### [`v5.0.0`](https://github.com/ansible-collections/community.postgresql/blob/HEAD/CHANGELOG.rst#v500) [Compare Source](https://github.com/ansible-collections/community.postgresql/compare/4.2.2...5.0.0) \====== ## Release Summary This is a major release of the `community.postgresql` collection. This changelog contains all changes to the modules and plugins in this collection that have been made after the previous release. ## Minor Changes - Replace the deprecated `ansible.module_utils.six` compatibility shims with their Python standard library equivalents. `ansible.module_utils.six` is deprecated in ansible-core 2.21 and is scheduled for removal in 2.24. - postgresql_membership - add `granted_by_any`, at the top level and per `memberships` row, to manage every grant of a membership whoever made it, as the deprecated `groups` option does. `GRANT` then names no granting role, and `state=absent` and `state=exact` revoke every grant of the membership. On every version, `groups` of `x` is `granted_by_any` set with a `memberships` row of `x`. - postgresql_membership - add the `grants` and `effective_options` return values, listing every grant of the requested pairs and the options the target role effectively holds. - postgresql_membership - add the `memberships` option, one membership per row with its own `target_roles`, `granted_by`, `admin_option`, `inherit_option` and `set_option`, applied in one transaction. Mutually exclusive with `groups`; the top-level `target_roles` is the default for rows that name none (https://github.com/ansible-collections/community.postgresql/issues/757). - postgresql_membership - move `PgMembership` from the `postgres` module_utils into a new `membership` module_utils, split into `PgMembershipByPair` (the `groups` model) and `PgMembershipByGrantor` (the `memberships` model). External importers have to follow the move. - postgresql_membership - with `memberships`, check before emitting a `GRANT` that the connecting role has the privileges of the granting role and that the granting role holds `ADMIN OPTION` on the group, and fail naming the roles that do hold it. The deprecated `groups` option gets the privilege check for every granting role it finds recorded before it revokes. A task with nothing left to do is not checked. ## Breaking Changes / Porting Guide - postgresql_membership - `state=exact` now reports `granted` with an entry for every requested group, as `state=present` does, so `result.granted == {}` no longer holds on an unchanged run. - postgresql_membership - a `memberships` row must set `granted_by` when the connecting role holds `ADMIN OPTION` on a group only through another role, since PostgreSQL refuses a grant recorded under a role without the option. The deprecated `groups` option is not affected. - postgresql_membership - on PostgreSQL 16 and later a `memberships` row manages the one grant recorded under its granting role, which is the bootstrap superuser when the connecting role is a superuser, the connecting role otherwise, or the role named by `granted_by`. `state=present` makes that grant even when another role has granted the membership, and `state=absent` and `state=exact` neither revoke nor report a grant recorded under another role. A task that was unchanged may report changed on its first run and fire its handlers. The deprecated `groups` option keeps treating the (group, target role) pair as the membership, whoever granted it (https://github.com/ansible-collections/community.postgresql/issues/757). ## Deprecated Features - postgresql_membership - the top-level `groups` option is deprecated and will be removed in `community.postgresql 6.0.0`. `granted_by_any` with the `groups` key of `memberships` behaves the same on every version; `target_roles` stays at the top level, and an empty `memberships` list with `state=exact` replaces an empty `groups` list. ## Removed Features (previously deprecated) - postgresql modules - the `login`, `host`, `unix_socket` and `port` aliases have been removed in `community.postgresql 5.0.0`. Use the `login_user`, `login_host`, `login_unix_socket` and `login_port` options instead (https://github.com/ansible-collections/community.postgresql/issues/847). - postgresql_copy - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_db - the `rename` choice of the `state` option has been removed. Use the `community.postgresql.postgresql_query` module instead (https://github.com/ansible-collections/community.postgresql/issues/833). - postgresql_ext - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_idx - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_membership - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_owner - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_pg_hba - the `keep_comments_at_rules` option has been removed. It had no effect since it was deprecated (https://github.com/ansible-collections/community.postgresql/issues/810). - postgresql_ping - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_privs - the `db` and `database` aliases of the `login_db` option have been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_publication - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_query - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_schema - the `db` and `database` aliases of the `login_db` option have been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_script - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_sequence - the `db` and `database` aliases of the `login_db` option have been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_sequence - the `rename_to` option has been removed. Use the `community.postgresql.postgresql_query` module instead (https://github.com/ansible-collections/community.postgresql/issues/833). - postgresql_set - the module has been removed. Please use the `community.postgresql.postgresql_alter_system` module instead (https://github.com/ansible-collections/community.postgresql/issues/823). - postgresql_slot - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_subscription - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_table - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_table - the `rename` option has been removed. Use the `community.postgresql.postgresql_query` module instead (https://github.com/ansible-collections/community.postgresql/issues/833). - postgresql_tablespace - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_tablespace - the `rename_to` option has been removed. Use the `community.postgresql.postgresql_query` module instead (https://github.com/ansible-collections/community.postgresql/issues/833). - postgresql_user - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). - postgresql_user_obj_stat_info - the `db` alias of the `login_db` option has been removed. Use the `login_db` option instead (https://github.com/ansible-collections/community.postgresql/issues/831). ## Bugfixes - postgresql_membership - fix `state=absent` and `state=exact` not removing a membership on PostgreSQL 16 and later when another role had granted it, and reporting a change on every run. The deprecated `groups` option now revokes every grant of the pair, one `REVOKE` per granting role, and fails naming the granting role when the connecting role lacks its privileges, where it used to succeed without revoking anything (https://github.com/ansible-collections/community.postgresql/issues/757). - postgresql_membership - fix a group named more than once being granted or revoked twice. - postgresql_membership - fix a group or role name containing a quote producing invalid SQL. - postgresql_membership - fix an empty `target_roles` list failing with a SQL syntax error; it is now a no-op. ### [`v4.2.2`](https://github.com/ansible-collections/community.postgresql/releases/tag/4.2.2) [Compare Source](https://github.com/ansible-collections/community.postgresql/compare/4.2.1...4.2.2) See [stable-4/CHANGELOG](https://github.com/ansible-collections/community.postgresql/blob/stable-4/CHANGELOG.rst) for all changes ### [`v4.2.1`](https://github.com/ansible-collections/community.postgresql/releases/tag/4.2.1) [Compare Source](https://github.com/ansible-collections/community.postgresql/compare/4.2.0...4.2.1) See [stable-4/CHANGELOG](https://github.com/ansible-collections/community.postgresql/blob/stable-4/CHANGELOG.rst) for all changes </details> --- ### Configuration :date: **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yNjQuMCIsInVwZGF0ZWRJblZlciI6IjM5LjI2NC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
renovate-bot force-pushed renovate/community.postgresql-5.x from 5ea554165a to d54f5841bf 2026-10-21 18:35:50 +00:00 Compare
renovate-bot force-pushed renovate/community.postgresql-5.x from d54f5841bf to af47ef718a 2026-10-21 19:51:58 +00:00 Compare
renovate-bot force-pushed renovate/community.postgresql-5.x from af47ef718a to 3bb34f74fc 2026-10-21 20:09:13 +00:00 Compare
renovate-bot force-pushed renovate/community.postgresql-5.x from 3bb34f74fc to cfeaeae0a5 2026-10-23 12:06:47 +00:00 Compare
renovate-bot force-pushed renovate/community.postgresql-5.x from cfeaeae0a5 to 55d6b5565e 2026-10-25 10:05:51 +00:00 Compare
renovate-bot force-pushed renovate/community.postgresql-5.x from 55d6b5565e to 5c023943d0 2026-10-25 12:06:24 +00:00 Compare
renovate-bot force-pushed renovate/community.postgresql-5.x from 5c023943d0 to 36ef8ecde3 2026-11-06 12:07:32 +00:00 Compare
renovate-bot force-pushed renovate/community.postgresql-5.x from 36ef8ecde3 to 09b888f4d9 2026-11-13 10:07:31 +00:00 Compare
renovate-bot force-pushed renovate/community.postgresql-5.x from 09b888f4d9 to 998b23eefe 2026-11-27 10:07:39 +00:00 Compare
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'renovate/community.postgresql-5.x:renovate/community.postgresql-5.x'
git switch 'renovate/community.postgresql-5.x'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'renovate/community.postgresql-5.x'
git switch 'renovate/community.postgresql-5.x'
git rebase 'main'
git switch 'main'
git merge --ff-only 'renovate/community.postgresql-5.x'
git switch 'renovate/community.postgresql-5.x'
git rebase 'main'
git switch 'main'
git merge --no-ff 'renovate/community.postgresql-5.x'
git switch 'main'
git merge --squash 'renovate/community.postgresql-5.x'
git switch 'main'
git merge --ff-only 'renovate/community.postgresql-5.x'
git switch 'main'
git merge 'renovate/community.postgresql-5.x'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
peschmae/ansible-home-borr!1019
No description provided.