Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

error Unknown failure (at android.os.Binder.execTransact(Binder.java:565)) Error while Installing APKs

Tags:

java

android

apk

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;
}
like image 303
Tsur Yohananov Avatar asked May 26 '17 13:05

Tsur Yohananov


3 Answers

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.

EDIT (Android Studio 3.0)

Disable Instant Run (Android Document)

To disable Instant Run:

  1. Open the Settings or Preferences dialog. (For Mac, Android Studio -> Preferences)
  2. Navigate to Build, Execution, Deployment > Instant Run.
  3. Uncheck the box next to Enable Instant Run.
like image 94
Anže Mur Avatar answered Nov 05 '22 14:11

Anže Mur


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.

like image 8
pravingaikwad07 Avatar answered Nov 05 '22 15:11

pravingaikwad07


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.

like image 5
visc Avatar answered Nov 05 '22 16:11

visc