尝试在python中使用appium按坐标点击时出现此错误:
AttributeError: 'list' 对象没有属性 'id'
这是我使用的代码:
from selenium import webdriver
from appium.webdriver.common.touch_action import TouchAction
caps = {}
caps["deviceName"] = "NVWCE6YSV47TGM8S"
caps["platformName"] = "Android"
caps["appPackage"] = "com.gradrix.quicklaunch"
caps["appActivity"] = "com.gradrix.quicklaunch.MainActivity"
driver = webdriver.Remote("http://localhost:4723/wd/hub", caps)
time.sleep(5)
TouchAction(driver).tap([(104, 255)]).perform()
driver.quit()
Run Code Online (Sandbox Code Playgroud)