Skip to content

Fix ABI selection around universal APKs - #52

Merged
titooan merged 2 commits into
mainfrom
tcampbell-published-apk-fallback
Oct 9, 2026
Merged

titooan merged 2 commits into
mainfrom
tcampbell-published-apk-fallback

Conversation

@moztcampbell

Copy link
Copy Markdown
Collaborator

If a universal APK doesn't exist when we expected one, the Download button fails. This impacts Fenix older than 143 and the Focus Beta / Release builds. These patches reword how selection works to build an ordered list and then the AppCard will do network checks that the APK actually exists before selecting and offering for Download.

At the same time, I change the default ABI preference to be the devices preferred one instead of a universal APK in order to reduce download size in the common case. A user may change settings to prefer universal APKs if they want.

This PR also shares more of the parsing code to be easier to maintain going forward.


Stack created with GitHub Stacks CLI • Give Feedback 💬

@moztcampbell
moztcampbell added this pull request to stack #54 October 8, 2026 05:27
Base automatically changed from tcampbell-picker-text-color to main October 9, 2026 10:31
The nightly and release APK directories have compatible naming schemes so use a
single parser for consistency. Add a general ArchiveApkDirectory type for both
types of listing. The nightly lists still filter the universal folders since
they might only contain AAB and not APK.

Some of the existing tests needed fixes where simulated results didn't match
the version of simulated requests.
A clean install without a preference set will default to using preferred ABI
for smaller downloads. The settings can still be used to select universal APKs
if they are preferred. An ordered list of preferred ABIs is derived from the
user setting and what is supported on device and used to pick from available
APKs.

Since APK URLs are constructed from directory names, they may not actually
exist on the server (such as if only an AAB is in the universal folder). This
patch adds a network check when populating the AppCard so it does not try (and
fail) to install a missing APK and an alternative exists.

If universal builds are preferred the user can set that setting and we will try
to use them if they exist for the target version and fallback automatically to
a non-universal APK otherwise.
@titooan
titooan force-pushed the tcampbell-published-apk-fallback branch from 8442c5f to c7562a9 Compare October 9, 2026 10:31
@titooan
titooan merged commit e5623ce into main Oct 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants