Remove useless error output

This commit is contained in:
yoshiko2
2022-08-26 02:43:50 +08:00
parent 4b9b2675e2
commit 54440de9b1
3 changed files with 8 additions and 6 deletions

View File

@@ -125,8 +125,9 @@ class Scraping():
continue
json_data = json.loads(data)
except Exception as e:
print('[!] 出错啦')
print(e)
# print('[!] 出错啦')
# print(e)
pass
# if any service return a valid return, break
if self.get_data_state(json_data):
print(f"[+]Find movie [{name}] metadata on website '{source}'")
@@ -156,8 +157,9 @@ class Scraping():
continue
json_data = json.loads(data)
except Exception as e:
print('[!] 出错啦')
print(e)
# print('[!] 出错啦')
# print(e)
pass
# json_data = self.func_mapping[source](number, self)
# if any service return a valid return, break
if self.get_data_state(json_data):

View File

@@ -86,7 +86,7 @@ class Javdb(Parser):
try:
resp = self.session.get(javdb_url)
except Exception as e:
print(e)
#print(e)
raise Exception(f'[!] {self.number}: page not fond in javdb')
self.querytree = etree.fromstring(resp.text, etree.HTMLParser())

View File

@@ -162,7 +162,7 @@ class Parser:
}
dic = self.extradict(dic)
except Exception as e:
print(e)
#print(e)
dic = {"title": ""}
js = json.dumps(dic, ensure_ascii=False, sort_keys=True, separators=(',', ':'))
return js