Qucs-S S-parameter Viewer & RF Synthesis Tools
Loading...
Searching...
No Matches
Classes | Functions | Variables
pip._vendor.distlib.metadata Namespace Reference

Classes

class  LegacyMetadata
 
class  Metadata
 
class  MetadataConflictError
 
class  MetadataInvalidError
 
class  MetadataMissingError
 
class  MetadataUnrecognizedVersionError
 

Functions

 _version2fieldlist (version)
 
 _best_version (fields)
 
 _get_name_and_version (name, version, for_filename=False)
 

Variables

 logger = logging.getLogger(__name__)
 
str PKG_INFO_ENCODING = 'utf-8'
 
str PKG_INFO_PREFERRED_VERSION = '1.1'
 
 _LINE_PREFIX_1_2 = re.compile('\n \\|')
 
 _LINE_PREFIX_PRE_1_2 = re.compile('\n ')
 
tuple _241_FIELDS
 
tuple _314_FIELDS
 
tuple _314_MARKERS
 
tuple _345_FIELDS
 
tuple _345_MARKERS
 
tuple _426_FIELDS
 
tuple _426_MARKERS
 
tuple _566_FIELDS
 
tuple _566_MARKERS = ('Description-Content-Type',)
 
tuple _643_MARKERS = ('Dynamic', 'License-File')
 
tuple _643_FIELDS = _566_FIELDS + _643_MARKERS
 
 _ALL_FIELDS = set()
 
 EXTRA_RE = re.compile()
 
dict _ATTR2FIELD
 
dict _FIELD2ATTR = {field: attr for attr, field in _ATTR2FIELD.items()}
 
tuple _PREDICATE_FIELDS = ('Requires-Dist', 'Obsoletes-Dist', 'Provides-Dist')
 
tuple _VERSIONS_FIELDS = ('Requires-Python',)
 
tuple _VERSION_FIELDS = ('Version',)
 
tuple _LISTFIELDS
 
tuple _LISTTUPLEFIELDS = ('Project-URL',)
 
tuple _ELEMENTSFIELD = ('Keywords',)
 
tuple _UNICODEFIELDS = ('Author', 'Maintainer', 'Summary', 'Description')
 
 _MISSING = object()
 
 _FILESAFE = re.compile('[^A-Za-z0-9.]+')
 
str METADATA_FILENAME = 'pydist.json'
 
str WHEEL_METADATA_FILENAME = 'metadata.json'
 
str LEGACY_METADATA_FILENAME = 'METADATA'
 

Detailed Description

Implementation of the Metadata for Python packages PEPs.

Supports all metadata formats (1.0, 1.1, 1.2, 1.3/2.1 and 2.2).

Function Documentation

◆ _best_version()

pip._vendor.distlib.metadata._best_version (   fields)
protected
Detect the best version depending on the fields used.

◆ _get_name_and_version()

pip._vendor.distlib.metadata._get_name_and_version (   name,
  version,
  for_filename = False 
)
protected
Return the distribution name with version.

If for_filename is true, return a filename-escaped form.

Variable Documentation

◆ _241_FIELDS

tuple pip._vendor.distlib.metadata._241_FIELDS
protected
Initial value:
1= ('Metadata-Version', 'Name', 'Version', 'Platform',
2 'Summary', 'Description',
3 'Keywords', 'Home-page', 'Author', 'Author-email',
4 'License')

◆ _314_FIELDS

tuple pip._vendor.distlib.metadata._314_FIELDS
protected
Initial value:
1= ('Metadata-Version', 'Name', 'Version', 'Platform',
2 'Supported-Platform', 'Summary', 'Description',
3 'Keywords', 'Home-page', 'Author', 'Author-email',
4 'License', 'Classifier', 'Download-URL', 'Obsoletes',
5 'Provides', 'Requires')

◆ _314_MARKERS

tuple pip._vendor.distlib.metadata._314_MARKERS
protected
Initial value:
1= ('Obsoletes', 'Provides', 'Requires', 'Classifier',
2 'Download-URL')

◆ _345_FIELDS

tuple pip._vendor.distlib.metadata._345_FIELDS
protected
Initial value:
1= ('Metadata-Version', 'Name', 'Version', 'Platform',
2 'Supported-Platform', 'Summary', 'Description',
3 'Keywords', 'Home-page', 'Author', 'Author-email',
4 'Maintainer', 'Maintainer-email', 'License',
5 'Classifier', 'Download-URL', 'Obsoletes-Dist',
6 'Project-URL', 'Provides-Dist', 'Requires-Dist',
7 'Requires-Python', 'Requires-External')

◆ _345_MARKERS

tuple pip._vendor.distlib.metadata._345_MARKERS
protected
Initial value:
1= ('Provides-Dist', 'Requires-Dist', 'Requires-Python',
2 'Obsoletes-Dist', 'Requires-External', 'Maintainer',
3 'Maintainer-email', 'Project-URL')

◆ _426_FIELDS

tuple pip._vendor.distlib.metadata._426_FIELDS
protected
Initial value:
1= ('Metadata-Version', 'Name', 'Version', 'Platform',
2 'Supported-Platform', 'Summary', 'Description',
3 'Keywords', 'Home-page', 'Author', 'Author-email',
4 'Maintainer', 'Maintainer-email', 'License',
5 'Classifier', 'Download-URL', 'Obsoletes-Dist',
6 'Project-URL', 'Provides-Dist', 'Requires-Dist',
7 'Requires-Python', 'Requires-External', 'Private-Version',
8 'Obsoleted-By', 'Setup-Requires-Dist', 'Extension',
9 'Provides-Extra')

◆ _426_MARKERS

tuple pip._vendor.distlib.metadata._426_MARKERS
protected
Initial value:
1= ('Private-Version', 'Provides-Extra', 'Obsoleted-By',
2 'Setup-Requires-Dist', 'Extension')

◆ _566_FIELDS

tuple pip._vendor.distlib.metadata._566_FIELDS
protected
Initial value:
1= _426_FIELDS + ('Description-Content-Type',
2 'Requires', 'Provides', 'Obsoletes')

◆ _ATTR2FIELD

dict pip._vendor.distlib.metadata._ATTR2FIELD
protected
Initial value:
1= {
2 name.lower().replace("-", "_"): name for name in _ALL_FIELDS
3}

◆ _LISTFIELDS

tuple pip._vendor.distlib.metadata._LISTFIELDS
protected
Initial value:
1= ('Platform', 'Classifier', 'Obsoletes',
2 'Requires', 'Provides', 'Obsoletes-Dist',
3 'Provides-Dist', 'Requires-Dist', 'Requires-External',
4 'Project-URL', 'Supported-Platform', 'Setup-Requires-Dist',
5 'Provides-Extra', 'Extension', 'License-File')