操作:
class TestExample:
def setup(self):
desired_caps = {
"platformName": "Android",
"platformVersion": "13",
"deviceName": "L7Y9Q8RC5LDQAERO",
"appPackage": "com.android.chrome",
"appActivity": "com.google.android.apps.chrome.Main",
'automationName': 'UIAutomator2',
}
self.driver = webdriver.Remote("http://127.0.0.1:4723/wd/hub", desired_caps)
报错:
AttributeError: ‘NoneType’ object has no attribute ‘to_capabilities’
解决方法:
卸掉版本为3.1.0的appium-client,重装2.10.2版本,成功运行,继续报新的错了