U
    ÉZj³  ã                   @   s¸  d Z ddlZddlZddlZddlZdZdd„ ZdZzddlm	Z	 ee	j
ƒZW n ek
rb   Y nX dd„ Zedkr”ed	ƒr‚d
Znedƒr�dZndZe de¡Zedkr¶ed e¡ƒ‚dejkrÖedkrÖe d¡ dZdZedk�r&z ddlmZ eejd< eZ[W n  ek
�r$   e d¡ Y nX ed
k�rlzddlmZ eZ[W n$ ek
�rj   e d¡ dZY nX zddlmZ dZW n ek
�rš   dZY nX dd„ Zdd„ Zdd„ ZdS )zLDetermine which implementation of the protobuf API is used in this process.
é    NTc                 C   s,   | dkrdS | dkrt dƒ‚| dkr(dS d S )Né   Úcppé   z%api_version=1 is no longer supported.r   Úpython)Ú
ValueError)Úapi_version© r   ún/var/www/html/TRUCKING_PROJECT/venv/lib/python3.8/site-packages/google/protobuf/internal/api_implementation.pyÚ_ApiVersionToImplementationType   s    r
   )Ú_api_implementationc                 C   s<   z t  | ¡}|st| d ƒ‚W dS  tk
r6   Y dS X d S )Nz import succeeded but was NoneTF)Ú	importlibÚimport_moduleÚImportError)Úmod_nameÚmodr   r   r	   Ú
_CanImport)   s    
r   zgoogle._upb._messageÚupbzgoogle.protobuf.pyext._messager   r   Z&PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION)r   r   r   zdPROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION {0} is not supported. Please set to 'python', 'cpp' or 'upb'.ÚPyPyz\PyPy does not work yet with cpp protocol buffers. Falling back to the python implementation.)Ú_messagez/google3.net.proto2.python.internal.cpp._messagez-Selected implementation cpp is not available.zXSelected implementation upb is not available. Falling back to the python implementation.)Ú(enable_deterministic_proto_serializationFc                   C   s   t S ©N)Ú_implementation_typer   r   r   r	   ÚType‚   s    r   c                   C   s   dS )Nr   r   r   r   r   r	   ÚVersionˆ   s    r   c                   C   s   t S r   )Ú)_python_deterministic_proto_serializationr   r   r   r	   Ú)IsPythonDefaultSerializationDeterministic�   s    r   )Ú__doc__r   ÚosÚsysÚwarningsZ_GOOGLE3_PYTHON_UPB_DEFAULTr
   r   Zgoogle.protobuf.internalr   r   r   r   Úgetenvr   ÚformatÚversionÚwarnZ	_c_moduleZgoogle.protobuf.pyextr   ÚmodulesZgoogle._upbZgoogle.protobufr   r   r   r   r   r   r   r   r	   Ú<module>   sx   
ÿÿþ


ÿ


