PK APOCALYPSE V1

APOCALYPSE V1

Current Path : /opt/alt/python39/lib/python3.9/site-packages/pip/_vendor/pep517/__pycache__/
Upload File :
Current File : //opt/alt/python39/lib/python3.9/site-packages/pip/_vendor/pep517/__pycache__/check.cpython-39.pyc

a

��Re��@s�dZddlZddlZddlZddlZddlmZmZddl	Z	ddl
mZddlZddl
Z
ddlmZddlZddlmZddlmZmZdd	lmZdd
lmZe�e�Zdd�Zd
d�Zdd�Zddd�Z ddddd�Z!dd�Z"edkr�e �dS)zHCheck a project and backend by attempting to build using PEP 517 hooks.
�N)�isfile�join)�CalledProcessError)�mkdtemp�)�enable_colourful_output)�TOMLDecodeError�	toml_load)�BuildEnvironment)�Pep517HookCallerc
CsHt���*}z|�|�t�d�Wn*tyLt�d�YWd�dS0z|�i�}t�d|�Wn.ty�tjddd�YWd�dS0z|�|�t�d�Wn*ty�t�d	�YWd�dS0t�}t�d
|��z$z|�	|i�}t�d|�Wn<t�yJtjddd�YWt
�|�Wd�dS0|�d
��s�t�d|�Wt
�|�Wd�dSt
||�}t|��r�t�d|�n(t�d|�Wt
�|�Wd�dSt�|��r�t�d�n&t�d�Wt
�|�Wd�dSWt
�|�nt
�|�0Wd�dS1�s:0YdS)N�#Installed static build dependencies�+Failed to install static build dependenciesF�Got build requires: %s�'Failure in get_requires_for_build_sdistT��exc_info�$Installed dynamic build dependencies�,Failed to install dynamic build dependencieszTrying to build sdist in %szbuild_sdist returned %rzFailure in build_sdistz.tar.gzz*Filename %s doesn't have .tar.gz extension�Output file %s exists�Output file %s does not existzOutput file is a tar filezOutput file is not a tar file)r
�pip_install�log�infor�error�get_requires_for_build_sdist�	Exceptionr�build_sdist�shutil�rmtree�endswith�pjoinr�tarfile�
is_tarfile��hooksZbuild_sys_requires�env�reqs�td�filename�path�r*��/builddir/build/BUILDROOT/alt-python39-pip-21.3.1-2.el8.x86_64/opt/alt/python39/lib/python3.9/site-packages/pip/_vendor/pep517/check.py�check_build_sdistsh






��
�

	
�

�r,c
CsHt���*}z|�|�t�d�Wn*tyLt�d�YWd�dS0z|�i�}t�d|�Wn.ty�tjddd�YWd�dS0z|�|�t�d�Wn*ty�t�d	�YWd�dS0t�}t�d
|��z$z|�	|i�}t�d|�Wn<t�yJtjddd�YWt
�|�Wd�dS0|�d
��s�t�d|�Wt
�|�Wd�dSt
||�}t|��r�t�d|�n(t�d|�Wt
�|�Wd�dSt�|��r�t�d�n&t�d�Wt
�|�Wd�dSWt
�|�nt
�|�0Wd�dS1�s:0YdS)Nrr
FrrTrrrzTrying to build wheel in %szbuild_wheel returned %rzFailure in build_wheelz.whlz'Filename %s doesn't have .whl extensionrrzOutput file is a zip filezOutput file is not a zip file)r
rrrrr�get_requires_for_build_wheelrr�build_wheelrrrr r�zipfile�
is_zipfiler#r*r*r+�check_build_wheelPsd






�
�

	
�

�r1c	Cs�t|d�}t|�rt�d�nt�d�dSzdt�|d��}t|�}Wd�n1sX0Y|d}|d}|d}|�d	�}t�d
�Wn&t	t
fy�tjddd
�YdS0t|||�}t||�}	t
||�}
|	s�t�d�|
s�t�d�|	S)Nzpyproject.tomlzFound pyproject.tomlzMissing pyproject.tomlF�rbzbuild-system�requiresz
build-backendzbackend-pathzLoaded pyproject.tomlzInvalid pyproject.tomlTrz%Sdist checks failed; scroll up to seezWheel checks failed)r rrrr�io�openr	�getr�KeyErrorrr,r1�warning)�
source_dir�	pyproject�fZpyproject_dataZbuildsysr3�backend�backend_pathr$Zsdist_okZwheel_okr*r*r+�check�s0

&




r>cCsjt�d�t��}|jddd�|�|�}t�t|j�}|rNt	t
dd��nt	t
dd��t�d	�dS)
NzQpep517.check is deprecated. Consider switching to https://pypi.org/project/build/r9z%A directory containing pyproject.toml)�helpz
Checks passed�greenz
Checks failed�redr)
rr8�argparse�ArgumentParser�add_argument�
parse_argsrr>r9�print�ansi�sys�exit)�argvZap�args�okr*r*r+�main�s
�

rMzzzz)�reset�boldrAr@cCs8tjdkr,tj��r,t|t|�tdSt|�SdS)N�ntrN)�os�namerH�stdout�isatty�
ansi_codes�str)�s�attrr*r*r+rG�srG�__main__)N)#�__doc__rBr4�loggingrQ�os.pathrrr r�
subprocessrrHr!�tempfilerr/Zcolorlogr�compatrr	Zenvbuildr
�wrappersr�	getLogger�__name__rr,r1r>rMrUrGr*r*r*r+�<module>s8
98"
�

if you don't want to be vaporized in a nuclear explosion, i simply have to become nuclear myself… i am atomic