当前位置:   article > 正文

Appium如何解决报错:An unknown server-side error occurred while processing the command. Original error: Er

an unknown server-side error occurred while processing the command. original

Appium Automatic Server 启动报错:An unknown server-side error occurred while processing the command. Original error: Error executing adbExec.


问题描述

使用appium客户端连接小米手机失败,完整报错信息如下:
An unknown server-side error occurred while processing the command. Original error: Error executing adbExec. Original error: ‘Command ‘{已隐藏}/Library/Android/sdk/platform-tools/adb -P 5037 -s fca2117a shell settings delete global hidden_api_policy_pre_p_apps’ exited with code 255’; Stderr: ‘Exception occurred while executing ‘delete’: java.lang.SecurityException: Permission denial, must have one of: [android.permission. WRITE_SECURE_SETTINGS] at com.android.providers.settings.SettingsProvider.enforceHasAtLeastOnePermission(SettingsProvider.java:2394) at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1494) at com.android.providers.settings.SettingsProvider.mutateGlobalSetting(SettingsProvider.java:1486) at com.android.providers.settings.SettingsProvider.deleteGlobalSetting(SettingsProvider.java:1457) at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:544) at android.content.ContentProvider.call(ContentProvider.java:2700) at android.content.ContentProviderTransport.call(ContentProvider.java:634) at com.android.providers.settings.SettingsServiceMyShellCommand.deleteForUser(SettingsService.java:408) at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(SettingsService.java:282) at com.android.modules.utils.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:97) at android.os.ShellCommand.exec(ShellCommand.java:38) at com.android.providers.settings.SettingsService.onShellCommand(SettingsService.java:50) at android.os.Binder.shellCommand(Binder.java:1075) at android.os.Binder.onTransact(Binder.java:895) at android.os.Binder.execTransactInternal(Binder.java:1351) at android.os.Binder.execTransact(Binder.java:1282)’; Code: ‘255’

原因分析:

Permission denial,应该是adb连接时没有权限的问题,最近更新了手机系统,不知道问题是不是出在这里,于是尝试从USB调试里面寻找某个开启开关。

解决方案:

小米手机:打开USB调试后- 搜索栏搜索:USB调试(安全设置)
开启它。

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/花生_TL007/article/detail/552495
推荐阅读
相关标签
  

闽ICP备14008679号