I updated Android Studio to 3.5 because I had a problem with the installation of the MOT. It’s the only magazine that shows it:
The installation failed.
The application cannot be installed: INSTALLATION_PARTICIPATION_EXCEPTION
Installation error due to ZERO
This happens when you try to install the MOTCH on the device itself. If I uninstall the application from the device and run the compilation again, it will only be installed once and this error will persist on the next installation. It works fine on the emulator, but I can’t use the emulator for everything.
What I was trying to do:
I installed Linux Mint on my machine and tested AS 3.5. For some reason, everything works fine, even on devices running Android 7 and below.
Previous OS : Windows 10 1903
Current operating system : Linux Coin 19.2
I think this problem might be with Windows machines.
How can I solve this problem?
Open the Run/Debug Settings dialog box (Windows: Run > Change Settings).
Modify your request > General > Installation Options > Set Markers .
Add installation flags -r -t.
These flags mean the installation of adb -r -t apkpad
You must disable the Use libusb backend option in parameters->debugger
This problem in Android Studio occurs on devices that use API 26 (Android 8). This is due to the replacement of InstantRun, now known as ApplyChanges.
It seems that there are only two options before they repair it in the next update.
Of course it is possible to manually uninstall the application from the device before starting it from AndroidStudio.
For me, deleting the application or doing a cleaning project solves the problem. To make things less frustrating, I added a clean piece of work to debug a construction like this:
Solution No 5:
After reading the release notes about the changes in Apply, I finally found a solution: https://developer.android.com/studio/run#apply-changes-run-fallback.
Enable Run fallback to apply changes
After you have clicked Apply Changes and Restart Activity or
Apply Code Changes, Android Studio creates a new MOT and determines
whether the changes can be applied. If the changes cannot be applied to the
icon and the application of the changes may fail, Android Studio will ask you again for the
icon of your application. However, if you don’t want
to ask you over and over again, you can set Android Studio to
to automatically restart your application if the changes cannot be applied.
To enable this behavior, follow these steps:
Open the Settings or Preferences dialog box :
On Windows or Linux, select File > Settings from the menu bar.
In the Android Studio macro, select > Preferences from the menu bar.
Navigate to Build, Run, Deploy > Deploy.
Check the checkboxes to enable automatic downshift for each of the
actions to apply the changes.
Solution No 6:
The Google team reported an issue with Lineage OS at https://issuetracker.google.com/issues/139782879 :
We can play it on a LineageOS device.
It does not fully support the system call we use for DeltaInstall.
There is no obvious solution (except to remove the MOT from the build file or to delete the application).
We should have a workaround, but at this stage LineageOS will not have a DeltaInstall and will still need a slower full installation.
By doing nothing, as OP indicates, the MOT cannot be deployed on the aircraft (so the error does not appear), which will not solve the problem.
This is recorded in Android Studio 3.6.
Thank you for the review. This should be recorded in the latest versions of 3.6. The Committee agrees that the Commission should take the necessary measures to promote the use of funds.
Solution No 7:
I have the solution in the launch edit code to change the configuration to Deploy, select Default APK and set the =-r -t flag and then Apply to launch. The application works on all devices and in the emulator. I also tested in OPPO 1 plus, Samsung Tab and the emulator.
Think of the
configuration of Edit Run near the Run button in the Android studio.
Edit application > General ==> Installation options ==> Set flags
Add installation flags -r -t
-r means that an existing application needs to be replaced. -t means that test packages are allowed.
Solution No 8:
Build > Clean Project works for me. Before changing other settings, try this first.
Solution No 9:
I still have this problem after the upgrade to version 3.5. I was wondering if you and Beg had any luck with a connected device?
UPDATE: I had to make it work by installing the entire application’s MOTK in the Installation Options section of the Commissioning/Debug Configuration dialog box.
Solution No 10:
Uninstalling the application on the device solved this problem for me.