mark-thompson / whole-foods-deliverance

[Availability notifications, auto-checkout, slot preferences, cart tracking] for Whole Foods / Amazon Fresh
MIT License
54 stars 12 forks source link

nav.py and wait.py through exceptions #13

Closed ghost closed 4 years ago

ghost commented 4 years ago

@mark-thompson here is the traceback. Thanks!

INFO:main:No slots found :( waiting... INFO:main:Checking for available slots INFO:main:Found 1 slots: Tomorrow::11:00 AM - 1:00 PM INFO:notify:Alerting user with message: 'Delivery slots found' ERROR:notify:send_sms() requires a config file at 'conf.toml' with key 'twilio' ERROR:notify:send_telegram() requires a config file at 'conf.toml' with key 'telegram' INFO:main:Attempting to select slot and checkout INFO:main:Selecting slot: Tomorrow::11:00 AM - 1:00 PM INFO:nav:Navigating <Route beginning at 'https://www.amazon.com/gp/buy/shipoptionselect/handlers/display.html' with 3 stops> INFO:nav:Navigating <Waypoint ('xpath', "//*[contains(@class, 'ufss-overview-continue-button')]") -> 'gp/buy/payselect/handlers/display.html'> INFO:nav:Navigated to 'gp/buy/payselect/handlers/display.html' INFO:nav:Navigating <Waypoint ('id', 'continue-top') -> 'gp/buy/spc/handlers/display.html'> WARNING:nav:Current URL 'https://www.amazon.com/gp/buy/shipoptionselect/handlers/display.html' does not match target Handling possible redirect (timeout in 10s) Traceback (most recent call last): File "/Users/aub/Repos/whole-foods-deliverance/nav.py", line 86, in navigate EC.url_contains(waypoint.dest) File "/Users/aub/Repos/whole-foods-deliverance/env/lib/python3.7/site-packages/selenium/webdriver/support/wait.py", line 80, in until raise TimeoutException(message, screen, stacktrace) selenium.common.exceptions.TimeoutException: Message:

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "run.py", line 147, in site_config.Routes.CHECKOUT.navigate(driver) File "/Users/aub/Repos/whole-foods-deliverance/nav.py", line 90, in navigate raise e File "/Users/aub/Repos/whole-foods-deliverance/nav.py", line 68, in navigate self.navigate_waypoint(driver, waypoint, timeout) File "/Users/aub/Repos/whole-foods-deliverance/nav.py", line 54, in navigate_waypoint "Navigation to '{}' failed".format(waypoint.dest) nav.NavigationException: Message: Navigation to 'gp/buy/spc/handlers/display.html' failed

mark-thompson commented 4 years ago

Duplicate of #12

mark-thompson commented 4 years ago

@b3ll0v1c let me know if the updated code is working for you