Open jjqi92 opened 3 weeks ago
@jjqi92, thank you for creating this issue. We will troubleshoot it as soon as we can.
Triage this issue by using labels.
If information is missing, add a helpful comment and then I-issue-template
label.
If the issue is a question, add the I-question
label.
If the issue is valid but there is no time to troubleshoot it, consider adding the help wanted
label.
If the issue requires changes or fixes from an external project (e.g., ChromeDriver, GeckoDriver, MSEdgeDriver, W3C),
add the applicable G-*
label, and it will provide the correct link and auto-close the
issue.
After troubleshooting the issue, please add the R-awaiting answer
label.
Thank you!
14:20:05.060 WARN [SeleniumManager.lambda$runCommand$1] - Exception managing chrome: error sending request for url (https://googlechromelabs.github.io/chrome-for-testing/known-good-versions-with-downloads.json) 14:20:05.962 INFO [LocalNode.newSession] - Session created by the Node. Id: 8489e07ec24f11223e4bad9514b5257e, Caps: Capabilities {acceptInsecureCerts: false, browserName: chrome-headless-shell, browserVersion: 124.0.6367.118, chrome: {chromedriverVersion: 124.0.6367.78 (a087f2dd364d..., userDataDir: /tmp/.org.chromium.Chromium...}, fedcm:accounts: true, goog:chromeOptions: {debuggerAddress: localhost:42389}, networkConnectionEnabled: false, pageLoadStrategy: normal, platformName: linux, proxy: Proxy(), se:bidiEnabled: false, se:cdp: ws://10.119.101.54:4444/ses..., se:cdpVersion: 124.0.6367.118, setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: dismiss and notify, webauthn:extension:credBlob: true, webauthn:extension:largeBlob: true, webauthn:extension:minPinLength: true, webauthn:extension:prf: true, webauthn:virtualAuthenticators: true}
Is it running without using a proxy? Can you please try that? Then it might be the proxy that prevents the request from going through, hence the timeout.
ChromeOptions options = new ChromeOptions();
options.addArguments("--headless");
options.addArguments("--no-sandbox");
options.addArguments("--disable-dev-shm-usage");
ProxyConfig proxyConfig = new ProxyConfig();
options.setAcceptInsecureCerts(false);
options.setEnableDownloads(false);
options.setProxy(new Proxy().setHttpProxy(String.format("http://%s:%s", proxyConfig.getValueByKey("PROXY_HOST"), proxyConfig.getValueByKey("PROXY_PORT"))));
WebDriver driver = new RemoteWebDriver(new URL("http://10.119.101.54:4444/wd/hub"), options);
After changing the proxy to the above method, RemoteWebDriver successfully initialized the driver, but an error occurred in driver.get("https://www.baidu.com") timeout: Timed out receiving message from renderer: -0.012 (Session info: chrome-headless-shell=124.0.6367.118)
Can you help me find out what's causing this?
Thank you for trying it out. Can you try "options.addArguments("--headless=new");
" and see if that helps? To understand how it is better read here https://developer.chrome.com/docs/chromium/new-headless.
I later tried selenium-server-4.5.3.jar to configure the environment, but still couldn't open the url. Finally, after changing to selenium-server-standalone-3.141.59.jar, the problem was solved.
i will try "options.addArguments("--headless=new");" later. thank you.
Using selenium-server-standalone-3.141.59.jar
is not really a solution as that a version not maintained anymore.
Yes, I also hope to use selenium grid4, and my Java service also uses selenium4, but when I build a distributed cluster, I can't open the url in the browser. I also tried selenium server 4.23.0, 4.17. 0, 4.5.3 and other versions failed to solve the problem until I changed to 3.141.59.
What happened?
when create session via remoteWebDriver(), it throws an exception: Unable to create session: Could not start a new session. java.util.concurrent.TimeoutException
How can we reproduce the issue?
Relevant log output
Operating System
ubuntu
Selenium version
java 4.23.0
What are the browser(s) and version(s) where you see this issue?
chrome 124
What are the browser driver(s) and version(s) where you see this issue?
chromedriver 124
Are you using Selenium Grid?
hub: 4.17.0 node:4.23.0