options.add_argument('--proxy-server=socks5://%s' % PROXY_HOST)
options.add_argument(f'--user-agent={randua}')
# setting profile
options.user_data_dir = "c:\\temp\\profile"
# another way to set profile is the below (which takes precedence if both variants are used
options.add_argument('--user-data-dir=c:\\temp\\profile2')
# just some options passing in to skip annoying popups
options.add_argument('--no-first-run --no-service-autorun --password-store=basic')
#options.add_argument("--headless")
prefs = {"profile.default_content_settings.geolocation": 1}
# Initialize Selenium Web Driver
self.driver = uc.Chrome(enable_cdp_events=True, options=options)
self.driver.get('https://whoer.net')`
Hello, I am very new to python and trying to learn automation.
I tried UC and it seems almost undetectable, my only issue right now is that websites like whoer.net detect the timezone difference
Is there a way to spoof the timezone depending on the proxy location?
I am using bright data proxies for tests
here is the code I have so far
` ``` PROXY_HOST = '127.0.0.1:24000' # rotating proxy or host randua = random.choice(open("useragents.txt").readlines()) self.tries = 5 options = Options()
Use a SOCKS5 proxy