mirror of
https://github.com/SpiceBot/SpiceBot.git
synced 2026-11-10 21:50:59 -05:00
test
This commit is contained in:
parent
f23df8a747
commit
aaf74c418c
@ -53,13 +53,10 @@ def fetch_result(query):
|
||||
|
||||
tree = html.fromstring(r.content)
|
||||
|
||||
title = tree.xpath((basic_xpath))
|
||||
return str(title)
|
||||
|
||||
try:
|
||||
title = tree.xpath((basic_xpath))
|
||||
# if isinstance(title, list):
|
||||
# title = title[0]
|
||||
if isinstance(title, list):
|
||||
title = title[0]
|
||||
# title = str(title)
|
||||
# for r in (("u'", ""), ("['", ""), ("[", ""), ("']", ""), ("\\n", ""), ("\\t", "")):
|
||||
# title = title.replace(*r)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user