Skip to content

Commit

Permalink
s3_object: fix value typo from last to latest (#1847) (#1851)
Browse files Browse the repository at this point in the history
[PR #1847/84351137 backport][stable-6] s3_object: fix value typo from last to latest

This is a backport of PR #1847 as merged into main (8435113).
SUMMARY

Fixes #1777
Fixing value for overwrite to not produce deprecation warning on setting overwirte=latest.

ISSUE TYPE


Bugfix Pull Request

COMPONENT NAME

s3_object
ADDITIONAL INFORMATION

Reviewed-by: Mark Chappell
  • Loading branch information
patchback[bot] authored Nov 30, 2023
1 parent 7ae77f2 commit e8bcfd9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
bugfixes:
- s3_object - Fix typo that caused false deprecation warning when setting `overwrite=latest` (https://github.com/ansible-collections/amazon.aws/pull/1847).
4 changes: 2 additions & 2 deletions plugins/modules/s3_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -1481,11 +1481,11 @@ def main():
if "amazonaws.com" not in endpoint_url:
module.fail_json(msg="dualstack only applies to AWS S3")

if module.params.get("overwrite") not in ("always", "never", "different", "last"):
if module.params.get("overwrite") not in ("always", "never", "different", "latest"):
module.deprecate(
(
"Support for passing values of 'overwrite' other than 'always', 'never', "
"'different' or 'last', has been deprecated."
"'different' or 'latest', has been deprecated."
),
date="2024-12-01",
collection_name="amazon.aws",
Expand Down

0 comments on commit e8bcfd9

Please sign in to comment.