modify scripts
This commit is contained in:
@ -95,6 +95,9 @@ def fetch_movies_common(tbl):
|
||||
url = row['href']
|
||||
row_id = row['id']
|
||||
uncensored = row['uncensored'] if row['uncensored'] > 0 else None
|
||||
# 增加一个判断:只有当url中包含uncensored时,才算无码
|
||||
uncensored = 1 if 'uncensored' in url.lower() else 0
|
||||
|
||||
if not utils.is_valid_url(url):
|
||||
logging.info(f'invalid url ({url}) in {tbl}, row id: {row_id}. skipping...')
|
||||
continue
|
||||
@ -224,7 +227,7 @@ def update_multilang_tags():
|
||||
langs_url = utils.generate_multilang_urls(url)
|
||||
for lang, next_url in langs_url.items():
|
||||
while next_url:
|
||||
logging.info(f"Fetching data for url {next_url} ..., raw url: {url}")
|
||||
logging.info(f"Fetching data for url {next_url} ...")
|
||||
soup, status_code = scraper.fetch_page(next_url, partial(scraper.generic_validator, tag="div", identifier="waterfall", attr_type="id"))
|
||||
if soup:
|
||||
list_data, next_url = scraper.parse_studios_labels_series_detail(soup, next_url)
|
||||
|
||||
Reference in New Issue
Block a user