AirtestProject / AirtestProject/Airtest

If using Airtest adb.exe, import trace outputs ModuleNotfoundError. However, Module can be imported if using Python's default adb.exe.

Abierto
#468 3 comentarios 0 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
Python
Estrellas
9.6k
Forks
1.5k
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

**Python version:** `python3.7.2`
**AirtestIDE version:** `V1.2.0`
**Poco version:** `pocoui==1.0.76`
**Airtest version:** `airtest==1.0.27`

**Describe the bug**
When using Airtest adb.exe to run `import trace`, Airtest shows ModuleNotFoundError.
When using Python adb.exe to run `import trace`. No error.

**Using Airtest adb.exe**
`\AirtestIDE_2019-01-15\AirtestIDE_2019-01-15_py3_win64\airtest\core\android\static\adb\windows\adb.exe`

```
ERROR: runTest (app.widgets.code_runner.ide_launcher.AirtestIDECase)
----------------------------------------------------------------------
Traceback (most recent call last):
File "airtest\cli\runner.py", line 66, in runTest
File "site-packages\six.py", line 693, in reraise
File "airtest\cli\runner.py", line 62, in runTest
File "E:\Stuff\AirtestPocoProjects\SecretGameRobot.air\SecretGameRobot.air\SecretGameRobot.py", line 175, in
import ThreadWithTrace
File "E:\Stuff\AirtestPocoProjects\SecretGameRobot.air\SecretGameRobot.air\ThreadWithTrace.py", line 7, in
import trace
ModuleNotFoundError: No module named 'trace'
```
**Using Python adb.exe**
No problem

**To Reproduce**
Steps to reproduce the behavior:
1. Open empty project in Airtest v1.2.0, with default python path set by airtest
2. Type import trace
3. Run code
4. See error

**Expected behavior**
Airtest adb.exe should be able to import trace , because it is found in Python37 > Lib
![image](https://user-images.githubusercontent.com/19833754/61613287-84d17400-ac93-11e9-82cd-bda94f175c1e.png)

**Screenshots**
My ThreadWithTrace class that outputs error when run using Airtest adb.exe
![image](https://user-images.githubusercontent.com/19833754/61613318-99ae0780-ac93-11e9-9d49-4af75e7756a1.png)

**Smartphone (please complete the following information):**
- Device: Pocophone F1
- Android Version : Android 9 PKQ1.18076

Guía de contribución

No hay ninguna guía de contribución indexada para este repositorio

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.