创建新会话是不可能的,因为使用HttpClient的“ createSession” [英] It is impossible to create a new session because 'createSession' which takes HttpClient,

查看:479
本文介绍了创建新会话是不可能的,因为使用HttpClient的“ createSession”的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

org.openqa.selenium.WebDriverException:无法创建新会话,因为未找到需要HttpClient,InputStream和long的'createSession'或无法访问
构建信息:版本:'3.12。 0',修订:'7c6e0b3',时间:'2018-05-08T14:04:26.12Z'

org.openqa.selenium.WebDriverException: It is impossible to create a new session because 'createSession' which takes HttpClient, InputStream and long was not found or it is not accessible Build info: version: '3.12.0', revision: '7c6e0b3', time: '2018-05-08T14:04:26.12Z'

我随机收到此错误,我想知道路线在iOS中导致此问题的原因

I am getting this error randomly i want to know the route cause for this issue in IOS

推荐答案

此问题背后有多个原因。有多种方法可以解决此问题,具体取决于这些问题的来源。

There are multiple reason behind this issue. There are multiple ways to resolve this issues, depending upon, where these issues are coming from.

1)我想到的一个问题是DesireCapabilities.setCapability()key /值不是正确的类型。我已经通过
DesiredCapabilities.setCapability( capabilities_variable, capabilities_value);解决了此问题
setCapability( appWaitDuration, 600000);这里的600000是String而不是long或int
检查您的setCapability类型是否为String / int / long。

1)One issue which occur to me was DesireCapabilities.setCapability() key/value was not correct type. I have resolved this issue by just DesiredCapabilities.setCapability("capabilities_variable","capabilities_value"); setCapability("appWaitDuration", "600000"); here 600000 was String instead of long or int Check your setCapability type whether it String/int/long.

2)检查 USB 连接是笔记本电脑还是计算机,如果未连接则是同一问题。

2) Check USB Connection is Laptop or Computer, if not connected than same issue.

3) ADB 服务器可能有问题。因此 adb kill-server adb启动服务器

3) ADB Server might be problem. So adb kill-server and adb start-server

4)尝试更改 USB

4) Try to change USB and try it out.

5)有时,这可能是代理问题(笔记本电脑/台式机在组织中可能有一些代理设置
,因为台式机/笔记本电脑通过TCP / IP连接与Mobile连接)。

5) Sometimes, it might be a proxy issue(Laptop/Desktop may have some proxy setup in organization, since for Desktop/Laptops are connected with Mobile via TCP/IP Connection).

6)有时,可能需要访问 PORT 的权限( sudo ufw allow portnumber (UBUNTU系统) )

6) Sometimes, there might be permission required to access PORT (sudo ufw allow portnumber (UBUNTU SYSTEM))

7)需要环境变量 Android_SDK_Home 和Android平台工具路径

7) Environment variable required Android_SDK_Home and Android Platform Tools path

这篇关于创建新会话是不可能的,因为使用HttpClient的“ createSession”的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆