B
    ø¸h  ã               @   s8   d dl mZmZ d dlmZ d dlmZmZ dd„ ZdS )é   )ÚPY2ÚPY3)ÚUniversalDetector)Ú__version__ÚVERSIONc             C   sH   t | tƒs0t | tƒs(td t| ƒ¡ƒ‚nt| ƒ} tƒ }| | ¡ | ¡ S )z£
    Detect the encoding of the given byte string.

    :param byte_str:     The byte sequence to examine.
    :type byte_str:      ``bytes`` or ``bytearray``
    z4Expected object of type bytes or bytearray, got: {0})	Ú
isinstanceÚ	bytearrayÚbytesÚ	TypeErrorÚformatÚtyper   ÚfeedÚclose)Zbyte_strZdetector© r   úMC:\Users\sanjo\AppData\Local\Qlobot\Launcher\ext_packages\chardet\__init__.pyÚdetect   s    


r   N)	Úcompatr   r   Zuniversaldetectorr   Úversionr   r   r   r   r   r   r   Ú<module>   s   