a
    sh8                     @  sX   d dl mZ d dlZd dlZd dlmZ d dlmZ ee	Z
ddddddd	d
ZdS )    )annotationsN)BuildBackendHookCaller)runner_with_spinner_messagestrr   z
str | None)namebackendmetadata_directorytempdreturnc                 C  s   |dusJ zXt d| td|  d}|| |j||d}W d   n1 sX0    Y  W n  ty   t d|  Y dS 0 tj	||S )zBuild one InstallRequirement using the PEP 517 build process.

    Returns path to wheel if successfully built. Otherwise, returns None.
    NzDestination directory: %szBuilding wheel for z (pyproject.toml))r   zFailed building wheel for %s)
loggerdebugr   subprocess_runnerbuild_wheel	Exceptionerrorospathjoin)r   r   r   r	   runner
wheel_name r   `/var/www/html/assistant/venv/lib/python3.9/site-packages/pip/_internal/operations/build/wheel.pybuild_wheel_pep517   s    

(r   )
__future__r   loggingr   Zpip._vendor.pyproject_hooksr   pip._internal.utils.subprocessr   	getLogger__name__r   r   r   r   r   r   <module>   s   
