【问题标题】:ModuleNotFoundError: No module named 'appium' (yes I have appium, adk, and appium-python-client)ModuleNotFoundError:没有名为“appium”的模块(是的,我有 appium、adk 和 appium-python-client)
【发布时间】:2020-11-05 13:10:16
【问题描述】:

我正在尝试使用 appium 启动,当我尝试在 python 中导入 appium 时出现此错误:

C:\Users\Sams PC>python
Python 3.8.4 (tags/v3.8.4:dfa645a, Jul 13 2020, 16:46:45) [MSC v.1924 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import appium
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'appium'

涵盖我所拥有的:

Appium:

C:\Users\Sams PC>appium
[Appium] Welcome to Appium v1.17.1
[Appium] Appium REST http interface listener started on 0.0.0.0:4723

Appium-python-客户端

C:\Users\Sams PC>pip install appium-python-client
Requirement already satisfied: appium-python-client in c:\users\sams pc\appdata\local\programs\python\python37\lib\site-packages (1.0.2)
Requirement already satisfied: selenium<4,>=3.14.1 in c:\users\sams pc\appdata\local\programs\python\python37\lib\site-packages (from appium-python-client) (3.141.0)
Requirement already satisfied: urllib3 in c:\users\sams pc\appdata\local\programs\python\python37\lib\site-packages (from selenium<4,>=3.14.1->appium-python-client) (1.25.7)

C:\Users\Sams PC>

我已经安装并设置了 Android Studio:

C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Android Studio>dir
 Volume in drive C has no label.
 Volume Serial Number is C08F-2C8E

 Directory of C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Android Studio

07/15/2020  06:26 PM    <DIR>          .
07/15/2020  06:26 PM    <DIR>          ..
07/15/2020  06:26 PM             1,181 Android Studio.lnk
               1 File(s)          1,181 bytes
               2 Dir(s)  30,455,201,792 bytes free

我查看了所有其他类似的问题,但我不太明白我缺少什么,因为我已经下载了看起来所需的所有内容。

【问题讨论】:

  • 你能检查pippython是否来自同一路径。

标签: python android appium


【解决方案1】:

你的 pip 指向 Python 3.7,而你的 Python 是 3.8。 将指向 3.7 的 pip 路径更改为 3.8,然后再次执行 pip install Appium-Python-Client

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2019-09-18
    • 1970-01-01
    • 2016-10-18
    • 1970-01-01
    • 2020-10-30
    • 1970-01-01
    • 2019-03-28
    相关资源
    最近更新 更多