我面临一些有关Selenium脚本的问题。到目前为止,我使用的是Chrome v73,它会自动升级到v74。现在的问题是,当我试图执行时,代码没有执行。抛到错误下面。有人能建议如何执行吗?
Starting ChromeDriver 73.0.3683.68 (47787ec04b6e38e22703e856e101e840b65afe72) on port 36996
Only local connections are allowed.
Please protect ports used by ChromeDriver and related test frameworks to prev
我已经更新了我的铬,没有考虑到它,因为我是相当新的硒,但这已造成以下的错误,在visual。
An unhandled exception of type 'System.InvalidOperationException' occurred in WebDriver.dll. Additional information: session not created: Chrome version must be between 70 and 73.
我试图更新这些库,但我的所有库都是最新的。这是剂量库和版本。
Selenium.Support 3.141.0
Selenium.
我在Windows10上使用Selenium和Python 3.7.3。
如果我将代码包装在一个类中,浏览器在打开页面后立即终止:
'''
Program to show how to open chrome browser using selenium webdriver
'''
from selenium import webdriver
#import os
class run_chrome_tests(object):
def test_method(self):
# This is the locatio
Result StackTrace:
at OpenQA.Selenium.Remote.RemoteWebDriver.UnpackAndThrowOnError(Response errorResponse)
at OpenQA.Selenium.Remote.RemoteWebDriver.Execute(String driverCommandToExecute, Dictionary`2 parameters)
at OpenQA.Selenium.Remote.RemoteWebDriver.StartSession(ICapabilities desiredCap
从硒面临的问题
回溯(最近一次调用):
File "C:/Users/SONY/PycharmProjects/untitled/bot_test.py", line 3, in <module>
driver = webdriver.Chrome()
File "C:\Users\SONY\Anaconda3\lib\site-packages\selenium\webdriver\chrome\webdriver.py", line 81, in __init__
desired_capabilities=desired_c
错误:
Starting ChromeDriver 2.20.353145 (343b531d31eeb933ec778dbcf7081628a1396067) on port 40734
Only local connections are allowed.
Exception in thread "main" org.openqa.selenium.remote.UnreachableBrowserException: Could not start a new session. Possible causes are invalid address of the remo
很多人试图用回答这个问题,但似乎没有一个解决方案有效,除非我添加--headless选项。
环境详细信息
selenium==3.141.0
Google Chrome 73.0.3683.103
Driver Used -- 73.0.3683.68 -- chromedriver_linux64.zip
OS -- Linux 16.04
Python -- 3.5.2
我面临的错误如下:
selenium.common.exceptions.WebDriverException:消息:未知错误: Chrome启动失败:异常退出
(未知错误: Dev
Exception in thread "main" org.openqa.selenium.WebDriverException: unknown error: unable to discover open page
浏览器正在打开,但所需的网页没有打开&浏览器正在5秒内关闭。在此之后,异常将出现在IDE中。附加浏览器的屏幕截图
尝试卸载(也删除用户数据)&重新安装chrome,但din无法工作:(
使用JDK 8,
selenium 3.6.0 for Java,
chrome浏览器-最新版本,
chrome驱动程序-不确定(可能是2.31)
我的代码
p
我有:
Windows 10 64位
Chrome版本58
节点6.10.1
国家预防机制3.10.10
显色剂2.29.0
Selenium独立运行,但运行我的测试(使用Chrome)后,在运行selenium的控制台中出现了一个错误:
Caused by: org.openqa.selenium.WebDriverException: Timed out waiting for driver server to start.
Build info: version: '3.4.0', revision: 'unknown', ti
当我运行程序时,会显示一些错误消息,程序无法执行,消息:
org.openqa.selenium.sessionNotCreatedExeception:could not start a new session. Response code 500. Message: session not created: This version of ChomeDriver only supports Chrome version 102.
Chromedriver没有点击URL。
测试环境:
chrome=73.0.3683.103
显色剂版本: 73.0.3683.68
java.version:'1.8.0_151‘
os.name: Windows 7
我收到以下错误:
Unable to receive message from renderer
Timed out receiving message from renderer: 19.997 Timed out receiving message from renderer:-0.004
预先感谢您所能提供的任何帮助。
启动时出现的错误,程序上周运行良好,我使用了Spring和Spring,可能是浏览器中的一些升级:
org.openqa.selenium.SessionNotCreatedException: session not created: This version of
ChromeDriver only supports Chrome version 95
Current browser version is 97.0.4692.71
使用pom与spring启动和它的默认值不工作,如何将它刷新到上一个版本?
我的Pom.xml:
<dependency>
<
Sep 13, 2021 1:38:45 PM cucumber.api.cli.Main run
WARNING: You are using deprecated Main class. Please use io.cucumber.core.cli.Main
Scenario: Login with valid credentials # src/test/resources/features/landing.feature:7
SLF4J: Failed to load class "org.slf
基本上,我有一个使用Selenium (Chromedriver)从网站获取数据的java程序。
相同的java程序在windows上运行时没有任何错误,这时我还没有犯任何错误。在CentOS 7中,它可以工作,但会抛出一些错误&这很奇怪。
错误:
Exception in thread "Thread-6" org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Response code 500. M
环境详情:
selenium==3.141.0 Google Chrome 73.0.3683.103 Driver Used -- 73.0.3683.68 -- chromedriver_linux64.zip OS -- Linux 16.04 Python -- 3.5.2
在上面的环境中,我的代码成功运行并获得页面源代码。然而,它并不像自动QA测试那样打开新的web浏览器。
我不确定我是不是漏了什么东西。我也尝试过使用火狐(GeckoDriver)。
from selenium import webdriver
from selenium.webdriver.chrome.optio
我在使用Selenium打开chrome时遇到错误,它会在打开后立即打开和关闭窗口。下面是我的代码:
import requests
import json
from selenium import webdriver
driver = webdriver.Chrome(executable_path=r'C:\Users\Salvatore\Desktop\Desktop\webdrivers\chromedriver.exe')```
This is the error:
```selenium.common.exceptions.SessionNotCreatedExc
我正在开发一个使用selenium的应用程序。
OS: macOS与苹果硅
语言:科特林
JDK: Java 18
但失败了。
输出
Starting ChromeDriver 105.0.5195.19 (b9c217c128c16f53d12f9a02933fcfdec1bf49af-refs/branch-heads/5195@{#176}) on port 50362
Only local connections are allowed.
Please see https://chromedriver.chromium.org/security-considerat
当我尝试在Chrome上运行Selenium测试时,我得到了以下异常。
org.openqa.selenium.WebDriverException: The path to the driver executable must be set by the webdriver.chrome.driver system property; for more information, see https://github.com/SeleniumHQ/selenium/wiki/ChromeDriver. The latest version can be downloaded from http
因此,我已经将我的NUnit Seleniumt测试放到了我们团队的tfs上。我已经将它们配置为构建并运行为Visual测试。我已经将我的VsoAgent配置为交互式的。我的测试开始运行,但在打开Chrome之后,我看到了一种通信,即Chrome自动扩展已经停止工作,我得到了一个错误:
OpenQA.Selenium.WebDriverException : The HTTP request to the remote WebDriver server for URL http://localhost:54836/session timed out after 60 seconds.
----
我面临一个在Visual中运行用C#编写的Selenium测试的问题。
我遇到的问题是,当我在调试模式下从工作室在ChromeDriver上运行测试时,铬窗口总是皱着眉头崩溃。
chromedriver命令窗口在循环中显示以下错误(~20次)。
Starting ChromeDriver 2.24.417431 (9aea000394714d2fbb20850021f6204f2256b9cf) on port 52376
Only local connections are allowed.
[28356:19528:0922/134628:ERROR:child_process_