'Load the document metadata.'

def load_prereq_metadata(self, storage, data):

    assert self.normalized_path
    meta = storage.get_document_metadata(self.locale, self.slug)
    if (meta is None):
        data[u'needs'].append((u'document_meta', self.normalized_path, self.current_options()))
    elif (u'error' in meta):
        raise self.SourceError(u'Error    getting    metadata    for    %s', self.normalized_path)
    elif meta:
        data[u'id'] = meta[u'id']
        data[u'locale'] = meta[u'locale']
        data[u'modified'] = dateutil.parser.parse(meta[u'modified'])
        data[u'slug'] = meta[u'slug']
        data[u'tags'] = meta[u'tags']
        data[u'title'] = meta[u'title']
        data[u'translations'] = meta[u'translations']
        if (u'uuid' in meta):
            data[u'uuid'] = meta[u'uuid']
        else:
            logger.warning(u'No    uuid:    %s', self.path)
