Skip to content

airtest执行时,会出现很多类似“Poco 连接断开”这样的错误,导致自动化任务无法正常运行 #1327

Description

@liuchengru

(请尽量按照下面提示内容填写,有助于我们快速定位和解决问题,感谢配合。否则直接关闭。)

(重要!问题分类)

描述问题bug
(简洁清晰得概括一下遇到的问题是什么。或者是报错的traceback信息。)
airtest执行时,会出现很多类似“Poco 连接断开”这样的错误,导致自动化任务无法正常运行
堆栈信息有如下几种:
1、Poco 连接断开(keep-alive 过期),1s 后重试 logout: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))
2、HTTPConnectionPool(host='127.0.0.1', port=11969): Max retries exceeded with url: / (Caused by
ConnectionError('<urllib3. connection.HTTPConnection object at 0x7f1543421040>: Failed to establish a new connection: [Errno 111] Connection refused'))
3、'Connection aborted.', RemoteDisconnected ('Remote end closed connection without response')
4、poco = AndroidUiautomationPoco (use_airtest_input=True, screenshot_each_action=False)
File /usr/local/python3.8/lib/python3.8/site-packages/poco/drivers/android/uiautomation.py", line 197, in init
raise RuntimeError("unable to launch AndroidUiautomationPoco")
RuntimeError: unable to launch AndroidUiautomationPoco

(在这里粘贴traceback或其他报错信息)

相关截图
(贴出遇到问题时的截图内容,如果有的话)

Image Image Image Image

复现步骤
非必现,有概率性

  1. adb连接手机
  2. 进行一些点击,滑动等操作
  3. See error

预期效果
(预期想要得到什么、见到什么)
poco服务不报错,airtest自动化正常运行,不中断

python 版本: python3.7``python3.8

airtest 版本: 1.3.5

airtest版本通过pip freeze可以命令可以查到

设备:

  • 型号: [e.g. SAMSUNG SM-A055F]
  • 系统: [e.g. Android 14]

其他相关环境信息

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions