[mozversion] Cannot get version info of any firefox APK
Categories
(Testing :: Mozbase, defect, P3)
Tracking
(Not tracked)
People
(Reporter: sparky, Unassigned)
References
Details
I am currently trying to get the version info for all of our android browsers but I can't seem to use a APK file for this. Based on the mozversion tests, it requires a zip file containing other files alongside the APK. Here's what I see when I try using the firefox APKs:
[task 2019-10-02T18:45:16.838Z] 18:44:16 INFO - mozversion Unable to find application.ini
[task 2019-10-02T18:45:16.838Z] 18:44:16 INFO - mozversion Unable to find platform.ini
I noticed that the zip requirement is not mentioned anywhere in the docs: https://firefox-source-docs.mozilla.org/mozbase/mozversion.html
And the docs use path/to/firefox.apk
which is not a zip file.
Either the docs should be fixed to note this or this functionality should be added.
Comment 1•5 years ago
|
||
Well, we have https://taskcluster-artifacts.net/LkjubSL5QFGNfuTZVGDxjg/0/public/build/target.json even though that is still fennec specific I assume it will change some day. Regarding apks, they are actually specially signed zip files.
Looking at geckoview-androidTest.apk
unzipping that gives assets/omni.ja which is a jar (another zip file). Unzipping that gives
./modules/AppConstants.jsm: MOZ_APP_VERSION: "71.0a1",
./modules/AppConstants.jsm: MOZ_APP_VERSION_DISPLAY: "71.0a1",
You can do the same for geckoview_example.apk where the MOZ_APP_VERSION is in modules/AppConstants.jsm again.
snorp: Do you have any other recommendation for replacing the application.ini in the old fennec target.apk?
No, I think what you have here is about the best we can do currently. That should work in GeckoView apps as well.
Reporter | ||
Comment 3•5 years ago
|
||
Ah ok, I didn't know the apks were actually zip files! But mozversion can't extract that "MOZ_APP_VERSION" information from it at this stage, right?
Comment 4•5 years ago
|
||
Right. We'll need to update it to handle unzipping the apk then finding and unzipping the omni.ja then getting the information from modules/AppConstants.jsm.
Updated•5 years ago
|
Updated•4 years ago
|
Comment 5•10 months ago
|
||
I'm experiencing the same issue. It seems like the version information for Firefox Combo APK is not readily available or accessible. If anyone has a workaround or solution, please share. Thank you!
Description
•