selenium

Selenium WebDriver Python reload html without refreshing the page

喜你入骨 提交于 2021-01-27 11:38:57
问题 I have a page with self-refreshing content (via WebSocket) like this one. While the content is constantly changing my firefox webdriver can only see the initial content. I could get the fresh one by refreshing the page by driver.navigate.refresh() but this causes unnecessary traffic besides in the Firefox window the new content already appear. My question is: Can I get the fresh html as I can observe in the Firefox window without reloading the whole page? 回答1: If the page contents change over

Selenium WebDriver Python reload html without refreshing the page

霸气de小男生 提交于 2021-01-27 11:38:52
问题 I have a page with self-refreshing content (via WebSocket) like this one. While the content is constantly changing my firefox webdriver can only see the initial content. I could get the fresh one by refreshing the page by driver.navigate.refresh() but this causes unnecessary traffic besides in the Firefox window the new content already appear. My question is: Can I get the fresh html as I can observe in the Firefox window without reloading the whole page? 回答1: If the page contents change over

RSelenium: Can't see Browser as I run my Code

我的梦境 提交于 2021-01-27 11:25:36
问题 MacOS Sierra 10.12.4. Chrome 63 (most recent). R 1.1.383. I'm using RSelenium to scrape web data. I'm able to pull data using the remote driver, but the actual web page browser doesn't pop up for me to view. This makes it difficult to debug some of my trickier web pulls. This is an example video of what I want to happen. The user can visually see the changes he's making in the browser- The goal of this post is to find out why I cannot visually see the browser as I run the code. Here's an

RSelenium: Can't see Browser as I run my Code

老子叫甜甜 提交于 2021-01-27 11:25:26
问题 MacOS Sierra 10.12.4. Chrome 63 (most recent). R 1.1.383. I'm using RSelenium to scrape web data. I'm able to pull data using the remote driver, but the actual web page browser doesn't pop up for me to view. This makes it difficult to debug some of my trickier web pulls. This is an example video of what I want to happen. The user can visually see the changes he's making in the browser- The goal of this post is to find out why I cannot visually see the browser as I run the code. Here's an

using a proxy with phantomjs in selenium webdriver

笑着哭i 提交于 2021-01-27 10:49:44
问题 I'm trying to configure a proxy with PhantomJS 1.9.1 in a ruby (1.8.7) script for selenium webdriver (2.25). I saw a few examples with Firefox, and I successfully did it with this browser. I used this code : profile = Selenium::WebDriver::Firefox::Profile.new profile.proxy = Selenium::WebDriver::Proxy.new :ssl => 'chronos.landebitel.local:3128' $browser = Watir::Browser.new :firefox, :profile => profile But I can't find any examples for phantomjs. I searched and tried many solutions, but none

using a proxy with phantomjs in selenium webdriver

China☆狼群 提交于 2021-01-27 10:48:24
问题 I'm trying to configure a proxy with PhantomJS 1.9.1 in a ruby (1.8.7) script for selenium webdriver (2.25). I saw a few examples with Firefox, and I successfully did it with this browser. I used this code : profile = Selenium::WebDriver::Firefox::Profile.new profile.proxy = Selenium::WebDriver::Proxy.new :ssl => 'chronos.landebitel.local:3128' $browser = Watir::Browser.new :firefox, :profile => profile But I can't find any examples for phantomjs. I searched and tried many solutions, but none

System.InvalidOperationException : Unable to create new service: ChromeDriverService with ChromeDriver and SeleniumGrid on local machine

泄露秘密 提交于 2021-01-27 08:54:19
问题 I had set up Selenium Grid (Both Hub and Node) on my local machine which runs on Windows 10 using below command for registering Hub. java -jar selenium-server-standalone-3.141.59.jar -role hub and for registering a Node, I had used below command java -jar selenium-server-standalone-3.141.59.jar -role node -hub http://10.37.34.2:4444/grid/register -port 5454 On Command Prompt, it displayed that "The node is registered to the hub and ready to use" Verified Grid Console as well at http:/

System.InvalidOperationException : Unable to create new service: ChromeDriverService with ChromeDriver and SeleniumGrid on local machine

我的梦境 提交于 2021-01-27 08:53:02
问题 I had set up Selenium Grid (Both Hub and Node) on my local machine which runs on Windows 10 using below command for registering Hub. java -jar selenium-server-standalone-3.141.59.jar -role hub and for registering a Node, I had used below command java -jar selenium-server-standalone-3.141.59.jar -role node -hub http://10.37.34.2:4444/grid/register -port 5454 On Command Prompt, it displayed that "The node is registered to the hub and ready to use" Verified Grid Console as well at http:/

How to pass a headless option for my driver using Java and Selenium?

守給你的承諾、 提交于 2021-01-27 08:02:58
问题 I am setting up a chrome driver with the help of Selenium and Java. I want this driver to be executed headless but I can't find out the way. Can you explain to me what do I need to do? My code sample: System.setProperty(CHROME_PROPERTY, LINUX_CHROMEDRIVER_PATH); driver = new ChromeDriver(); driver.manage().window().maximize(); driver.manage().timeouts().implicitlyWait(DEFAULT_IMPLICITY_TIME, TimeUnit.SECONDS); 回答1: System.setProperty(CHROME_PROPERTY, LINUX_CHROMEDRIVER_PATH); // OS and

Proxy authentication popup in Selenium

蓝咒 提交于 2021-01-27 07:41:03
问题 I am working on a project where I need to use a proxy. I am using the Chrome browser and when I run my script it forces me to enter the username and password of the proxy. I have tried passing the username and password with the URL itself, but it is not working. Here is the code: Proxy p = new Proxy(); p.setHttpProxy("in-pr.oxylabs.io:20000"); p.setSslProxy("in-pr.oxylabs.io:20000"); System.setProperty("webdriver.chrome.driver","D:\\Love_Testing\\Senium_Naveen\\chrome Driver\\chromedriver