1 官网下载源码:
https://pypi.org/project/Appium-Python-Client/#files
也可下载历史版本
2 解压下载后的安装包
3 进入Appium-Python-Client 的解压路径下
输入:
python3 setup.py install
回车即可安装成功
from appium import webdriver
from appium.webdriver.common.appiumby import AppiumBy
des_cap = {}
des_cap['platformName'] = 'Android'
driver = webdriver.Remote(command_executor='http://127.0.0.1:4723/wd/hub',
desired_capabilities=des_cap)
driver.find_element(AppiumBy.ID)