|
|
@@ -83,7 +83,6 @@ def get_meta_data(this_data, this_venue):
|
|
|
:param this_venue:
|
|
|
:return:
|
|
|
"""
|
|
|
- global print_it
|
|
|
this_soup = BeautifulSoup(this_data, 'html.parser')
|
|
|
early = this_soup.select('div.large')
|
|
|
# if early:
|
|
|
@@ -153,6 +152,7 @@ def scrape_scratchings(div, this_venue):
|
|
|
print('The start of the offending line is: {}'.format(text[0:10]))
|
|
|
continue
|
|
|
text = re.sub(r'e\s+', ' ', text)
|
|
|
+ text = re.sub(r'\s+', ' ', text) # Kills tabs between number and name of horse
|
|
|
temp_list = Scratching(this_venue.name, this_venue.state, this_venue.date, race, text)
|
|
|
scraped_scratchings.append(temp_list)
|
|
|
return scraped_scratchings
|