
    Vh	                     v    d dl Z d dlmZ d dlmZ d dlmZ d dlmZ d dlmZ d dlm	Z	 d dl
mZ  G d	 d
e	      Zy)    N)AnsibleAction)AnsibleActionFail)AnsibleError)AnsibleFileNotFound)to_text)
ActionBase)
merge_hashc                   $     e Zd ZdZd fd	Z xZS )ActionModuleTc                 x   d| _         |
t               }t        |   ||      }~| j                  j
                  j                  dd      }	 | j                  j
                  j                         }|rct        j                  j                  |      }| j                  |      s3	 | j                  j                  | j                  d|      d      }||d<   | j                  j&                  xr | j(                  j*                   }t-        || j/                  |||            }|s/| j1                  | j(                  j2                  j4                         |S # t        $ r ||d<   Y t         $ r}t#        t%        |            d}~ww xY w# t6        $ r&}|j9                  |j:                         Y d}~|S d}~ww xY w)zhandler for s3_object operations

        This adds the magic that means 'src' can point to both a 'remote' file
        on the 'host' or in the 'files/' lookup path on the controller.
        TNsrcfilesF)decrypt)module_args	task_vars
wrap_async)_supports_asyncdictsuperrun_taskargsgetcopyospath
expanduser_remote_file_exists_loaderget_real_file_find_needler   r   r   r   	async_val_connectionhas_native_asyncr	   _execute_module_remove_tmp_path_shelltmpdirr   updateresult)	selftmpr   r*   sourcenew_module_argser   	__class__s	           g/home/dcms/DCMS/lib/python3.12/site-packages/ansible_collections/amazon/aws/plugins/action/s3_object.pyr   zActionModule.run   s     $IS),$$UD1	$"jjoo224O++F3 //7<!%!;!;D<M<MgW]<^hm!;!n17. --Wd6F6F6W6W2WJ,,T]jt,uF %%d&6&6&=&=&D&DE % / 817.' </
;;<  	$MM!((##	$sJ   AF
 $2E A>F
 F$F
 &F.FFF
 
	F9F44F9)NN)__name__
__module____qualname__TRANSFERS_FILESr   __classcell__)r0   s   @r1   r   r      s    O, ,    r   )r   ansible.errorsr   r   r   r   ansible.module_utils._textr   ansible.plugins.actionr   ansible.utils.varsr	   r    r7   r1   <module>r=      s+    
 ( , ' . . - )/: /r7   