Chrome Driver Server is not able to launch Chrome browser - java

I am using ChromeDriver v2.24 and I have Chrome browser 52 in my system (not installed, executable file).
When I am executing my selenium script, the Chrome Driver is getting executed, but the Chrome browser is not getting launched. Because of that, I am getting
NoSuchSessionException: no such session
Console:
Starting ChromeDriver 2.24.417431 (9aea000394714d2fbb20850021f6204f2256b9cf) on port 27796
Only local connections are allowed.
Jun 02, 2017 11:17:46 AM org.openqa.selenium.remote.ProtocolHandshake createSession
INFO: Detected dialect: OSS
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
Note: My script was working fine when I was using ChromeDriver 3.1 and Chrome 58 before the Windows security update. Post update I am not able to launch the Chrome browser as it's not launching the browser but running in the background.

Here is the Answer to your Question:
As the logs depict till INFO: Detected dialect: OSS all was fine with your code.
Next we observe SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". which means the issue is with the loading of the class.
You have mentioned My script was working fine when I was using ChromeDriver 3.1 and Chrome 58 before the Windows security update
So the solution would be to download the latest ChromeDriver 2.29 from here and re-execute your script.
Let me know if this Answers your Question.

You should remove all Chrome browser instances from the system and install Chrome browser v52-54 which is supported by your chromedeirver 2.24.
Without installing a Chrome v52-54 crhomedriver is not able to launch it.
Make sure this is currently installed version and it's not updated automatically when the browser starts. You may need to disable Google Chrome auto update

Related

Getting {"method":"Inspector.detached","params":{"reason":"target_closed"}} error in running selenium chromedriver

I'm running simple Selenium test, which uses selenium version 4.0.0 and chromedriver version 109. I'm running automation test on Salesforce application, which logs into the application and performs some operation. In the middle of the test execution, I get below error:
Jan 23, 2023 7:58:23 PM org.openqa.selenium.devtools.Connection handle
INFO: <- {"method":"Inspector.detached","params":{"reason":"target_closed"}}
Jan 23, 2023 7:58:23 PM org.openqa.selenium.devtools.Connection handle
INFO: Method Inspector.detached called with 0 callbacks available
After this connection to the browser is lost and when any further selenium webdriver statement(e.g. findElement) is executed, I gives exception:
org.openqa.selenium.NoSuchWindowException: no such window: target window already closed
from unknown error: web view not found
Can someone please help me with this ?
I tried different ways to fix the problem, Removed 'Thread.sleep' and updated browser capabilities as mentioned in this post, but it didn't work:
org.openqa.selenium.WebDriverException: disconnected: received Inspector.detached event error during test execution using Selenium and Chromedriver

Why are selenium ChromeDriver create null session in unix base OSs?

I developed a app to read some web pages using Selenium.
ChromeDriver on windows worked correctly but in unix base Oss (Mac & Centos7) does not worked!
I think a problem is "Forwarding newSession on session null to remote" in the unix base OSs.
Some warnings and info when I ran app in unix base OSs are as bellow:
Starting ChromeDriver 102.0.5005.61 (0e59bcc00cc4985ce39ad31c150065f159d95ad3-refs/branch-heads/5005#{#819}) on port 53751
Only local connections are allowed.
Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping ChromeDriver safe.
ChromeDriver was started successfully.
[1658989503.540][WARNING]: This version of ChromeDriver has not been tested with Chrome version 103.
28-Jul-2022 10:55:03.613 INFO [Forwarding newSession on session null to remote] org.openqa.selenium.remote.ProtocolHandshake.createSession Detected dialect: W3C
28-Jul-2022 10:55:03.673 WARNING [main] org.openqa.selenium.devtools.CdpVersionFinder.findNearestMatch Unable to find an exact match for CDP version 103, so returning the closest version found: a no-op implementation
28-Jul-2022 10:55:03.673 INFO [main] org.openqa.selenium.devtools.CdpVersionFinder.findNearestMatch Unable to find CDP implementation matching 103.
28-Jul-2022 10:55:03.674 WARNING [main] org.openqa.selenium.chromium.ChromiumDriver.lambda$new$3 Unable to find version of CDP to use for . You may need to include a dependency on a specific version of the CDP using something similar to `org.seleniumhq.selenium:selenium-devtools-v86:4.1.0` where the version ("v86") matches the version of the chromium-based browser you're using and the version number of the artifact is the same as Selenium's.
Are there any solutions to resolve ChromeDriver error?
If you have any suggestions that can be help me, please add comment or answer.
Thanks.
This error message...
Starting ChromeDriver 102.0.5005.61 (0e59bcc00cc4985ce39ad31c150065f159d95ad3-refs/branch-heads/5005#{#819}) on port 53751
.
[1658989503.540][WARNING]: This version of ChromeDriver has not been tested with Chrome version 103.
.
28-Jul-2022 10:55:03.613 INFO [Forwarding newSession on session null to remote] org.openqa.selenium.remote.ProtocolHandshake.createSession Detected dialect: W3C
28-Jul-2022 10:55:03.673 WARNING [main] org.openqa.selenium.devtools.CdpVersionFinder.findNearestMatch Unable to find an exact match for CDP version 103, so returning the closest version found: a no-op implementation
28-Jul-2022 10:55:03.673 INFO [main] org.openqa.selenium.devtools.CdpVersionFinder.findNearestMatch Unable to find CDP implementation matching 103.
28-Jul-2022 10:55:03.674 WARNING [main] org.openqa.selenium.chromium.ChromiumDriver.lambda$new$3 Unable to find version of CDP to use for . You may need to include a dependency on a specific version of the CDP using something similar to `org.seleniumhq.selenium:selenium-devtools-v86:4.1.0` where the version ("v86") matches the version of the chromium-based browser you're using and the version number of the artifact is the same as Selenium's.
...implies that the ChromeDriver was unable to initiate/spawn a new Browsing Context i.e. google-chrome session.
Your main issue is the incompatibility between the version of the binaries you are using.
Solution
Ensure that:
Selenium is upgraded to current released Version 4.3.0.
ChromeDriver is updated to current ChromeDriver v103.0 level.
Chrome Browser is updated to current chrome=103.0 (as per chromedriver=103.0.5060.53 release notes).

Launching chrome in headless mode with selenium in Java giving error

This is my code:
WebDriverManager.chromedriver().setup();
System.setProperty("webdriver.chrome.driver", "src/main/extras/chromedriver.exe");
ChromeOptions options = new ChromeOptions();
options.addArguments("--headless");
WebDriver driver = new ChromeDriver(options);
driver = new ChromeDriver();
driver.get(url);
The last line, getting the URL, is giving this error:
Exception in thread "Thread-3" java.lang.NullPointerException
I wasn't getting this error before I tried to launch the browser in headless mode.
This is my full error message thing:
"D:\Program Files\Amazon Corretto\jdk11.0.11_9\bin\java.exe" "-javaagent:C:\Program Files\JetBrains\IntelliJ IDEA 2021.2\lib\idea_rt.jar=59273:C:\Program Files\JetBrains\IntelliJ IDEA 2021.2\bin" -Dfile.encoding=UTF-8 -classpath C:\Users\jackg\.m2\repository\org\openjfx\javafx-controls\11.0.2\javafx-controls-11.0.2.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-graphics\11.0.2\javafx-graphics-11.0.2.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-fxml\11.0.2\javafx-fxml-11.0.2.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-web\11.0.2\javafx-web-11.0.2.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-media\11.0.2\javafx-media-11.0.2.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-base\11.0.1\javafx-base-11.0.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-java\4.1.1\selenium-java-4.1.1.jar;C:\Users\jackg\.m2\repository\com\google\auto\service\auto-service-annotations\1.0.1\auto-service-annotations-1.0.1.jar;C:\Users\jackg\.m2\repository\com\google\auto\service\auto-service\1.0.1\auto-service-1.0.1.jar;C:\Users\jackg\.m2\repository\com\google\auto\auto-common\1.2\auto-common-1.2.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-devtools-v85\4.1.1\selenium-devtools-v85-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-devtools-v94\4.1.1\selenium-devtools-v94-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-devtools-v95\4.1.1\selenium-devtools-v95-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-devtools-v96\4.1.1\selenium-devtools-v96-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-edge-driver\4.1.1\selenium-edge-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-firefox-driver\4.1.1\selenium-firefox-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-firefox-xpi-driver\4.1.1\selenium-firefox-xpi-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-ie-driver\4.1.1\selenium-ie-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-opera-driver\4.1.1\selenium-opera-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\io\netty\netty-codec\4.1.70.Final\netty-codec-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\io\netty\netty-handler\4.1.70.Final\netty-handler-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\io\netty\netty-resolver\4.1.70.Final\netty-resolver-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-exporter-logging\1.9.1\opentelemetry-exporter-logging-1.9.1.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-sdk-metrics\1.9.1-alpha\opentelemetry-sdk-metrics-1.9.1-alpha.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-sdk-logs\1.9.1-alpha\opentelemetry-sdk-logs-1.9.1-alpha.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-api-metrics\1.9.1-alpha\opentelemetry-api-metrics-1.9.1-alpha.jar;C:\Users\jackg\.m2\repository\org\asynchttpclient\async-http-client-netty-utils\2.12.3\async-http-client-netty-utils-2.12.3.jar;C:\Users\jackg\.m2\repository\io\netty\netty-codec-socks\4.1.60.Final\netty-codec-socks-4.1.60.Final.jar;C:\Users\jackg\.m2\repository\io\netty\netty-handler-proxy\4.1.60.Final\netty-handler-proxy-4.1.60.Final.jar;C:\Users\jackg\.m2\repository\io\netty\netty-transport-native-epoll\4.1.60.Final\netty-transport-native-epoll-4.1.60.Final-linux-x86_64.jar;C:\Users\jackg\.m2\repository\io\netty\netty-transport-native-kqueue\4.1.60.Final\netty-transport-native-kqueue-4.1.60.Final-osx-x86_64.jar;C:\Users\jackg\.m2\repository\org\reactivestreams\reactive-streams\1.0.3\reactive-streams-1.0.3.jar;C:\Users\jackg\.m2\repository\com\typesafe\netty\netty-reactive-streams\2.0.4\netty-reactive-streams-2.0.4.jar;C:\Users\jackg\.m2\repository\com\sun\activation\jakarta.activation\1.2.2\jakarta.activation-1.2.2.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-safari-driver\4.1.1\selenium-safari-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\org\slf4j\slf4j-api\1.7.32\slf4j-api-1.7.32.jar;C:\Users\jackg\.m2\repository\com\google\code\gson\gson\2.8.8\gson-2.8.8.jar;C:\Users\jackg\.m2\repository\org\jsoup\jsoup\1.14.2\jsoup-1.14.2.jar;C:\Users\jackg\.m2\repository\com\github\docker-java\docker-java\3.2.12\docker-java-3.2.12.jar;C:\Users\jackg\.m2\repository\com\github\docker-java\docker-java-core\3.2.12\docker-java-core-3.2.12.jar;C:\Users\jackg\.m2\repository\com\github\docker-java\docker-java-api\3.2.12\docker-java-api-3.2.12.jar;C:\Users\jackg\.m2\repository\com\fasterxml\jackson\core\jackson-annotations\2.10.3\jackson-annotations-2.10.3.jar;C:\Users\jackg\.m2\repository\commons-io\commons-io\2.6\commons-io-2.6.jar;C:\Users\jackg\.m2\repository\org\apache\commons\commons-compress\1.21\commons-compress-1.21.jar;C:\Users\jackg\.m2\repository\commons-lang\commons-lang\2.6\commons-lang-2.6.jar;C:\Users\jackg\.m2\repository\com\fasterxml\jackson\core\jackson-databind\2.10.3\jackson-databind-2.10.3.jar;C:\Users\jackg\.m2\repository\com\fasterxml\jackson\core\jackson-core\2.10.3\jackson-core-2.10.3.jar;C:\Users\jackg\.m2\repository\org\bouncycastle\bcpkix-jdk15on\1.64\bcpkix-jdk15on-1.64.jar;C:\Users\jackg\.m2\repository\org\bouncycastle\bcprov-jdk15on\1.64\bcprov-jdk15on-1.64.jar;C:\Users\jackg\.m2\repository\org\slf4j\jcl-over-slf4j\1.7.30\jcl-over-slf4j-1.7.30.jar;C:\Users\jackg\.m2\repository\com\github\docker-java\docker-java-transport-httpclient5\3.2.12\docker-java-transport-httpclient5-3.2.12.jar;C:\Users\jackg\.m2\repository\com\github\docker-java\docker-java-transport\3.2.12\docker-java-transport-3.2.12.jar;C:\Users\jackg\.m2\repository\org\apache\httpcomponents\client5\httpclient5\5.0.3\httpclient5-5.0.3.jar;C:\Users\jackg\.m2\repository\org\apache\httpcomponents\core5\httpcore5\5.0.2\httpcore5-5.0.2.jar;C:\Users\jackg\.m2\repository\commons-codec\commons-codec\1.13\commons-codec-1.13.jar;C:\Users\jackg\.m2\repository\com\google\guava\failureaccess\1.0.1\failureaccess-1.0.1.jar;C:\Users\jackg\.m2\repository\com\google\guava\listenablefuture\9999.0-empty-to-avoid-conflict-with-guava\listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar;C:\Users\jackg\.m2\repository\com\google\code\findbugs\jsr305\3.0.2\jsr305-3.0.2.jar;C:\Users\jackg\.m2\repository\org\checkerframework\checker-qual\3.8.0\checker-qual-3.8.0.jar;C:\Users\jackg\.m2\repository\com\google\errorprone\error_prone_annotations\2.5.1\error_prone_annotations-2.5.1.jar;C:\Users\jackg\.m2\repository\com\google\j2objc\j2objc-annotations\1.3\j2objc-annotations-1.3.jar;C:\Users\jackg\.m2\repository\org\brotli\dec\0.1.2\dec-0.1.2.jar;C:\Users\jackg\.m2\repository\org\apache\commons\commons-lang3\3.12.0\commons-lang3-3.12.0.jar;C:\Users\jackg\.m2\repository\org\apache\commons\commons-text\1.9\commons-text-1.9.jar;C:\Users\jackg\.m2\repository\commons-beanutils\commons-beanutils\1.9.4\commons-beanutils-1.9.4.jar;C:\Users\jackg\.m2\repository\commons-logging\commons-logging\1.2\commons-logging-1.2.jar;C:\Users\jackg\.m2\repository\commons-collections\commons-collections\3.2.2\commons-collections-3.2.2.jar;C:\Users\jackg\.m2\repository\org\apache\commons\commons-collections4\4.4\commons-collections4-4.4.jar -p "C:\Users\jackg\.m2\repository\org\openjfx\javafx-base\11.0.1\javafx-base-11.0.1-win.jar;C:\Users\jackg\.m2\repository\io\netty\netty-transport-classes-kqueue\4.1.70.Final\netty-transport-classes-kqueue-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\org\controlsfx\controlsfx\11.1.0\controlsfx-11.1.0.jar;C:\Users\jackg\.m2\repository\net\synedra\validatorfx\0.1.13\validatorfx-0.1.13.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-sdk\1.9.1\opentelemetry-sdk-1.9.1.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-graphics\11.0.2\javafx-graphics-11.0.2-win.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-fxml\11.0.2\javafx-fxml-11.0.2-win.jar;C:\Users\jackg\.m2\repository\com\beust\jcommander\1.81\jcommander-1.81.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-controls\11.0.2\javafx-controls-11.0.2-win.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-chromium-driver\4.1.1\selenium-chromium-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\io\netty\netty-transport-classes-epoll\4.1.70.Final\netty-transport-classes-epoll-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-api\4.1.1\selenium-api-4.1.1.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-json\4.1.1\selenium-json-4.1.1.jar;C:\Users\jackg\.m2\repository\net\java\dev\jna\jna\5.8.0\jna-5.8.0.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-sdk-extension-autoconfigure-spi\1.9.1\opentelemetry-sdk-extension-autoconfigure-spi-1.9.1.jar;C:\Users\jackg\.m2\repository\net\jodah\failsafe\2.4.4\failsafe-2.4.4.jar;C:\Users\jackg\.m2\repository\io\netty\netty-transport-native-unix-common\4.1.70.Final\netty-transport-native-unix-common-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\io\netty\netty-codec-http\4.1.70.Final\netty-codec-http-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-sdk-extension-autoconfigure\1.9.1-alpha\opentelemetry-sdk-extension-autoconfigure-1.9.1-alpha.jar;C:\Users\jackg\.m2\repository\net\bytebuddy\byte-buddy\1.12.2\byte-buddy-1.12.2.jar;C:\Users\jackg\.m2\repository\io\netty\netty-buffer\4.1.70.Final\netty-buffer-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\io\github\bonigarcia\webdrivermanager\5.0.3\webdrivermanager-5.0.3.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-sdk-common\1.9.1\opentelemetry-sdk-common-1.9.1.jar;C:\Users\jackg\.m2\repository\org\apache\commons\commons-exec\1.3\commons-exec-1.3.jar;C:\Users\jackg\.m2\repository\io\netty\netty-common\4.1.70.Final\netty-common-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\org\kordamp\ikonli\ikonli-javafx\12.2.0\ikonli-javafx-12.2.0.jar;C:\Users\jackg\.m2\repository\com\dlsc\formsfx\formsfx-core\11.4.2\formsfx-core-11.4.2.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-sdk-trace\1.9.1\opentelemetry-sdk-trace-1.9.1.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-api\1.9.1\opentelemetry-api-1.9.1.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-web\11.0.2\javafx-web-11.0.2-win.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-context\1.9.1\opentelemetry-context-1.9.1.jar;C:\Users\jackg\.m2\repository\com\google\guava\guava\30.1.1-jre\guava-30.1.1-jre.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-chrome-driver\4.1.1\selenium-chrome-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\com\opencsv\opencsv\5.5.2\opencsv-5.5.2.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-support\4.1.1\selenium-support-4.1.1.jar;C:\Users\jackg\.m2\repository\org\kordamp\bootstrapfx\bootstrapfx-core\0.4.0\bootstrapfx-core-0.4.0.jar;C:\Users\jackg\.m2\repository\org\openjfx\javafx-media\11.0.2\javafx-media-11.0.2-win.jar;C:\Users\jackg\.m2\repository\eu\hansolo\tilesfx\11.48\tilesfx-11.48.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-http\4.1.1\selenium-http-4.1.1.jar;C:\Users\jackg\.m2\repository\org\asynchttpclient\async-http-client\2.12.3\async-http-client-2.12.3.jar;C:\Users\jackg\.m2\repository\io\opentelemetry\opentelemetry-semconv\1.9.1-alpha\opentelemetry-semconv-1.9.1-alpha.jar;C:\Users\jackg\.m2\repository\io\ous\jtoml\2.0.0\jtoml-2.0.0.jar;C:\Users\jackg\.m2\repository\org\seleniumhq\selenium\selenium-remote-driver\4.1.1\selenium-remote-driver-4.1.1.jar;C:\Users\jackg\.m2\repository\io\netty\netty-transport\4.1.70.Final\netty-transport-4.1.70.Final.jar;C:\Users\jackg\.m2\repository\org\kordamp\ikonli\ikonli-core\12.2.0\ikonli-core-12.2.0.jar;D:\Users\jackg\Desktop\Java Code\Ethermine Tracker JavaFX\target\classes" -m com.traptricker.etherminetrackerjavafx/com.traptricker.etherminetrackerjavafx.Main
Dec 30, 2021 9:22:25 PM javafx.fxml.FXMLLoader$ValueElement processValue
WARNING: Loading FXML document with JavaFX API of version 17 by JavaFX runtime of version 11.0.1
Starting program...
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
Starting ChromeDriver 95.0.4638.17 (a9d0719444d4b035e284ed1fce73bf6ccd789df2-refs/branch-heads/4638#{#178}) on port 63013
Only local connections are allowed.
Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping ChromeDriver safe.
ChromeDriver was started successfully.
[1640917354.440][WARNING]: This version of ChromeDriver has not been tested with Chrome version 96.
Dec 30, 2021 9:22:34 PM org.openqa.selenium.remote.ProtocolHandshake createSession
INFO: Detected dialect: W3C
Dec 30, 2021 9:22:34 PM org.openqa.selenium.devtools.CdpVersionFinder findNearestMatch
INFO: Found exact CDP implementation for version 96
Starting ChromeDriver 95.0.4638.17 (a9d0719444d4b035e284ed1fce73bf6ccd789df2-refs/branch-heads/4638#{#178}) on port 53163
Only local connections are allowed.
Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping ChromeDriver safe.
ChromeDriver was started successfully.
[1640917356.435][WARNING]: This version of ChromeDriver has not been tested with Chrome version 96.
Dec 30, 2021 9:22:36 PM org.openqa.selenium.remote.ProtocolHandshake createSession
INFO: Detected dialect: W3C
Dec 30, 2021 9:22:36 PM org.openqa.selenium.devtools.CdpVersionFinder findNearestMatch
INFO: Found exact CDP implementation for version 96
Exception in thread "Thread-3" java.lang.NullPointerException
at com.traptricker.etherminetrackerjavafx/com.traptricker.etherminetrackerjavafx.SeleniumScrapper.setUpWebdriver(SeleniumScrapper.java:31)
at com.traptricker.etherminetrackerjavafx/com.traptricker.etherminetrackerjavafx.Controller.trackEthermine(Controller.java:54)
at java.base/java.lang.Thread.run(Thread.java:829)
You need to take care of a few things here:
You have already download the ChromeDriver and accessing it as:
System.setProperty("webdriver.chrome.driver", "src/main/extras/chromedriver.exe");
Additionally you are also downloading ChromeDriver through WebDriverManager as:
WebDriverManager.chromedriver().setup();
As a result your program have access to multiple instances of ChromeDriver. Hence you see:
Exception in thread "Thread-3" java.lang.NullPointerException
Solution
You need to use only one instance of ChromeDriver either the downloaded version or the one downloaded and accessed through WebDriverManager

Remote IE click has no effect

Nothing happens after clicking on the web element. I have even print the statement after the click operation which is executed correctly but after that is is failing as click operation is not changing the object state.
Steps to reproduce -
create a selenium script to load google home page.
click on the I'm feeling Lucky button`enter code here.
it should load the doodle page.
When I run this script on my local machine, it worked fine. Now i have created an executable jar file using maven and eclipse to run my test suit and downloaded this jar on my remote desktop machine on server with all the necessary dependent files.
When I run the test using CMD java -jar "test-suit.jar".
It is opening IE browser successfully and load the url . It is clicking on I'm feeling lucky but it does not load doodle page after click and test fails . no error is given just i got this log:
log4j:WARN No appenders could be found for logger (org.apache.http.client.protoc
ol.RequestAddCookies).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more in
fo.
Sep 20, 2018 7:28:39 AM io.github.bonigarcia.wdm.WebDriverManager getDriversFrom
Xml
INFO: Reading https://selenium-release.storage.googleapis.com/ to seek IEDriverS
erver
Sep 20, 2018 7:28:40 AM io.github.bonigarcia.wdm.WebDriverManager getLatest
INFO: Latest version of IEDriverServer is 3.14
Sep 20, 2018 7:28:40 AM io.github.bonigarcia.wdm.Downloader checkBinary
INFO: Using binary driver previously downloaded
Sep 20, 2018 7:28:40 AM io.github.bonigarcia.wdm.WebDriverManager exportDriver
INFO: Exporting webdriver.ie.driver as C:\Users\debolin.dhar.m2\repository\webd
river\IEDriverServer\Win32\3.14\IEDriverServer.exe
null
true
null
false
Started InternetExplorerDriver server (32-bit)
3.14.0.0
Listening on port 24032
Only local connections are allowed
Sep 20, 2018 7:28:47 AM org.openqa.selenium.remote.ProtocolHandshake createSessi
on
INFO: Detected dialect: W3C
true
false
clicked on I'm feeling lucky
doodle Page doesn't exist
===============================================
Suite
Total tests run: 4, Failures: 1, Skips: 1
I don't understand what could be the error. Whether it is not clicking and not throwing any error also or I need to take certain additional settings to be set on my server machine or change in my script to get it work.

Google App Engine - How to get demos to work?

I'm embarrassed to have to ask this, but I can't for the life of me figure out what I'm doing wrong.
I've downloaded the appengine-java-sdk-1.4.2 via the eclipse 3.6 plugin as per the instructions on Installing the Java SDK page. I am running Mac OSX 10.5.8 with JRE version 1.5.0_26. I have made the dev_appserver.sh file executable (chmod u+x dev_appserver.sh) and when I attempt to start the app server with one of the demos via the command
bin/dev_appserver.sh demos/guestbook/war/
I get the following output, but the server does not start up:
2011-03-13 17:52:43.404 java[839:80f] [Java CocoaComponent compatibility mode]: Enabled
2011-03-13 17:52:43.405 java[839:80f] [Java CocoaComponent compatibility mode]: Setting timeout for SWT to 0.100000
********************************************************
Warning: Future versions of the Dev App Server will require Java 1.6 or later. Please upgrade your JRE.
********************************************************
Mar 13, 2011 9:52:44 PM com.google.apphosting.utils.jetty.JettyLogger info
INFO: Logging to JettyLogger(null) via com.google.apphosting.utils.jetty.JettyLogger
Mar 13, 2011 9:52:44 PM com.google.apphosting.utils.config.AppEngineWebXmlReader readAppEngineWebXml
INFO: Successfully processed /Applications/eclipse_3.6/plugins/com.google.appengine.eclipse.sdkbundle.1.4.2_1.4.2.v201102111811/appengine-java-sdk-1.4.2/demos/guestbook/war/WEB-INF/appengine-web.xml
Mar 13, 2011 9:52:44 PM com.google.apphosting.utils.config.AbstractConfigXmlReader readConfigXml
INFO: Successfully processed /Applications/eclipse_3.6/plugins/com.google.appengine.eclipse.sdkbundle.1.4.2_1.4.2.v201102111811/appengine-java-sdk-1.4.2/demos/guestbook/war/WEB-INF/web.xml
I see the warning about upgrading the JRE, but I don't think this is the problem, as there are no exceptions reported. It just won't start up. I've tried creating a hello world app from within Eclipse using the plugin and running as Web server, but that also spits out the same text but does not start up the web server.
Any idea what I'm doing wrong and how to remedy the problem?
By changing the line in dev_appserver.sh to
/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Commands/java -ea -cp "$JAR_FILE" \
com.google.appengine.tools.KickStart \
com.google.appengine.tools.development.DevAppServerMain $*
instead of using the default java (which is set to 1.5.0_26 as I mentioned earlier) the web server starts up.
I had the same problem and simply tried running Eclipse as Administrator and then debugging worked fine.

Categories

Resources