
    ,hG                     n    d dl mZ d dlZd dlmZmZ ddlmZ  ej                  e	      Z
d Zd	dZd
dZy)    )unicode_literalsN)binary_type	text_type   )
exceptionsc                     t        | t              r	 | j                  d      S | S # t        $ r+ t        j                  d|        | j                  dd      cY S w xY w)NasciizAn error occurred while decoding %s in ASCII 'strict' mode. Fallback to 'ignore' errors handling, some characters might have been strippedignore)
isinstancer   decodeUnicodeDecodeErrorloggerwarning)ss    Q/var/www/html/Resume-Scraper/venv/lib/python3.12/site-packages/imapclient/util.py
to_unicoder      s`    ![!	/88G$$ H " 	/NNUVW 88GX..	/s   % 1AAc                 H    t        | t              r| j                  |      S | S N)r   r   encode)r   charsets     r   to_bytesr      s     !Yxx  H    c                 d    | s.d}|r|dj                  ||      z  }t        j                  |      y )Nz>Server replied with a response that violates the IMAP protocolz{}: {})formatr   ProtocolError)	conditionmessagemsgs      r   assert_imap_protocolr   "   s8    N8??300C&&s++	 r   )r	   r   )
__future__r   loggingsixr   r    r   	getLogger__name__r   r   r   r    r   r   <module>r'      s4   
 (  & 			8	$
,r   