Skip to content

Commit

Permalink
add try except for accepting updating terms (#28)
Browse files Browse the repository at this point in the history
  • Loading branch information
isaac-chung authored Sep 29, 2024
1 parent 04562ef commit 837654b
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions give_kudos.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,11 @@ def give_kudos(self):
Interate over web feed entries
"""
## Give Kudos on loaded page ##
try:
self.page.get_by_role("button", name="Accept").click(timeout=5000)
print("Accepting updated terms.")
except:
pass
web_feed_entry_locator = self.page.locator(self.web_feed_entry_pattern)
self.locate_kudos_buttons_and_maybe_give_kudos(web_feed_entry_locator=web_feed_entry_locator)
self.browser.close()
Expand Down

0 comments on commit 837654b

Please sign in to comment.