selenium-chromedriver

How to resolve “chromedriver executable needs to be in PATH” error when running Selenium Chrome using virtualenv within PyDev?

↘锁芯ラ 提交于 2019-12-10 02:00:44
问题 Short: Having read Controlling the Browser with the selenium Module at https://automatetheboringstuff.com/chapter11, I am trying to run the Selenium Chrome driver in a virtual environment from PyDev. I have managed to do it from outside PyDev, but from within, I get: selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH. Long: I'm using Linux Debian 3.10.11-1. Following https://www.dabapps.com/blog/introduction-to-pip-and-virtualenv-python/,

Selenium chrome driver socks proxy configuration

一个人想着一个人 提交于 2019-12-10 00:48:21
问题 I am having troubles in setting socks proxy for chrome driver Proxy proxy = new Proxy(); proxy.setProxyType(Proxy.ProxyType.MANUAL); proxy.setAutodetect(false); proxy.setSocksProxy(ProxyHelper.PROXY_HOST + ":" + ProxyHelper.PROXY_PORT); DesiredCapabilities capabilities = DesiredCapabilities.chrome(); capabilities.setCapability(CapabilityType.PROXY, proxy); WebDriver chromeDriver = new ChromeDriver(capabilities); This configuration gives: Exception in thread "main" org.openqa.selenium

Python Selenium Chrome Disable Pop Up Blocker

﹥>﹥吖頭↗ 提交于 2019-12-09 23:43:38
问题 For some reason I can not figure out how to disable the pop up blocker (to allow pop up windows to work). This use to work, so I am guessing it has something to do with the new version of Chrome/Chromedriver? Below is some sample code, that I know use to work, but now when a pop up happens, I do not even see the icon in the top right, where you can allow the pop up or not. I did also try using the prefs found here to disable the pop up blocker, but that did not work ether. If anyone has a

chrome modify headers in selenium java, i am able to add extension .crx through script

泄露秘密 提交于 2019-12-09 23:27:26
问题 I am able to add extension(.crx ) through selenium web driver ChromeOptions options = new ChromeOptions(); options.addExtensions(new File("src/main/resources/idgpnmonknjnojddfkpgkljpfnnfcklj.crx")); But unable to add name and value through selenium java. can anyone help me on this? 回答1: Chrome stores the settings of an extension in the localstorage. So one way to customize your extension is to first set the context on it and then edit the localstorage with a piece of Javascript. Here is an

Unexpected Alert Open Error. “browser.switchTo().alert().accept();” works fine in firefox but not in Chrome when running through Jenkins

巧了我就是萌 提交于 2019-12-09 18:36:04
问题 How to handle this error in chrome browser using protractor. Chrome driver through's following error: UnexpectedAlertOpenError: unexpected alert open: {Alert text : There are unsaved data, please save before you leave, otherwise your changes get lost!} I have used "browser.switchTo().alert().accept();" but this is not working, works fine in firefox. Please help me, help is greatly appreciated. 回答1: today, after struggling with this new problem for the past week or so, we found that the

Chome 61, ChromeDriver 2.32 Click on element for mobile device emulators throws WebDriverException: unknown error: Element is not clickable at point

不羁的心 提交于 2019-12-09 18:11:10
问题 I have tests that were perfectly working in Chrome 60 and ChromeDriver 2.31, but after Chrome updated to 61 version I had to update ChromeDriver to 2.32. And now I am getting sporadic org.openqa.selenium.WebDriverException: unknown error: Element is not clickable at point (X, Y) - in all tests that are run for mobile device emulators such as "iPhone 6 Plus" browser mode, for example. As a workaround I would probably use scroll to element before the click, but it's just a quick fix and it's

Selecting Element followed by text with Selenium WebDriver

我们两清 提交于 2019-12-09 18:10:16
问题 I am using Selenium WebDriver and the Python bindings to automate some monotonous WordPress tasks, and it has been pretty straightforward up until this point. I am trying to select a checkbox, but the only way that I can identify it is by the text following it. Here is the relevant portion of HTML: <li id="product_cat-52"> <label class="selectit"> <input value="52" type="checkbox" name="tax_input[product_cat][]" id="in-product_cat-52"> polishpottery </label> </li> The only information that I

Selenium error - Cannot navigate to invalid URL

眉间皱痕 提交于 2019-12-09 14:47:32
问题 I get the following error : unknown error: unhandled inspector error: {"code":-32603,"message":"Cannot navigate to invalid URL"} (Session info: chrome=29.0.1547.57) (Driver info: chromedriver=2.2,platform=Windows NT 6.1 SP1 x86_64) I think its got to do with chrome browser last updated version (29) about two days ago. * Note: *my chromedriver is up to date (2.2). please let me know what should i do to fix it. 回答1: I received the same error while using Selenium on python. Prepending the

IllegalAccessError thrown by new ChromeDriver() on OSX (Java)

≯℡__Kan透↙ 提交于 2019-12-09 14:10:33
问题 Getting this under Eclipse straight out of the gate. Code: System.setProperty("webdriver.chrome.driver" , "/path/to/selenium/chromedriver"); WebDriver driver = new ChromeDriver(); Throws Exception: Exception in thread "main" java.lang.IllegalAccessError: tried to access method com.google.common.util.concurrent.SimpleTimeLimiter.<init>(Ljava/util/concurrent/ExecutorService;)V from class org.openqa.selenium.net.UrlChecker at org.openqa.selenium.net.UrlChecker.<init>(UrlChecker.java:67) at org

how to set proxy with authentication in selenium chromedriver python?

99封情书 提交于 2019-12-09 13:53:14
问题 I am creating a script that crawls one website to gather some data but the problem is that they blocked me after too many requests but using a proxy I can send more request then currently I do. I have integrated proxy with chrome option --proxy-server options.add_argument('--proxy-server={}'.format('http://ip:port')) but I am using a paid proxy so it requires authentication and as below screenshot it gives the alert box for username and password Then I tried to use it with username and