

def get_artifact_metadata(self, remote_artifact):
    "\n        Gets artifact's maven metadata.\n\n        Metadata capability needs to be enabled to use this. Also indexing has to be enabled for that repo to make it\n        work.\n\n        :param remote_artifact:\n        :return:\n        "
    artifact_id = 'urn:maven/artifact#{coordinates}'.format(coordinates=remote_artifact.get_coordinates_string())
    logger.debug('artifact_id: %s', artifact_id)
    artifact_id_encoded = base64.b64encode(artifact_id)
    metadata_raw = self._send_json('service/local/index/custom_metadata/{repo_id}/{artifact_id_encoded}'.format(repo_id=remote_artifact.repo_id, artifact_id_encoded=artifact_id_encoded))
    metadata = {
        
    }
    for d in metadata_raw['data']:
        try:
            metadata[d['key']] = d['value']
        except KeyError:
            raise RepositoryClientError('Malformed artifact metadata. Missing key or value at artifact {atrifact}'.format(artifact=remote_artifact))
    return metadata

dataset/ETHPy150Open stardust85/repositorytools/repositorytools/lib/repository.py NexusProRepositoryClient.get_artifact_metadata/original