Page 1 of 2

Android Build Error

Posted: Wed Jan 23, 2019 3:40 pm
by Deon

Hi
I am trying to create an apk.
I created a backup of an app A and then created a new app B from the backup of A.

When I try and compile the APK, I get this error.....
(Bear in mind App A compiles to APK just fine, so why does the exact same app bomb with this error???

Build error

Most likely build error cause:

(node:26647) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: /app/platforms/android/gradlew: Command failed with exit code 1 Error output:
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

FAILURE: Build failed with an exception.


Android Build Error

Posted: Wed Jan 23, 2019 9:20 pm
by Serhii Kulibaba

Hello Deon,

  1. Please check your Push Notification settings, did you set a new set of project ID, json config files and so on for the new app?

  2. Do you use Barcode Scanner in your app? If yes, please disable it and run the build again


Android Build Error

Posted: Thu Jan 24, 2019 10:56 am
by Deon

Hi Serhii

Thank you. I did create a new firebase project and also created new database and with new push notification api.
I only use app to receive push messages. I do not send messages, so there is no reference to push api key from the app. Project db ID is set to new db as well.

I dont use barcode scanner in app.


Android Build Error

Posted: Thu Jan 24, 2019 11:57 am
by Galyna Abramovych

Deon,

Generally, to troubleshoot issues with pushes, first of all, you need to check if the settings for Push for Android in your project have been configured correctly and with all the steps as described in our documentation: https://docs.appery.io/docs/pushnotif...

You should also know that for the correct functioning of the Push option, the Device and Notification Cordova plugins should be enabled in the App Settings of your project (I have no doubts you know it, though).

As for the error that you get with your binary build, please increase the Target SDK version in your Android binary settings to 8.1 and try again.
One more thing that can help resolve the issue:
Removing the "SENDER_ID" property from your PushPlugin, generating new JSON config files for Firebase, and uploading them to Appery.io platform: https://docs.appery.io/docs/pushnotif....

Please let us know the result.

PS
Such an error might also indicate that you have two plugins enabled in your app that are conflicting.
To troubleshoot, uncheck all the plugins until the build successes then you add plugins one by one with the build checks to understand what plugins give you this error.
You can find all the plugins you are using now in your App Settings interface.


Android Build Error

Posted: Sun Jan 27, 2019 3:08 pm
by Deon

Thank you for your reply.

Quite a while ago I brought it to Appery's attention that the Push Services in the Server backend loses its settings for no reason. The uploaded certificates would simply vanish. This issue was acknowledged and fixed by Appery support.

It seems this issue has returned. The Google Services JSON file as well as the Firebase AdminSDK file is disappearing by itself after adding it to Push Settings.

I then created brand new Firebase files and uploaded, just for good measure. For now I am able to create the APK. I will let you know if the settings reset again.


Android Build Error

Posted: Sun Jan 27, 2019 3:17 pm
by Deon

Ok, It continually loses it settings. I pop the files in. I compile APK fine. Next compile settings are gone and I have to uploaded the Firebase files again. Please can you check why the settings keep getting lost.


Android Build Error

Posted: Sun Jan 27, 2019 3:29 pm
by Deon

Now its not retaining the settings at all. Why is there no confirmation that settings are saved. Maybe provide a button to click to save settings?
To top it, I cant use my existing firebase files that I created. I have to create new ones everytime the settings are lost.

This is de-ja-vu.


Android Build Error

Posted: Mon Jan 28, 2019 8:19 am
by Serhii Kulibaba

Could you please share your application with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a and provide us with it's name?

JSON configs are not included in the app backup, because of security reasons. Please generate a new pair of them for each your application (even, created from the backup)


Android Build Error

Posted: Thu Feb 07, 2019 1:15 pm
by Chris6743166

I'm getting this issue too.

Background to the problem, I need to make manual small changes to config.xml during development. Once ready to build the release version, clicking the 'release' checkbox causes the push JSON files to be lost from the push settings.

Deleting and regenerating config.xml does not resolve the problem. The only solution appears to be repeatedly closing and reopening the entire builder once config.xml and the push settings have been restored, though it appears this sometimes has to be done repeatedly.


Android Build Error

Posted: Thu Feb 07, 2019 2:48 pm
by Galyna Abramovych

Chris,

Could you please share your application with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a and provide us with its name?