From 3b8ae44f04653dc3dffc7265ca3e32db62efef36 Mon Sep 17 00:00:00 2001 From: bingopriya Date: Thu, 27 Jul 2023 20:29:41 +0530 Subject: [PATCH] Fixes #1607 - Catch botocore exception when getting bucket tags --- plugins/modules/s3_object.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/modules/s3_object.py b/plugins/modules/s3_object.py index 8f36df398f0..0b5d658b7b9 100644 --- a/plugins/modules/s3_object.py +++ b/plugins/modules/s3_object.py @@ -920,6 +920,8 @@ def get_current_object_tags_dict(module, s3, bucket, obj, version=None): return {} except is_boto3_error_code(("NoSuchTagSet", "NoSuchTagSetError")): return {} + except botocore.exceptions.ClientError: + return {} return boto3_tag_list_to_ansible_dict(current_tags)