예제 #1
0
def scrape_description(url, shortmem=None):
    try:
        details = shortmem['base_etree'].xpath(
            "//span[@id='video-description']")[0]
        return util.clean_description_html(util.lxml_inner_html(details))
    except IndexError:
        raise errors.FieldNotFound('Could not find the description field')
예제 #2
0
def scrape_description(url, shortmem=None):
    try:
        details = shortmem['base_etree'].xpath(
            "//span[@id='video-description']")[0]
        return util.clean_description_html(util.lxml_inner_html(details))
    except IndexError:
        raise errors.FieldNotFound('Could not find the description field')
예제 #3
0
파일: wistia.py 프로젝트: itsbenweeks/Amara
def scrape_description(url, shortmem={}):
    try:
        description = shortmem['oembed'][
            'title']  # No desc provided in oembed. Use title.
    except KeyError:
        description = ''
    return util.clean_description_html(description)
예제 #4
0
def scrape_description(url, shortmem={}):
    if 'summary' in shortmem['feed_item']:
        description = shortmem['feed_item'].summary
    else:
        description = _fp_get(shortmem, 'puredescription')

    if description:
        return util.clean_description_html(description)
    else:
        return u''
예제 #5
0
파일: blip.py 프로젝트: crodjer/mirosubs
def scrape_description(url, shortmem={}):
    if 'summary' in shortmem['feed_item']:
        description = shortmem['feed_item'].summary
    else:
        description = _fp_get(shortmem, 'puredescription')

    if description:
        return util.clean_description_html(description)
    else:
        return u''
예제 #6
0
파일: vimeo.py 프로젝트: brettle/mirosubs
def scrape_description(url, shortmem={}):
    try:
        description = shortmem["api_data"]["description"]
    except KeyError:
        description = ""
    return util.clean_description_html(description)
예제 #7
0
파일: vimeo.py 프로젝트: rhemmanur/mirosubs
def scrape_description(url, shortmem={}):
    return util.clean_description_html(shortmem['api_data']['description'])
예제 #8
0
def scrape_description(url, shortmem={}):
    try:
        description = shortmem['api_data']['description']
    except KeyError:
        description = ''
    return util.clean_description_html(description)
예제 #9
0
파일: vimeo.py 프로젝트: crodjer/mirosubs
def scrape_description(url, shortmem={}):
    try:
        description = shortmem['api_data']['description']
    except KeyError:
        description = ''
    return util.clean_description_html(description)
예제 #10
0
def scrape_description(url, shortmem=None):
    return util.clean_description_html(shortmem['api_data']['description'])