pcomputo / Whole-Foods-Delivery-Slot

Automated script for Whole Foods and Amazon Fresh delivery slot
Apache License 2.0
443 stars 149 forks source link

'chromedriver' executable needs to be in PATH. #49

Closed LouShuishui closed 4 years ago

LouShuishui commented 4 years ago

I'm running amazon_fresh_delivery_slot_chrome.py on Windows10 and got this error:

File "amazon_fresh_delivery_slot_chrome.py", line 62, in getWFSlot('https://www.amazon.com/gp/buy/shipoptionselect/handlers/display.html?hasWorkingJavascript=1') File "amazon_fresh_delivery_slot_chrome.py", line 16, in getWFSlot driver = webdriver.Chrome() File "/home/XXX/.local/lib/python2.7/site-packages/selenium/webdriver/chrome/webdriver.py", line 73, in init self.service.start() File "/home/XXX/.local/lib/python2.7/site-packages/selenium/webdriver/common/service.py", line 83, in start os.path.basename(self.path), self.start_error_message) selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home

pcomputo commented 4 years ago

You'll have to update the path of the this installed webdriver under: python driver = webdriver.Chrome() if its not the default location your OS needs. Similarly, for FireFox python driver = webdriver.Firefox(executable_path="")

there are instructions for this in the Readme.

LouShuishui commented 4 years ago

Thanks for pointing it! But I still get error after given the path:

Traceback (most recent call last): File "amazon_fresh_delivery_slot_chrome.py", line 62, in getWFSlot('https://www.amazon.com/gp/buy/shipoptionselect/handlers/display.html?hasWorkingJavascript=1') File "amazon_fresh_delivery_slot_chrome.py", line 16, in getWFSlot driver = webdriver.Chrome(executable_path='C:/Users/XXX/Downloads/chromedriver_win32/chromedriver.exe') File "/home/XXX/.local/lib/python2.7/site-packages/selenium/webdriver/chrome/webdriver.py", line 73, in init self.service.start() File "/home/XXX/.local/lib/python2.7/site-packages/selenium/webdriver/common/service.py", line 83, in start os.path.basename(self.path), self.start_error_message) selenium.common.exceptions.WebDriverException: Message: 'chromedriver.exe' executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home