Getting org.openqa.selenium.WebDriverException: java.net.SocketException on Java client 6.0.0-Beta5 and 6.0.0 versions
The problem
Getting org.openqa.selenium.WebDriverException: java.net.SocketException on Java client 6.0.0-Beta5 and 6.0.0 versions
Environment
- Appium version (or git revision) that exhibits the issue: 1.8.0
- Last Appium version that did not exhibit the issue (if applicable):
- Desktop OS/version used to run Appium: Windows 10
- Node.js version (unless using Appium.app|exe): Latest
- Mobile platform/version under test: API 25
- Real device or emulator/simulator: Real device
- Appium CLI or Appium.app|exe: Appium CLI
- TestNG -6.14.3
- Extent Reports - 2.41.2
Link to Stack trace
https://gist.github.com/Gocoollnath/2b949429341574b459776937053a3913
Link to Appium logs
https://gist.github.com/Gocoollnath/29e05255e3ff5c595c929da84ce19652
Code To Reproduce Issue [ Good To Have ]
https://gist.github.com/Gocoollnath/4d54fe5ddfacf1d8e3260ea9330f135c
@sravanmedarapu @dpgraham Could any light be thrown into this issue,please?
I am also getting an org.openqa.selenium.WebDriverException, java.net.SocketException. Reproducible with version java client version 6.0.0 only
@Gocoollnath @ElenaAlejo I couldn't reproduce this issue in latest java client(6.0.0) and server version(1.8.1).
@SrinivasanTarget the issue is not continuous. It occurs sparingly
@Gocoollnath @ElenaAlejo Have been running tests since then the versions are out. I couldn't reproduce it. So its hard to solve atleast from my end.
Hello, @SrinivasanTarget , I update the server version to 1.8.1, and I still have the issue, that is reproducible in my test cases, not intermittent. This is the log:
https://gist.github.com/ElenaAlejo/79d21d5c8284b24e8b74202de2c00cb7
Stack trace:
Message: org.openqa.selenium.WebDriverException: java.net.SocketException: Connection reset
Build info: version: '3.12.0', revision: '7c6e0b3', time: '2018-05-08T14:04:26.12Z'
System info: host: 'MacBook-Pro-de-elena.local', ip: 'fe80:0:0:0:8b9:df9e:95df:fa45%en0', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.13.2', java.version: '1.8.0_151'
Driver info: driver.version: IOSDriver
Stack Trace:
io.appium.java_client.remote.AppiumCommandExecutor.execute(AppiumCommandExecutor.java:233)
org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:543)
io.appium.java_client.DefaultGenericMobileDriver.execute(DefaultGenericMobileDriver.java:46)
io.appium.java_client.AppiumDriver.execute(AppiumDriver.java:1)
io.appium.java_client.ios.IOSDriver.execute(IOSDriver.java:1)
io.appium.java_client.HasSessionDetails.getSessionDetails(HasSessionDetails.java:39)
io.appium.java_client.HasSessionDetails.getSessionDetail(HasSessionDetails.java:56)
io.appium.java_client.HasSessionDetails.getPlatformName(HasSessionDetails.java:65)
io.appium.java_client.pagefactory.AppiumFieldDecorator.
Workaround: I am using Java client 6.0.0-Beta5
@ElenaAlejo there is fix in master https://github.com/appium/java-client/pull/928/ can you please try building latest from master n give it a try.
In my case the master code fixed this issue.
I am facing similar issue with Java client 5.0.0 versions also:-
Can you please let us know how to write details in pom.xml for java -client master code.
org.openqa.selenium.WebDriverException: java.net.SocketException: Connection reset Build info: version: '3.12.0', revision: '7c6e0b3', time: '2018-05-08T14:04:26.12Z' System info: host: 'gwgmobilabsiMac', ip: 'fe80:0:0:0:10e4:6e09:2a1:57de%en0', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.13.4', java.version: '1.8.0_171' Driver info: driver.version: IOSDriver at io.appium.java_client.remote.AppiumCommandExecutor.execute(AppiumCommandExecutor.java:104) at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:543) at io.appium.java_client.DefaultGenericMobileDriver.execute(DefaultGenericMobileDriver.java:42) at io.appium.java_client.AppiumDriver.execute(AppiumDriver.java:1)
@Siddh010 clone master and run ./gradlew clean build -x test -x signArchives and replace the .jar from build/ inside .m2 of io.java-client
I am able to build the project but now block with below issue as I am not able to init Page Object. ExceptionI while trying to Initialise Page factory with Java client 6.0.0 #949
I am using Java client 6.0.0 and face the same issue, I think everyone using page factory framework and facing this issue. Can anyone fix this? Please describe in detail, how it gonna be fixed
@NavdeepSingh09 Please use version 6.1.0
It's working Thanks