a
    bgN                     @   s@   d dl Z d dlmZ d dlmZ d dlmZ G dd deZdS )    N)Path)Union)
TextLoaderc                       s.   e Zd ZdZeeef d fddZ  ZS )PythonLoaderzFLoad `Python` files, respecting any non-default encoding if specified.)	file_pathc                    sN   t |d }t|j\}}W d   n1 s00    Y  t j||d dS )ziInitialize with a file path.

        Args:
            file_path: The path to the file to load.
        rbN)r   encoding)opentokenizedetect_encodingreadlinesuper__init__)selfr   fr   _	__class__ y/var/www/html/cobodadashboardai.evdpl.com/venv/lib/python3.9/site-packages/langchain_community/document_loaders/python.pyr      s    .zPythonLoader.__init__)	__name__
__module____qualname____doc__r   strr   r   __classcell__r   r   r   r   r      s   r   )r
   pathlibr   typingr   Z)langchain_community.document_loaders.textr   r   r   r   r   r   <module>   s   