o ais @ s d Z ddlmZ ddlZddlZddlZddlZddlZddlZddl Z ddl Z ddlZddlm Z mZ ddlmZ ddlmZmZ ddlmZmZmZmZ dd lmZmZmZmZmZmZm Z g d Z!e"e#Z$dZ%dZ&d eddde%dfZ'dZ(G dd de)Z*G dd de)Z+G dd de)Z,G dd de,Z-G dd de-Z.G dd de-Z/e.Z0e/Z1G dd d e)Z2d*d"d#Z3d$d% Z4d&d' Z5d(d) Z6dS )+zPEP 376 implementation. )unicode_literalsN )DistlibException resources)StringIO) get_schemeUnsupportedVersionError)MetadataMETADATA_FILENAMEWHEEL_METADATA_FILENAMELEGACY_METADATA_FILENAME)parse_requirementcached_propertyparse_name_and_versionread_exports write_exports CSVReader CSVWriter)DistributionBaseInstalledDistributionInstalledDistributionEggInfoDistributionDistributionPathzpydist-exports.jsonzpydist-commands.json INSTALLERRECORD REQUESTED RESOURCESSHAREDz .dist-infoc @ s( e Zd ZdZdd Zdd Zdd ZdS ) _CachezL A simple cache mapping names and .dist-info paths to distributions c C s i | _ i | _d| _dS )zZ Initialise an instance. There is normally one for each DistributionPath. FN)namepath generatedself r$ /builddir/build/BUILDROOT/alt-python310-pip-21.3.1-5.el8.x86_64/opt/alt/python310/lib/python3.10/site-packages/pip/_vendor/distlib/database.py__init__1 s z_Cache.__init__c C s | j | j d| _dS )zC Clear the cache, setting it to its initial state. FN)r clearr r! r" r$ r$ r% r' 9 s z_Cache.clearc C s6 |j | j vr|| j |j <