Reputation: 543
Could somebody tell me what that means?
Everything went fine, I haven't changed anyhing and it just happened, this is the code in Binder 565:
try {
res = onTransact(code, data, reply, flags);
} catch (RemoteException | RuntimeException e) {
if (LOG_RUNTIME_EXCEPTION) {
Log.w(TAG, "Caught a RuntimeException from the binder stub implementation.", e);
}
if ((flags & FLAG_ONEWAY) != 0) {
if (e instanceof RemoteException) {
Log.w(TAG, "Binder call failed.", e);
} else {
Log.w(TAG, "Caught a RuntimeException from the binder stub implementation.", e);
}
} else {
reply.setDataPosition(0);
reply.writeException(e);
}
res = true;
}
Upvotes: 38
Views: 53542
Reputation: 1545
I had this issue when I was trying to install apk on emulator and I was always getting error messages that I need to uninstall the old version of my app's apk.
I solved it like this:
1. File -> Settings -> Build, Execution, Deployment.
2. Instant Run -> disable "Enable Instant Run to hot swap code/resource changes on deploy".
3. Apply -> OK
After that you can clean the project (Build -> Clean project) and re-enable instant run to get the instant run working again.
Disable Instant Run (Android Document)
To disable Instant Run:
Upvotes: 89
Reputation: 570
I had a similar error message. In my case, it was because I changed the folder of my project. I moved the project to another folder and when I tried to install apk to my device it failed with a similar error. Deleting of data, uninstalling the old app, cleaning the project and building the new apk helped in my case.
Upvotes: 0
Reputation: 103
In my case, I cleaned the project, then rebuilt the code and it worked.
And in Mi or Xiomi
phone just enabled "INSTALL VIA USB" in developer option.
Upvotes: 3
Reputation: 485
I had similar issue. My phone space was very low. I just increased my phone space and it worked for me.
Upvotes: 1
Reputation: 15402
This crash appeared suddenly without any reason. I just restarted Android Studio and my device ; and it worked. I don't know if both solutions or just one of them is required.
Check also that there is enough space disk on your device to install the app. Actually, even if your app is 10 Mo, there might be this problem if you have 300 Mo or less available on your device.
Upvotes: 0
Reputation: 522
Unknown failure (at android.os.Binder.execTransact(Binder.java:702)) Error while Installing APK
There could be 2 Possible solutions for this error :
Solution 1: Check that you have enabled "INSTALL VIA USB" option in 'Developer Options' in Mobile (especially if you are using Xiomi devices)
Solution 2: https://stackoverflow.com/a/46102740/5582162 - Solution posted by @Mithor.
Upvotes: 8
Reputation: 31
Your solution worked with mine but the problem reoccurred on enable it back even when the app ran successfully. Then, following the Build Project documentation in Android Documentation as advised by Dhaval Jardosh, performing a clean project the app started to run with the Instant Run enabled.
Upvotes: 1
Reputation: 1
This is usually because your device and your JNI do not match. For example, your device is X86 ABI, but you use the JNI for ARM.
Upvotes: 0
Reputation: 4959
I had a similar error message. Turns out my systems and/or emulator ran out of storage space and it's couldn't install the APK. Mithor's solution revealed to out of space memory error. I was then able to enable instant run after freeing up some space.
Upvotes: 5