Fix source avsox

This commit is contained in:
yoshiko2
2021-06-04 01:27:02 +08:00
parent 191c1f99ed
commit 88cef56870

View File

@@ -96,7 +96,7 @@ def main(number):
a = get_html(site + '/cn/search/' + number.replace('_', '')) a = get_html(site + '/cn/search/' + number.replace('_', ''))
html = etree.fromstring(a, etree.HTMLParser()) # //table/tr[1]/td[1]/text() html = etree.fromstring(a, etree.HTMLParser()) # //table/tr[1]/td[1]/text()
result1 = str(html.xpath('//*[@id="waterfall"]/div/a/@href')).strip(" ['']") result1 = str(html.xpath('//*[@id="waterfall"]/div/a/@href')).strip(" ['']")
web = get_html(result1) web = get_html("https:" + result1)
soup = BeautifulSoup(web, 'lxml') soup = BeautifulSoup(web, 'lxml')
info = str(soup.find(attrs={'class': 'row movie'})) info = str(soup.find(attrs={'class': 'row movie'}))
try: try:
@@ -116,7 +116,7 @@ def main(number):
'label': getLabel(info), 'label': getLabel(info),
'year': getYear(getRelease(info)), # str(re.search('\d{4}',getRelease(a)).group()), 'year': getYear(getRelease(info)), # str(re.search('\d{4}',getRelease(a)).group()),
'actor_photo': getActorPhoto(web), 'actor_photo': getActorPhoto(web),
'website': result1, 'website': "https:" + result1,
'source': 'avsox.py', 'source': 'avsox.py',
'series': getSeries(info), 'series': getSeries(info),
} }