Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

540
Vistas
Selenium Webdriver Import ChromeDriverManager Error

I've been using selenium webdriver; however, I am now attempting to interact with a page using Java (this is new to me). In attempting to do this, I've found this video that appears to be exactly what Im looking for:

https://www.youtube.com/watch?v=bBRFVIEiFIE

I keep getting an error message generated from the second line of the code:

from selenium import webdriver

from webdriver_manager.chrome import ChromeDriverManager

This is the error message:

 Traceback (most recent call last):
 File "C:\Users\erich\Desktop\SeleniumDrivers\State Scrape Java.py", line 2, in <module>
 from webdriver_manager.chrome import ChromeDriverManager
 File "C:\Python27\lib\site-packages\webdriver_manager\chrome.py", line 4, in <module>
 from webdriver_manager.driver import ChromeDriver
 File "C:\Python27\lib\site-packages\webdriver_manager\driver.py", line 77
 self.auth_header = {'Authorization': f'token {self._os_token}'}
                                                             ^
 SyntaxError: invalid syntax

I have made sure to pip install webdriver-manager and have attempted the two possible options on pypi.

Any help will be greatly appreciated!

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

Try:

#selenium4 with python [pip install selenium4)

from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.chrome.service import Service
from webdriver_manager.chrome import ChromeDriverManager

#options to add as arguments
from selenium.webdriver.chrome.options import Options
option = webdriver.ChromeOptions()
option.add_argument("start-maximized")

#chrome to stay open
option.add_experimental_option("detach", True)

driver = webdriver.Chrome(service=Service(ChromeDriverManager().install()),options=option)
driver.get('https://www.example.com/')

WebdriverManager

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda