(self)
return dict(map(transform, map(FoldedCase, self)))
Convert PackageMetadata to a JSON-compatible format
        per PEP 0566.
Convert PackageMetadata to a JSON-compatible format
        per PEP 0566.
Convert PackageMetadata to a JSON - compatible format per PEP 0566 .
def json(self):
        """
        Convert PackageMetadata to a JSON-compatible format
        per PEP 0566.
        """

        def transform(key):
            value = self.get_all(key) if key in self.multiple_use_keys else self[key]
            if key == 'Keywords':
                value = re.split(r'\s+', value)
            tk = key.lower().replace('-', '_')
            return tk, value

        return dict(map(transform, map(FoldedCase, self)))
def json ( self ) : def transform ( key ) : value = self . get_all ( key ) if key in self . multiple_use_keys else self [ key ] if key == 'Keywords' : value = re . split ( r'\s+' , value ) tk = key . lower ( ) . replace ( '-' , '_' ) return tk , value return dict ( map ( transform , map ( FoldedCase , self ) ) )