/opt/alt/python37/lib/python3.7/site-packages/pip/_internal/models
NameSizeModeActions
__pycache__/-0755rm
candidate.py11950644editdlrm
candidate.pyc18310644editdlrm
candidate.pyo18310644editdlrm
direct_url.py69000644editdlrm
format_control.py28230644editdlrm
index.py11610644editdlrm
index.pyc14830644editdlrm
index.pyo14830644editdlrm
link.py74700644editdlrm
link.pyc95060644editdlrm
link.pyo93400644editdlrm
scheme.py7780644editdlrm
scheme.pyc11430644editdlrm
scheme.pyo11430644editdlrm
search_scope.py47510644editdlrm
search_scope.pyc41480644editdlrm
search_scope.pyo41480644editdlrm
selection_prefs.py20440644editdlrm
selection_prefs.pyc19360644editdlrm
selection_prefs.pyo19360644editdlrm
target_python.py40340644editdlrm
target_python.pyc41060644editdlrm
target_python.pyo41060644editdlrm
wheel.py27720644editdlrm
__init__.py630644editdlrm
__init__.pyc2440644editdlrm
__init__.pyo2440644editdlrm
Edit: /opt/alt/python37/lib/python3.7/site-packages/pip/_internal/models/index.py (1161B)
from pip._vendor.six.moves.urllib import parse as urllib_parse class PackageIndex(object): """Represents a Package Index and provides easier access to endpoints """ __slots__ = ['url', 'netloc', 'simple_url', 'pypi_url', 'file_storage_domain'] def __init__(self, url, file_storage_domain): # type: (str, str) -> None super(PackageIndex, self).__init__() self.url = url self.netloc = urllib_parse.urlsplit(url).netloc self.simple_url = self._url_for_path('simple') self.pypi_url = self._url_for_path('pypi') # This is part of a temporary hack used to block installs of PyPI # packages which depend on external urls only necessary until PyPI can # block such packages themselves self.file_storage_domain = file_storage_domain def _url_for_path(self, path): # type: (str) -> str return urllib_parse.urljoin(self.url, path) PyPI = PackageIndex( 'https://pypi.org/', file_storage_domain='files.pythonhosted.org' ) TestPyPI = PackageIndex( 'https://test.pypi.org/', file_storage_domain='test-files.pythonhosted.org' )