Skip to content

Deprecate rename and rename_to choices/options #832

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 15, 2025

Conversation

Andersson007
Copy link
Collaborator

SUMMARY

Fixes #820

@andreasscherbaum
Copy link
Collaborator

I'd love to see an explanation as to why this is deprecated, but I don't know what is the right place for it.

Basically summarizing the discussion, pointing out that using "rename" is not playing well with state-based systems like Ansible.

Co-authored-by: Douglas J Hunley <doug.hunley@gmail.com>
@Andersson007
Copy link
Collaborator Author

I'd love to see an explanation as to why this is deprecated, but I don't know what is the right place for it.

Basically summarizing the discussion, pointing out that using "rename" is not playing well with state-based systems like Ansible.

@andreasscherbaum SGTM, i would avoid putting to much in the option's docs tough, how about:

Option 1: we add a link to the GH discussion which would give the full context, something like:

DEPRECATED (see the L(discussion,https://github.com/ansible-collections/community.postgresql/issues/820)). C(rename) is used to rename the database C(name) to C(target).
To rename a database, use the M(community.postgresql.postgresql_query) module.

Option 2: Add a more verbose note to the notes: section of the DOCUMENTATION block and refer from the option's doc to the note (though I personally like the link to the discussion option).

Thoughts, folks?

@andreasscherbaum
Copy link
Collaborator

Option 1 is already fine, I think. It's about giving users an idea as to why this is deprecated. Otherwise the discussion might start again.

@Andersson007
Copy link
Collaborator Author

Option 1 is already fine, I think. It's about giving users an idea as to why this is deprecated. Otherwise the discussion might start again.

Done, PTAL, thanks

Copy link
Collaborator

@andreasscherbaum andreasscherbaum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@Andersson007 Andersson007 merged commit 25748ad into ansible-collections:main Apr 15, 2025
26 checks passed
@Andersson007
Copy link
Collaborator Author

@andreasscherbaum @hunleyd thanks for reviewing and approving the changes!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deprecate the rename choice from modules. Schedule removal in one of the next major releases
3 participants