ZoRestAreaAddress
#Restaurant Rating | |
try: | |
rest_rating_anchor = driver.find_element_by_xpath("""/html/body/div[1]/div[2]/main/div/section[3]/section/section[2]/section/div[1]/p""") | |
rest_rating_text = rest_rating_anchor.text | |
except NoSuchElementException: | |
rest_rating_text = "Not Rated Yet" | |
pass | |
rest_rating.append(rest_rating_text) | |
print(f'Scraping Restaurant Area - {name} - {rest_rating_text} - OK') | |
#Restaurant Review | |
try: | |
rest_review_anchor = driver.find_element_by_xpath("""/html/body/div[1]/div[2]/main/div/section[3]/section/section[2]/section/div[2]/p""") | |
rest_review_text = rest_review_anchor.text | |
except NoSuchElementException: | |
rest_review_text = "Not Reviewed Yet" | |
pass | |
rest_review.append(rest_review_text) | |
print(f'Scraping Restaurant Review Counts - {name} - {rest_review_text} - OK') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment