fix duplicate lines bug #13
@ -19,12 +19,9 @@ def get_df(html_path):
|
||||
for row in trs:
|
||||
# print(type(row))
|
||||
entries = row.find_all("td")
|
||||
for e in entries:
|
||||
# print(e.text.strip())
|
||||
|
||||
entry_str = [e.text.strip() for e in entries]
|
||||
s = dict(zip(cols, entry_str))
|
||||
rows.append(s)
|
||||
entry_str = [e.text.strip() for e in entries]
|
||||
s = dict(zip(cols, entry_str))
|
||||
rows.append(s)
|
||||
df = pd.DataFrame(rows)
|
||||
return df
|
||||
|
||||
|
||||
Reference in New Issue
Block a user