android studio 真机调试连接时候好好的,运行安装就掉线 Session 'app': Error Installing APKs

1 运行跑起来,准备安装时候,掉线,Session 'app': Error Installing APKs

2 有时候报提示:   Installation failed because the device "huawei-ath_tl00h-F3D7N15B04017165" disconnected


3  有时候报 :  远程主机强迫关闭了一个现有的连接。
java.io.IOException: 远程主机强迫关闭了一个现有的连接。
at sun.nio.ch.SocketDispatcher.write0(Native Method)
at sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:51)
at sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:93)
at sun.nio.ch.IOUtil.write(IOUtil.java:65)
at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:471)
at com.android.ddmlib.AdbHelper.executeRemoteCommand(AdbHelper.java:529)
at com.android.ddmlib.AdbHelper.executeRemoteCommand(AdbHelper.java:632)
at com.android.ddmlib.SplitApkInstaller.uploadApk(SplitApkInstaller.java:151)
at com.android.ddmlib.SplitApkInstaller.install(SplitApkInstaller.java:77)
at com.android.ddmlib.Device.installPackages(Device.java:930)
at com.android.tools.idea.run.tasks.SplitApkDeployTask$SplitApkInstaller.installApp(SplitApkDeployTask.java:131)
at com.android.tools.idea.run.RetryingInstaller.install(RetryingInstaller.java:86)

at com.android.tools.idea.run.tasks.SplitApkDeployTask.perform(SplitApkDeplo... (show balloon)

然后在其他手机可以运行,在模拟器也可以运行,但是换到这个华为荣耀就不行

最后发现,手机用的不是同一根数据线。一个是Tpye-c 一个是安卓,刚刚好,华为荣耀是安卓数据线

这条是可以连接上,但是安装不了,线,真是多种多种,有的线只可以充电,有的线可以连接不可以跑。有的线,什么都可以。

坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑坑

省咧号,100个坑。

网上搜索很多解决方案,还是不行,最后 换条数据线,马上就好。。。妈妈在也不用担心调试问题。

猜你喜欢

转载自blog.csdn.net/qq_33495943/article/details/79487143