当前位置: 首页 > 后端技术 > Python

uiautomator2ConnectionErrorrequests.exceptions.ReadTimeout-

时间:2023-03-26 00:43:18 Python

使用uiautomator2时,有时会报uiautomator2requests.exceptions.ConnectionError:HTTPConnectionPool(host='localhost',port=54573):orrequests.exceptions.ReadTimeout:HTTPConnectionPool(host='[127.0.0.1](127.0.0.1)',port=61466:读取超时。(readtimeout=60)当出现这两个错误时,只需重新安装uiautomator2包即可解决问题python-muiautomator2init如果init过程中console输出信息,卡不动,直接重新连接手机和usbsocket,然后重新init即可解决问题