U ÀÒ.eƒ ã @ sš d dl Z d dlZd dlZd dlZd dlmZ d dlmZ d dl m Z d dlmZ d dl mZmZ d dlmZ er|d dlmZ e e¡ZG d d „ d eƒZdS )é N)Úcanonicalize_name)Úparse)ÚPyPI)ÚHAS_TLS)Únormalize_pathÚredact_auth_from_url)ÚMYPY_CHECK_RUNNING)ÚListc @ s4 e Zd ZdZedd„ ƒZdd„ Zdd„ Zdd „ Zd S )ÚSearchScopezF Encapsulates the locations that pip is configured to search. c C s~ g }|D ]0}| d¡r.t|ƒ}tj |¡r.|}| |¡ qtsrt ||¡D ]&}t |¡}|jdkrJt d¡ qrqJ| ||d�S )zQ Create a SearchScope object after normalizing the `find_links`. ú~Zhttpszipip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.©Ú find_linksÚ index_urls)Ú startswithr ÚosÚpathÚexistsÚappendr Ú itertoolsÚchainÚurllib_parseZurlparseZschemeÚloggerZwarning)Úclsr r Zbuilt_find_linksÚlinkZnew_linkZparsed© r úE/usr/lib/python3.8/site-packages/pip/_internal/models/search_scope.pyÚcreate s&