kaliiiiiiiiii / Selenium-Driverless

undetected Selenium without usage of chromedriver
https://kaliiiiiiiiii.github.io/Selenium-Driverless/
Other
487 stars 61 forks source link

improve racing conditions #129

Closed kaliiiiiiiiii closed 8 months ago

kaliiiiiiiiii commented 8 months ago

should recolve https://github.com/kaliiiiiiiiii/Selenium-Driverless/issues/127

poplu2525 commented 8 months ago

It still gives an error, I was trying to attach proxies but as soon as the browser is launched it gives

TimeoutError: User not connected

def load_broswer():
    proxy_selected=random.choice(proxies_list)
    #print('proxy_selected-- ',proxy_selected)
    #options = uc.ChromeOptions()
    profile = profiles.Windows() # or .Android()
    profile["proxy"] = {
      "proxy":"http://"+proxy_selected
      }
    options = ChromeOptions()
    #user_data_dir = 'D:/profiles'
    #options.add_argument("--user-data-dir=" + user_data_dir) # no effect
    driver = Chrome(profile=profile, options=options, driverless_options=True)
    driver.get("https://shop.winndixie.com/shop") # this should pass cloudflare captchas now
    time.sleep(8)
    return driver
kaliiiiiiiiii commented 8 months ago

It still gives an error, I was trying to attach proxies but as soon as the browser is launched it gives

TimeoutError: User not connected

def load_broswer():
    proxy_selected=random.choice(proxies_list)
    #print('proxy_selected-- ',proxy_selected)
    #options = uc.ChromeOptions()
    profile = profiles.Windows() # or .Android()
    profile["proxy"] = {
      "proxy":"http://"+proxy_selected
      }
    options = ChromeOptions()
    #user_data_dir = 'D:/profiles'
    #options.add_argument("--user-data-dir=" + user_data_dir) # no effect
    driver = Chrome(profile=profile, options=options, driverless_options=True)
    driver.get("https://shop.winndixie.com/shop") # this should pass cloudflare captchas now
    time.sleep(8)
    return driver

please provide the imports as well