Android .apk install fail - Failed to collect certificates

In this forum we discuss the future of Ren'Py, both bug fixes and longer-term development. Pre-releases are announced and discussed here.
Post Reply
Message
Author
yozayozo
Newbie
Posts: 8
Joined: Sun Sep 19, 2021 10:15 am
Contact:

Android .apk install fail - Failed to collect certificates

#1 Post by yozayozo »

I have done the following steps:
1. downloaded latest renpy 7.4.8.
2. opened it, clicked android and installed initial files it requires (got prompted)
3. pressed SDK & create keys - installed and created key, android.keystore is present now
4. installed the .apk via adb so the logs are present
5. install fails with the following error:

[INSTALL_PARSE_FAILED_NO_CERTIFICATES: Failed collecting certificates for /data/app/vmdl648642222.tmp/base.apk: Failed to collect certificates from /data/app/vmdl648642222.tmp/base.apk using APK Signature Scheme v2: integer overflow]

I have no clue what to do. Trying to find a solution for the last 2 days now.
Succesfully installed .apk with 3.1gb and 2.1gb and 1.5gb in the near past, but now this 2.05gb .apk is failing to install and I see no clear reason as to why.

Should I perhaps try an older version of Renpy to build the .apk?

More info (could be relevant):
ADB:
- latest adb.exe (platform-tools)
- have PATH system variable C:\Users\USER\Desktop\stuff\platform-tools


Java:
- C:\Program Files\Java :
--- jdk.1.8.0_291
--- jdk.1.8.0_301
--- jdk-16.0.2
--- jre1.8.0_291
--- jre1.8.0_301

-version command returns :
openjdk version "1.8.0_302"
OpenJDK Runtime Environment (Temurin)(build 1.8.0_302-b08)
OpenJDK 64-Bit Server VM (Temurin)(build 25.302-b08, mixed mode)

Have PATH system variable -- %JAVA_HOME%\bin


Node (probably irrelevant):
v14.18.0

User avatar
PyTom
Ren'Py Creator
Posts: 16096
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Android .apk install fail - Failed to collect certificates

#2 Post by PyTom »

I don't know how you managed to install 3.1 and 2.1 GB apks - the limit is 2.0 GB, as far as I'm aware.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

yozayozo
Newbie
Posts: 8
Joined: Sun Sep 19, 2021 10:15 am
Contact:

Re: Android .apk install fail - Failed to collect certificates

#3 Post by yozayozo »

Yeah I was in awe too. But it works for some reason. Do you have any info about the certificate error? Or do you think it is the error because the apk is too large?

User avatar
PyTom
Ren'Py Creator
Posts: 16096
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Android .apk install fail - Failed to collect certificates

#4 Post by PyTom »

My guess is that it's because the apk is too large.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

yozayozo
Newbie
Posts: 8
Joined: Sun Sep 19, 2021 10:15 am
Contact:

Re: Android .apk install fail - Failed to collect certificates

#5 Post by yozayozo »

Okay after detailed researching I've found out that since 1st of August 2021 (01.08.2021.) the V2 signature scheme for android apps is mandatory. All apps / .apks created after that date are required to have it. If you look closely at what the signature does and how it operates you can now see that the limit of the apps is 2GB straight.

When before that date apps could work without it, and be bundled up to 4GB as maximum per .apk / .zip since they are the same thing. But going over the 2GB with .apk-s meant that there is a high chance that it won't install on many android devices.

TLDR: .apk-s created after 01.08.2021. must be 2GB in size or lower with V2 signature

Post Reply

Who is online

Users browsing this forum: No registered users