I'm tring to do a code to send messages to a list of people in whatsapp to a list of people with selenium and chromedriver, but im getting this error:
C:\Users\Crist\Desktop\Whattsapp mama>prueba.py
Traceback (most recent call last):
File "C:\Users\Crist\Desktop\Whattsapp mama\prueba.py", line 10, in <module>
driver = webdriver.Chrome(r"C:\Users\Crist\Downloads\chromedriver\chromedriver.exe")
File "C:\Users\Crist\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\chrome\webdriver.py", line 76, in __init__
RemoteWebDriver.__init__(
File "C:\Users\Crist\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 157, in __init__
self.start_session(capabilities, browser_profile)
File "C:\Users\Crist\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 252, in start_session
response = self.execute(Command.NEW_SESSION, parameters)
File "C:\Users\Crist\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 321, in execute
self.error_handler.check_response(response)
File "C:\Users\Crist\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\remote\errorhandler.py", line 242, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: unknown error: cannot find Chrome binary
(Driver info: chromedriver=2.25.426923 (0390b88869384d6eb0d5d09729679f934aab9eed),platform=Windows NT 10.0.19042 x86_64)
This is the code:
from selenium import webdriver
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support.ui import Select
from selenium.webdriver.common.by import By
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.chrome.options import Options
import time
contact = ["cristobal de toro", "cristobal", "gonzalo molina"]
text = "Hey, this message was sent using Selenium"
driver = webdriver.Chrome(r"C:\Users\Crist\Downloads\chromedriver\chromedriver.exe")
driver.get("https://web.whatsapp.com")