DEV Community

Zachary Powell
Zachary Powell

Posted on

What should I do if HMS Core (APK) cannot be updated (error code 102)?

I integrated the HMS Core SDK via the Maven repository in Android Studio. During the test on a Huawei mobile phone, I was prompted to update HMS Core (APK) to the latest version. But when I tried to update it, error code 102 was displayed, indicating that HMS Core (APK) cannot be updated.

I contacted Huawei technical support personnel (you can also submit a ticket online), and provided the problem reproducing logs without any filter. They told us that the hmsrootcas.bks certificate, which is required for updating HMS Core (APK), was invalid.

image

Because the project is an Android Studio project, the technical support personnel advised us to delete the hmsrootcas.bks certificate file, build dependencies, and generate the package again according to the reference documentation.

Generally, the problem can be solved by performing the preceding steps. However, when I deleted the hmsrootcas.bks certificate file under the Assets file and integrated the SDK again, the problem still occurred no matter how many times I tried.

In response, technical support told us to download the Base SDK integrated for Eclipse to obtain the msrootcas.bks certificate file and add the file to our project. Using Base SDK 5.3.0.301 as an example, the detailed directory for obtaining the file is hmssdk-eclipse-5.3.0.301.zip/security-ssl-1.1.5.306/assets/hmsrootcas.bks.

If you encounter the same problem when you use Eclipse, delete the hmsrootcas.bks certificate file in the package and download the Assets file of the SDK to the project.

SDK download link:
https://developer.huawei.com/consumer/en/doc/development/HMSCore-Library-V5/game-sdk-download-0000001050121222-V5#ZH-CN_TOPIC_0000001050121222__section3142161417195

Top comments (0)