2021-10-17 16:36:53:962 [Instrumentation] Caused by: java.lang.IllegalStateException: UiAutomationService android.accessibilityservice.IAccessibilityServiceClient$Stub$Proxy@63c31ebalready registered! 2021-10-17 16:36:53:962 [Instrumentation] at android.os.Parcel.createException(Parcel.java:1958) 2021-10-17 16:36:53:962 [Instrumentation] at android.os.Parcel.readException(Parcel.java:1918) 2021-10-17 16:36:53:962 [Instrumentation] at android.os.Parcel.readException(Parcel.java:1868) 2021-10-17 16:36:53:962 [Instrumentation] at android.app.IUiAutomationConnection$Stub$Proxy.connect(IUiAutomationConnection.java:255) 2021-10-17 16:36:53:963 [Instrumentation] at android.app.UiAutomation.connect(UiAutomation.java:234) 2021-10-17 16:36:53:963 [Instrumentation] at android.app.Instrumentation.getUiAutomation(Instrumentation.java:2145) 2021-10-17 16:36:53:963 [Instrumentation] at androidx.test.uiautomator.UiDevice.getUiAutomation(UiDevice.java:1129) 2021-10-17 16:36:53:963 [Instrumentation] at androidx.test.uiautomator.QueryController.<init>(QueryController.java:95) 2021-10-17 16:36:53:963 [Instrumentation] at androidx.test.uiautomator.UiDevice.<init>(UiDevice.java:109) 2021-10-17 16:36:53:963 [Instrumentation] at androidx.test.uiautomator.UiDevice.getInstance(UiDevice.java:261) 2021-10-17 16:36:53:963 [Instrumentation] at io.appium.uiautomator2.utils.Device.getUiDevice(Device.java:33) 2021-10-17 16:36:53:964 [Instrumentation] at io.appium.uiautomator2.model.internal.CustomUiDevice.<init>(CustomUiDevice.java:70) 2021-10-17 16:36:53:964 [Instrumentation] at io.appium.uiautomator2.model.internal.CustomUiDevice.getInstance(CustomUiDevice.java:80) 2021-10-17 16:36:53:964 [Instrumentation] at io.appium.uiautomator2.server.mjpeg.MjpegScreenshotStream.<clinit>(MjpegScreenshotStream.java:43) 2021-10-17 16:36:53:964 [Instrumentation] ... 32 more 2021-10-17 16:36:54:032 [Instrumentation] INSTRUMENTATION_RESULT: shortMsg=Process crashed. 2021-10-17 16:36:
Through the error information search of caused by, we know that because the uiautomator process already exists, we need to kill the process first
Solution 1:
1. Query ADB process:
adb shell ps | find "uiautomator"
2. Kill process:
adb shell kill <PID>
3. If you are prompted with “/ system/bin/sh: Kill: 1835: operation not permitted”, you need to switch ADB to root permission and kill the process
adb root
Solution 2:
Restart the phone
Similar Posts:
- Troubleshooting method for mobile phone automation: original error: the instrumentation process cannot be initialized
- Install and run Android in Androidx86 emulator – This adb server’s $ADB_VENDOR_KEYS is not set
- [Solved] appium Error: Message: Cannot set the element to ‘XXXX’. Did you interact with the correct element?
- [Solved] Stderr: ‘Failure [INSTALL_PARSE_FAILED_UNEXPECTED_EXCEPTION: Failed to parse…
- [Solved] appium Error: A new session could not be created
- The method of eliminating “more than one device and emulator” in ADB
- [Solved] Errors reported by genymotion, UI autoviewer and appium
- [Solved] Appium Error: selenium.common.exceptions.WebDriverException: Message: An unknown server-side error occurred while processing the command. Original error: Can’t stop process; it’s not currently runni…
- [Solved] Version 28 (intended for Android Pie and below) is the last version of the legacy support library
- Uiautomatorviewer.bat error reporting solution