代码如下,提示error: Logcat capture failed: spawn ENOENT
from appium import webdriver from time import sleep desired_caps={} desired_caps[‘platformName‘]= ‘Android‘ desired_caps[‘platformVersion‘]= ‘5.1.1‘ desired_caps[‘deviceName‘]= ‘127.0.0.1:62001‘ desired_caps[‘appPackage‘]=‘com.cleanmaster.mguard_cn‘ desired_caps[‘appActivity‘]=‘com.keniu.security.main.MainActivity‘ driver=webdriver.Remote(‘http://localhost:4723/wd/hub‘,desired_caps)
但是将
driver=webdriver.Remote(‘http://localhost:4723/wd/hub‘,desired_caps)
改为
driver=webdriver.Remote(‘http://127.0.0.1:4723/wd/hub‘,desired_caps)
运行正常了
不明所以