Pushwoosh/pushwoosh-appcelerator-titanium

Firebase Analytics conflict

Closed this issue · 5 comments

I had to add the string google_app_id to my string.xml files, and because of that there was an error of string already added because your file gen_google_services_config.js was appending it from the google_services.json file.

When I comment the line bellow the app runs with no problems:

			//append("google_app_id", query(client, "client_info.mobilesdk_app_id"));
			
			var oauth_clients_list = client["oauth_client"];`

I'm using 5.19.1.

wfhm commented

Hello @platanus-xx,

When I comment the line bellow the app runs with no problems

It is a bit unclear whether there is an issue with the Pushwoosh module (or with Firebase Analytics), or it is just a warning for us, so could you please clarify what exactly you meant?

Hey @wfhm, thanks for the reply.
So, as I was installing and configuring the titanium-firebase-analytics I had to add the key google_app_id to my string.xml file.
But it conflicted with the key appended by the file gen_google_services_config.js from the PushWoosh Module.
Therefore I had to comment the append above for it to work.
I've opened this issue in hope that you could just check the existence of the key before appending it.

wfhm commented

@platanus-xx,

Thanks for the feedback! Please let me pull some time to check if we can do anything with it, I will come back to you as soon as there is any news.

wfhm commented

Hey @platanus-xx,

Should be fixed with the latest release.

Hello @wfhm
I've tested the new module.
The pushes are happening as expected! Perfect.
But this issue of conflicting key is not solved yet.
I noticed you changed the append to a try/catch. But it's not a runtime error issue. It's a compiler error, as shown bellow:

[ERROR] Failed to package application: [ERROR] [ERROR] (skipping file '.keep' due to ANDROID_AAPT_IGNORE pattern '.*') [ERROR] /Users/thales/Developer/git/pinion/app/build/android/res/values/values.xml:246: error: Resource entry google_app_id is already defined. [ERROR] /Users/thales/Developer/git/pinion/app/build/android/res/values/googleservices.xml:8: Originally defined here.

I've commented the try/catch again and had no issues compiling.
But I'm commenting here so you can reopen the issue for further investigations.