Closed Ziv-Barber closed 8 years ago
I don't get this error. Do you have any more details on this? Are you using the latest version of the plugin?
Thanks,
-Craig
The problem is when use the plugin with others plugins that use google play services also.
How you can replicate the problem (e.g. onesignal plugin uses Google GCM):
cordova create workshop com.yourname.workshop Workshop
cd workshop
cordova platform add android
cordova plugin add com.cmackay.plugins.googleanalytics
cordova plugin add onesignal-cordova-plugin
cordova build --debug android
The problem is that are two versions of com.google.android.gms
I solved it editing plugin.xml in all plugins that use Google Play Services and set tags <framework src="com.google.android.gms:service-name:XXX" />
to the last version (8.1.0)
https://developers.google.com/android/guides/setup
After clean gradle files:
cordova platforms rm android
cordova platforms add android
The problem is that adding the plugin google play services make 2 compilation lines inside the gradle.build file. The additional problem is that every time that you build something adding this line again into gradle.build. The work around is to edit gradle.build:
On Fri, Oct 23, 2015 at 9:21 AM, Pacotole notifications@github.com wrote:
The problem is that are two versions of com.google.android.gms
I solved it editing plugin.xml in all plugins that use Google Play Services and set tags <framework src="com.google.android.gms:service-name:XXX" /> to the last version (8.1.0)
https://developers.google.com/android/guides/setup
After clean gradle files:
cordova platforms rm android cordova platforms add android
— Reply to this email directly or view it on GitHub https://github.com/cmackay/google-analytics-plugin/issues/49#issuecomment-150495941 .
@Ziv-Barber Are you using a plugin that does not make use of the <framework>
tag as @pacotole suggested? This is the most common reason for this problem.
I am closing this. When I tested this I wasn't able to reproduce this. It appears to be the issue both @pacotole and @petarov suggested. If there are more details, feel free to reopen. Thanks!
Anyone managed to find a solution to the com.google.playservices problem?