[TIMOB-26131] Android: SDK is wrongly adding core "Google Play Services" libraries as of 7.1.0
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2018-06-26T13:41:10.000+0000 |
Affected Version/s | Release 7.1.0 |
Fix Version/s | Release 7.3.0 |
Components | Android |
Labels | android, google-play-services, sdk |
Reporter | Joshua Quick |
Assignee | Gary Mathews |
Created | 2018-06-14T19:11:28.000+0000 |
Updated | 2018-07-02T21:15:08.000+0000 |
Description
*Summary:*
As of Titanium 7.1.0, the SDK is wrongly including the following JAR files to all Android app builds...
* play-services-base-11.0.4.jar
* play-services-basement-11.0.4.jar
* play-services-location-11.0.4.jar
* play-services-tasks-11.0.4.jar
On a Mac, you can verify that the above libraries are wrongly being included by going to the following directory in Finder...
~/Library/Application Support/Titanium/mobilesdk/osx/7.x.x/android
These 4 libraries are not supposed to be there and it's preventing us from updating the "ti.playservices" module's Google Play Services libraries to a newer version (will cause a version conflict).
*Note:*
Titanum's core "geolocation" code needs a reference to the above mentioned JAR files to compile, but it doesn't require the JAR files to be included. This is because our "geolocation" code will dynamically detect the existence of the Google Play Services classes via reflection... and if they don't exist, it'll fallback to using the OS' location APIs instead. So, we need to exclude the Google Play Services JARs when packaging the SDK.
master: https://github.com/appcelerator/titanium_mobile/pull/10127
I think the PR changes are small enough to be back-ported to 7.3.0. And it will help reduce the chance of the app being multidexed unnecessarily. I don't foresee any issues. I've tested our geolocation APIs with these JARs missing and our core code correctly falls-back to the OS' location APIs. (I've talked to [~amukherjee] about this during today's meeting and he is okay with this.)
PR (7_3_X): https://github.com/appcelerator/titanium_mobile/pull/10132
*Closing ticket.* Fix verified in SDK Version
7.3.0.v20180628132121
and SDK Version:7.4.0.v20180702110619
. *FR Passed* Can no longer see the following files in the/Library/Application Support/Titanium/mobilesdk/osx/7.x.x/android
directory. * play-services-base-11.0.4.jar * play-services-basement-11.0.4.jar * play-services-location-11.0.4.jar * play-services-tasks-11.0.4.jar *Test Environment*