今天想学习下uiautomator2
模块,但是第一步就卡住了,python3 -m uiautomator2 init
初始化的时候报错了,报错信息如下

主要是 ConnectionRefusedError: [Errno 61] Connection refused 连接被拒绝。
问题原因: 因为我以前下过uiautomator2
,可能是我以前的uiautomator2
版本太低了 卸载了 重新装一下就好了
解决
- 卸载
pip3 uninstall uiautomator2

- 重装
pip3 install --pre uiautomator2

- 最后
python3 -m uiautomator2 init

网友评论