Skip to content
This repository has been archived by the owner on Apr 2, 2021. It is now read-only.

Using ip:port:username:password proxy for your Chromedriver for Selenium and Helium.

Notifications You must be signed in to change notification settings

ibadus/Helium-Selenium-proxy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Helium-Selenium-proxy

Using ip:port:username:password proxy for your Chromedriver for Selenium and Helium.

Installation

  • Download Selenium and Helium
pip install selenium helium

Usage

Get the proxies from the proxies.txt

# VAR FOR THE PROXY PARTS
proxies = []
ip = []
port = []
username = []
psw = []

# PATH TO THE PROXIES.TXT FILE
THIS_FOLDER = os.path.dirname(os.path.abspath(__file__))
proxies_file = os.path.join(THIS_FOLDER, 'proxies.txt')
#OPEN THE PROXIES.TXT AND READ LINE BY LINE TO GET THE INFOS
file = open(str(proxies_file), "r")
for line in file:
    prox = line.rstrip("\n")
    prox = prox.split(":")
    ip.append(prox[0])
    port.append(prox[1])
    username.append(prox[2])
    psw.append(prox[3])
    proxies.append(line.rstrip("\n"))
file.close()

start the browser

# LOAD PROXY
proxy_1 = CPS(ip[0],port[0],username[0],psw[0])
# START SELENIUM BROWSER WITH PROXY
driver = proxy_1.set_proxy()
# CHANGE SELENIUM TO HELIUM 
set_driver(driver)

For more informations about chrome_proxy_driver_setup (CPS) please visit this repo

Thanks

Thanks to nkpydev for Chrome-Webdriver-Proxy

About

Using ip:port:username:password proxy for your Chromedriver for Selenium and Helium.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages