What Do Mobile App Installation Result Codes on Huawei Devices Mean and How to Resolve Them?

  1. The app package is invalid, incomplete, or incompatible with the operating system (result code: -2).
    Cause analysis: An invalid package is uploaded for a third-party app.
    Solution: Upload a valid app package.
  2. Insufficient storage space (result code: -4).
    Cause analysis: The storage space is insufficient for installing an app.
    Solution: Open Optimizer and tap Cleanup to free up some storage space on your phone.
  3. An app with the same package name has already been installed on the device (result code: -5).
    Cause analysis: The app cannot be installed as the package name already exists.
    Solution: Change the package name to a new one.
  4. Incompatible update (result code: -7).
    Cause analysis: The package name of the later version is the same as that of the earlier version currently installed, but their signatures are different.
    Solution: Change the signature of the later version to that of the earlier one.
  5. Incompatible app that supports ShareUid (result code: -8).
    Cause analysis: The installation failed because the signature of the to-be-installed app that supports ShareUid is different from that of the installed app that supports ShareUid.
    Solution: Ensure that the signature is the same as that of the installed app that supports ShareUid.
  6. The shared library is lost (result code: -9).
    Cause analysis: The Google Maps library that the app depends on does not exist. As a result, the app installation failed.
    Solution: It is recommended that you integrate HMS Core into your app to avoid such dependency issues.
  7. An element name of the to-be-installed app is the same as that of an installed app (result code: -13).
    Cause analysis: The ContentProvider defined in the app is the same as that of an installed app.
    Perform the following steps to find the conflict: View logs and check the installation failure callback information. Run the adb command to obtain all ContentProvider definitions on the device, and find the app that caused the conflict. adb shell dumpsys package providers >d:/temp/provider.txt Solution:Uninstall the conflicting app or resolve the conflict.
  8. The app is incompatible with the CPU of the device (result code: -113 or -16).Cause analysis: Adaptations for specific CPU versions were not performed when the app was packaged.Solution: Adapt the app for the CPU version of the device in question.
  9. App verification timed out (result code: -21), and app verification failed (result code: -22). Cause analysis: When the app was being automatically verified by Google Play, the network connection timed out. Usually, the preceding process is not triggered unless Google Play has been updated by the user or by a downloaded app, which leads to verification timeout. Solution: On the device, go to Settings > Apps > Google Play Services and tap DISABLE on the App info page, or go to Settings > Apps > Google Play Services Updater and tap Uninstall updates in the upper right corner. Then click FORCE STOP (if available) to deactivate the app if it is still displayed in the app list. On the device, ensure that Google Play Protect is disabled.
  10. The app package failed to be installed because a later version has been installed (result code: -25). Cause analysis: Android devices allow for the creation of multiple user accounts. A non-owner account may have downloaded and installed a later version of the app in PrivateSpace for testing purposes. If so, the installation will fail. Solution: Check whether a later version of the app is installed in PrivateSpace by a non-owner account. If so, uninstall the app and install it again.
  11. Parsing failed (result code: -102). Cause analysis: An error occurred when generating the package, causing parsing to fail. Solution: Contact the technical support of the corresponding channel to check logs to locate the download path, download the APK again using a browser, and then install the APK in ADB mode to check whether the error occurs again.
  12. The app package does not contain any certificates (result code: -103) Cause analysis: The app package is for Early Access targeting specific users and does not contain any certificates. Solution: Add a certificate to the app package.
  13. Unknown error (result code: -111).Cause analysis: The device is a TD Tech dual-system policing terminal and is customized to limit app installation. Solution: Instruct users to contact TD Tech for assistance.




Lead Developer Advocate for Huawei AppGallery | He/Him | All views are my own and do not represent the views of Huawei

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

MLH Local Hack Day, Just A Week Left To Go!

Want to know Workday ERP- This will help you

Rolling dice; another look into TDD

Flexibility of defining var in golang

Apache Kafka and MQTT (Part 4 of 5) — Mobility Services + Transportation

Project: launching a functional CMS website in 72h

Aldrin Week in Review

Learn Swift Fundamentals by preparing for Job Interview, Questions 131~ 132 For Delegate

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Zachary Powell

Zachary Powell

Lead Developer Advocate for Huawei AppGallery | He/Him | All views are my own and do not represent the views of Huawei

More from Medium

Common errors found when generating Android certificates (and how to fix them!)

Learn to perform Asynchronous operations in Android using RxJava in 10 mins

Android Huawei push notification with deep linking

Using custom keystore in android gradle