fix handling of empty speeches
This commit is contained in:
parent
384bd83b20
commit
93310a8030
1 changed files with 3 additions and 3 deletions
|
|
@ -133,9 +133,9 @@ def main():
|
|||
if args.debug:
|
||||
links = links[:5]
|
||||
names = names[:5]
|
||||
sleep_for = 1
|
||||
sleep_for = 0
|
||||
else:
|
||||
sleep_for = 5
|
||||
sleep_for = 10
|
||||
|
||||
bios = [get_bio(link, name, sleep_for) for link, name in zip(links, names)]
|
||||
|
||||
|
|
@ -252,7 +252,7 @@ def get_functions(elem):
|
|||
|
||||
def parse_speech(page):
|
||||
if not page:
|
||||
return (None, None)
|
||||
return None
|
||||
soup = BeautifulSoup(page.content)
|
||||
infos = [s.text.strip() for s in soup.find_all(class_="m-biography__speechTitle")]
|
||||
titles = [
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue