AirtestProject / AirtestProject/Poco

Airtest默认端口5001经常被Unity占用导致poco UI树刷新不出来

Ouverte
#536 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
Python
Étoiles
2k
Forks
341
Métriques de merge des PR
Aucune PR mergée en 30 j

Description

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

**(重要!问题分类)**
* 图像识别相关问题 -> https://github.com/AirtestProject/Airtest/issues
* 测试开发环境AirtestIDE使用问题 -> https://github.com/AirtestProject/AirtestIDE/issues
* 控件识别、树状结构、poco库报错 -> 此仓库

**描述问题bug**
Airtest默认端口5001经常被Unity占用导致poco UI树刷新不出来

**复现步骤**
1. 启动Airtest
2. 启动Unity
3. 使用Airtest设备窗选中拖拽出来的Unity Game窗口
4. 运行Unity
5. 在Airtest中没有显示poco UI树
6. 确认主摄像机已挂载Poco Manager
7. 在系统控制台输入netstat -aon|findstr 5001,查看Airtest默认5001端口号的占用情况,发现是Unity在占用。
8. 该问题经常出现在如下操作中:首次建立Airtest、Unity、poco联调,poco UI树显示正常。然后,停止Unity Game窗口内的程序运行,再运行Unity Game窗口内的程序,接着建立联调,poco UI树无法正常刷新出来。经查询,发现是Airtest默认5001端口号被Unity占用。每次出现这个问题,都需要手动将Unity关闭再重新打开,很麻烦,非常影响工作效率。

**预期效果**
有没有什么办法或是合理的操作建议,能够减少或是规避甚至解决该问题的产生。

**相关截图**
![poco_UI_01](https://user-images.githubusercontent.com/34853505/161008537-8479dd02-f507-496f-a150-bb249d741e5e.png)

![poco_UI_02](https://user-images.githubusercontent.com/34853505/161008884-fb67f447-b318-4c76-bc8d-1c2a65779b7e.png)

![poco_UI_03](https://user-images.githubusercontent.com/34853505/161009318-4a109f3a-70cf-4ca6-aa0d-dcb8a4215d4d.png)

![poco_UI_04](https://user-images.githubusercontent.com/34853505/161009843-dcc673cb-5ed2-40df-8815-cf3c453732e2.png)

**python 版本:** `python3.8.9`

**poco 版本:** `1.0.84`
> poco版本通过`pip freeze`可以命令可以查到

**设备:**
- 型号: PC
- 系统: Windows 10
- (别的信息)无

**其他相关环境信息**
目前只在Windows 10系统上运行,经常出现此问题。

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.