Python selenium webdriver “Session not created” exception when opening Chrome

前端 未结 3 920
Happy的楠姐
Happy的楠姐 2020-12-10 06:06

Here\'s my code for opening Chrome:

from selenium import webdriver 
driver=webdriver.Chrome(\'C:\\\\Users\\\\Im         


        
相关标签:
3条回答
  • 2020-12-10 06:34

    Update your chromedriver to 2.24 version from the given url:

    http://chromedriver.storage.googleapis.com/index.html?path=2.24/

    That worked for me.

    0 讨论(0)
  • 2020-12-10 06:41

    Setting LANG=en_US.UTF-8 before executing my script works for me. See this: https://bugs.chromium.org/p/chromedriver/issues/detail?id=1552#c43

    In Python:

    import os
    os.environ["LANG"] = "en_US.UTF-8"
    
    0 讨论(0)
  • 2020-12-10 07:01

    To install the chromedriver on windows, download and unzip the chromedriver_win32.zip and add the path to the folder containing the chromedriver.exe in the environment variables setting [System properties - Advanced system settings - Environment variables].

    0 讨论(0)
提交回复
热议问题