
    i6                     *    d dl Z d dlmZ defdZd Zy)    N)Unionsecondsc                     t        | t              r	 d| v rt        |       } nt        |       } t        j                  |        y# t        $ r t        |       } Y ,w xY w)zl
    Wait for a specified number of seconds.

    Args:
        seconds: The number of seconds to wait.
    .N)
isinstancestrfloatint
ValueErrortimesleep)r   s    M/Users/bowang/.openclaw/workspace/ChatDev/functions/function_calling/utils.pywaitr      sT     '3	%g~.g,
 	JJw	  	%GnG	%s   A AAc                  R    t        j                  dt        j                               S )z
    Get the current time in the format: YYYY-MM-DD HH:MM:SS.
    
    Returns:
        str: The current time in the format: YYYY-MM-DD HH:MM:SS.
    z%Y-%m-%d %H:%M:%S)r   strftime	localtime     r   get_current_timer      s     ==,dnn.>??r   )r   typingr   r	   r   r   r   r   r   <module>r      s     % (@r   