Fatal error in building the app in Sidekick


#1

Hi there!

I use sidekick in order to build the app. I have connected Firebase as backend service.
Last I’ve installed are the plugins mapbox and geolocation. After that I got the error during the run of the app on my smartphone:

[17-11-24 12:30:32.167] (Info) FAILURE: Build failed with an exception.
[17-11-24 12:30:32.171] (Info) * What went wrong:
[17-11-24 12:30:32.173] (Info) Execution failed for task ':processF0F1F2F3DebugGoogleServices'.
[17-11-24 12:30:32.175] (Info) > Please fix the version conflict either by updating the version of the google-services plugin (information about the latest version is available at https://bintray.com/android/android-tools/com.google.gms.google-services/) or updating the version of com.google.android.gms to 11.2.2.
[17-11-24 12:30:32.177] (Info) * Try:
[17-11-24 12:30:32.179] (Info) Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
[17-11-24 12:30:32.194] (Info) Command ./gradlew failed with exit code 1
[17-11-24 12:30:32.197] (Info) bc_94a57ecf1b9d0abe99536fb01c06c9306905bce1_NuSzucLzkiDaSgLqmF
[17-11-24 12:30:32.201] (Error) Error detected during LiveSync on 0aef245f02b5b0dc for C:\Users\Nikita\nativescript-plugin-firebase-demo\Firebase. Error: Build failed.
[17-11-24 12:30:32.205] (Info) Stopped LiveSync on 0aef245f02b5b0dc for C:\Users\Nikita\nativescript-plugin-firebase-demo\Firebase.
[17-11-24 12:30:32.215] (Error) Couldn't enable debugging for 0aef245f02b5b0dc, Error: Couldn't enable debugging for 0aef245f02b5b0dc at Errors.fail (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\common\errors.js:125:28) at Errors.failWithoutHelp (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\common\errors.js:133:21) at LiveSyncService.<anonymous> (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:225:30) at Generator.next (<anonymous>) at C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:13:71 at new Promise (<anonymous>) at __awaiter (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:9:12) at LiveSyncService.enableDebuggingCoreWithoutWaitingCurrentAction (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:222:16) at LiveSyncService.<anonymous> (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:262:25) at Generator.next (<anonymous>)
 DEVICES 1  OUTPUT 4

I tried to remove the plugins mapbox and geolocation but the error is the same. I also got the information about the error from Firebase:

Exception java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{org.nativescript.firebasedemo/com.tns.NativeScriptActivity}: java.lang.NullPointerException: Attempt to read from field 'int com.tns.Runtime.currentObjectId' on a null object reference
android.app.ActivityThread.performLaunchActivity (ActivityThread.java:2327)
android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:2476)
android.app.ActivityThread.-wrap11 (ActivityThread.java)
android.app.ActivityThread$H.handleMessage (ActivityThread.java:1344)
android.os.Handler.dispatchMessage (Handler.java:102)
android.os.Looper.loop (Looper.java:148)
android.app.ActivityThread.main (ActivityThread.java:5417)
java.lang.reflect.Method.invoke (Method.java)
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:726)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:616)
arrow_drop_down
Caused by java.lang.NullPointerException: Attempt to read from field 'int com.tns.Runtime.currentObjectId' on a null object reference
com.tns.Runtime.initInstance (Runtime.java:601)
com.tns.NativeScriptActivity.<init> (NativeScriptActivity.java:7)
java.lang.Class.newInstance (Class.java)
android.app.Instrumentation.newActivity (Instrumentation.java:1067)
android.app.ActivityThread.performLaunchActivity (ActivityThread.java:2317)
android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:2476)
android.app.ActivityThread.-wrap11 (ActivityThread.java)
android.app.ActivityThread$H.handleMessage (ActivityThread.java:1344)
android.os.Handler.dispatchMessage (Handler.java:102)
android.os.Looper.loop (Looper.java:148)
android.app.ActivityThread.main (ActivityThread.java:5417)
java.lang.reflect.Method.invoke (Method.java)
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:726)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:616)

I’m quite new in nativescript and sidekick, so I just don’t know what to do. I tried to google this error but without the success. I would be appreciate for your help.


#2

@nukulele
Can you share your
App.gradle file? (app_resources/android/app.gradle)


#3

Yes, please see it below:


android {  
  defaultConfig {  
    generatedDensities = []
    // added these:
    multiDexEnabled true
    applicationId "org.nativescript.firebasedemo"
  }

  dexOptions {
    javaMaxHeapSize "4g"
  }

  aaptOptions {  
    additionalParameters "--no-version-vectors"  
  }
}

def settingsGradlePath = "$projectDir/../../app/App_Resources/Android/settings.gradle";
def settingsGradleFile = new File(settingsGradlePath);
if(settingsGradleFile.exists())
{
    apply from: settingsGradleFile;
}

#4

@nukulele

project.ext {
    googlePlayServicesVersion = "11.2.2"
  }

add this at the same level of defaultConfig

android {  
  defaultConfig {  
    generatedDensities = []
    // added these:
    multiDexEnabled true
    applicationId "org.nativescript.firebasedemo"
  }
project.ext {
    googlePlayServicesVersion = "11.2.2"
  }

  dexOptions {
    javaMaxHeapSize "4g"
  }

  aaptOptions {  
    additionalParameters "--no-version-vectors"  
  }
}

#5

Thank you for your reply!

But after that I’ve got the new error, please see the log below:


[17-11-24 18:59:31.942] (Info) Version: 1.0.1-v.2017.11.16.1
[17-11-24 18:59:32.187] (Info) Checking for updates...
[17-11-24 18:59:36.902] (Info) Dependencies versions: NodeJS: 8.9.0, npm: 5.5.1, NativeScript CLI: 3.3.0.
[17-11-24 18:59:37.549] (Info) No updates available.
[17-11-24 18:59:38.849] (Info) Loaded CLI extension nativescript-cloud, version 1.0.0.
[17-11-24 18:59:38.857] (Info) Loaded CLI extension nativescript-starter-kits, version 0.3.4.
[17-11-24 18:59:41.174] (Info) Devices service initialized.
[17-11-24 18:59:54.866] (Info) App with path: C:\Users\Nikita\nativescript-plugin-firebase-demo\Firebase was opened.
[17-11-24 19:00:04.171] (Info) Build started.
[17-11-24 19:00:06.499] (Info) Prepare step started.
[17-11-24 19:00:06.894] (Info) Prepare step completed.
[17-11-24 19:00:08.218] (Info) Upload step started.
[17-11-24 19:00:32.071] (Info) Upload step completed.
[17-11-24 19:00:32.771] (Info) Build step started.
[17-11-24 19:00:38.509] (Info) GRADLE_USER_HOME is /opt/docker_shared/94a57ecf1b9d0abe99536fb01c06c9306905bce1.gradle
[17-11-24 19:00:38.512] (Info) android Build Tooling revision 2017.11.20.1r
[17-11-24 19:00:38.517] (Info) Build Tooling Hostname a314630eb7ac
[17-11-24 19:00:38.522] (Info) Unzip Project Files
[17-11-24 19:00:40.009] (Info) Executing before-prepare hook from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/hooks/before-prepare/nativescript-plugin-firebase.js
[17-11-24 19:00:40.014] (Info) Preparing project...
[17-11-24 19:00:40.017] (Info) Project successfully prepared (android)
[17-11-24 19:00:40.022] (Info) Executing after-prepare hook from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/hooks/after-prepare/firebase-build-gradle.js
[17-11-24 19:00:40.027] (Info) Configure firebase
[17-11-24 19:00:40.032] (Info) Executing after-prepare hook from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/hooks/after-prepare/firebase-copy-google-services.js
[17-11-24 19:00:40.034] (Info) Copy /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/app/App_Resources/Android/google-services.json to /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/google-services.json.
[17-11-24 19:00:40.039] (Info) Executing after-prepare hook from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/hooks/after-prepare/nativescript-plugin-firebase.js
[17-11-24 19:00:40.042] (Info) Building project...
[17-11-24 19:00:40.044] (Info) Gradle build...
[17-11-24 19:00:54.999] (Info) :config phase:  createDefaultIncludeFiles
[17-11-24 19:00:55.014] (Info) \t+found plugins: nativescript-plugin-firebase
[17-11-24 19:00:55.037] (Info) \t+found plugins: nativescript-geolocation
[17-11-24 19:00:55.042] (Info) \t+found plugins: nativescript-mapbox
[17-11-24 19:00:55.044] (Info) \t+found plugins: tns-core-modules-widgets
[17-11-24 19:00:55.049] (Info) :config phase:  createPluginsConfigFile
[17-11-24 19:00:55.054] (Info) \t Creating product flavors include.gradle file in /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations folder...
[17-11-24 19:00:55.059] (Info) \t Applying settings from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/app/App_Resources/Android/settings.json
[17-11-24 19:00:55.064] (Info) :config phase:  pluginExtend
[17-11-24 19:00:55.067] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/nativescript-plugin-firebase/include.gradle
[17-11-24 19:00:55.069] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/nativescript-geolocation/include.gradle
[17-11-24 19:00:55.072] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/nativescript-mapbox/include.gradle
[17-11-24 19:00:56.528] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/tns-core-modules-widgets/include.gradle
[17-11-24 19:00:56.530] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/include.gradle
[17-11-24 19:00:56.530] (Info) :config phase:  addAarDependencies
[17-11-24 19:00:56.533] (Info) \t+adding dependency: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/libs/aar/widgets-release.aar
[17-11-24 19:00:56.535] (Info) \t+adding dependency: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/libs/aar/firebase-release.aar
[17-11-24 19:01:15.969] (Info) Running full build
[17-11-24 19:01:15.974] (Info) finished with reading lines with js files
[17-11-24 19:01:24.900] (Info) Exception in thread \"main\"
[17-11-24 19:01:24.908] (Info) java.lang.IllegalArgumentException: Class com.google.android.gms.common.internal.zzae conflict: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/build/intermediates/exploded-aar/com.google.android.gms/play-services-base/11.4.0/jars/classes.jar and /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/build/intermediates/exploded-aar/com.google.android.gms/play-services-base/11.2.2/jars/classes.jar
[17-11-24 19:01:24.918] (Info) \tat com.telerik.metadata.ClassRepo.addToCache(ClassRepo.java:21)
[17-11-24 19:01:24.920] (Info) \tat com.telerik.metadata.Builder.build(Builder.java:38)
[17-11-24 19:01:24.925] (Info) \tat com.telerik.metadata.Generator.main(Generator.java:44)
[17-11-24 19:01:24.928] (Info) FAILURE: Build failed with an exception.
[17-11-24 19:01:24.930] (Info) * What went wrong:
[17-11-24 19:01:24.933] (Info) Execution failed for task ':buildMetadata'.
[17-11-24 19:01:24.938] (Info) > Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 1
[17-11-24 19:01:24.940] (Info) * Try:
[17-11-24 19:01:24.943] (Info) Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
[17-11-24 19:01:26.436] (Info) Command ./gradlew failed with exit code 1
[17-11-24 19:01:26.441] (Info) # build android
[17-11-24 19:01:26.444] (Info) ┌─────────┬──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
[17-11-24 19:01:26.446] (Info) │ Usage   │ Synopsis                                                                                                                                                                                                                             │
[17-11-24 19:01:26.449] (Info) │ General │ $ tns build android [--compileSdk <API Level>] [--key-store-path <File Path> --key-store-password <Password> --key-store-alias <Name> --key-store-alias-password <Password>] [--release] [--static-bindings] [--copy-to <File Path>] │
[17-11-24 19:01:26.451] (Info) └─────────┴──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
[17-11-24 19:01:26.456] (Info) Builds the project for Android and produces an APK that you can manually deploy on device or in the native emulator.
[17-11-24 19:01:26.456] (Info) ### Options
[17-11-24 19:01:26.459] (Info) * --compileSdk - Sets the Android SDK that will be used to build the project.
[17-11-24 19:01:26.464] (Info) * --release - If set, produces a release build. Otherwise, produces a debug build. When set, you must also specify the --key-store-* options.
[17-11-24 19:01:26.464] (Info) * --key-store-path - Specifies the file path to the keystore file (P12) which you want to use to code sign your APK. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
[17-11-24 19:01:26.469] (Info) * --key-store-password - Provides the password for the keystore file specified with --key-store-path. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
[17-11-24 19:01:26.471] (Info) * --key-store-alias - Provides the alias for the keystore file specified with --key-store-path. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
[17-11-24 19:01:26.471] (Info) * --key-store-alias-password - Provides the password for the alias specified with --key-store-alias-password. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
[17-11-24 19:01:26.474] (Info) * --copy-to - Specifies the file path where the built .apk will be copied. If it points to a non-existent directory, it will be created. If the specified value is directory, the original file name will be used.
[17-11-24 19:01:26.476] (Info) ### Attributes
[17-11-24 19:01:26.479] (Info) <API Level> is a valid Android API level. For example: 22, 23.
[17-11-24 19:01:26.484] (Info) Exception in thread \"main\" java.lang.IllegalArgumentException: Class com.google.android.gms.common.internal.zzae conflict: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/build/intermediates/exploded-aar/com.google.android.gms/play-services-base/11.4.0/jars/classes.jar and /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/build/intermediates/exploded-aar/com.google.android.gms/play-services-base/11.2.2/jars/classes.jar
[17-11-24 19:01:26.486] (Info) \tat com.telerik.metadata.ClassRepo.addToCache(ClassRepo.java:21)
[17-11-24 19:01:26.489] (Info) \tat com.telerik.metadata.Builder.build(Builder.java:38)
[17-11-24 19:01:26.499] (Info) \tat com.telerik.metadata.Generator.main(Generator.java:44)
[17-11-24 19:01:26.501] (Info) FAILURE: Build failed with an exception.
[17-11-24 19:01:26.504] (Info) * What went wrong:
[17-11-24 19:01:26.509] (Info) Execution failed for task ':buildMetadata'.
[17-11-24 19:01:26.516] (Info) > Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 1
[17-11-24 19:01:26.519] (Info) * Try:
[17-11-24 19:01:26.521] (Info) Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
[17-11-24 19:01:26.524] (Info) Command ./gradlew failed with exit code 1
[17-11-24 19:01:26.526] (Info) bc_94a57ecf1b9d0abe99536fb01c06c9306905bce1_ZU2XdtsvlqcbHhphet
[17-11-24 19:01:28.001] (Error) Error detected during LiveSync on 0aef245f02b5b0dc for C:\Users\Nikita\nativescript-plugin-firebase-demo\Firebase. Error: Build failed.
[17-11-24 19:01:28.014] (Info) Stopped LiveSync on 0aef245f02b5b0dc for C:\Users\Nikita\nativescript-plugin-firebase-demo\Firebase.
[17-11-24 19:01:28.016] (Error) Couldn't enable debugging for 0aef245f02b5b0dc, Error: Couldn't enable debugging for 0aef245f02b5b0dc
    at Errors.fail (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\common\errors.js:125:28)
    at Errors.failWithoutHelp (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\common\errors.js:133:21)
    at LiveSyncService.<anonymous> (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:225:30)
    at Generator.next (<anonymous>)
    at C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:13:71
    at new Promise (<anonymous>)
    at __awaiter (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:9:12)
    at LiveSyncService.enableDebuggingCoreWithoutWaitingCurrentAction (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:222:16)
    at LiveSyncService.<anonymous> (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:262:25)
    at Generator.next (<anonymous>)

I tried to remove android platform but it gave me this:


C:\Users\Nikita\nativescript-plugin-firebase-demo\Firebase>tns platform remove a
ndroid
Gradle build...
Exception in thread "main" java.util.zip.ZipException: error in opening zip file

        at java.util.zip.ZipFile.open(Native Method)
        at java.util.zip.ZipFile.<init>(ZipFile.java:225)
        at java.util.zip.ZipFile.<init>(ZipFile.java:155)
        at java.util.zip.ZipFile.<init>(ZipFile.java:169)
        at org.gradle.wrapper.Install.unzip(Install.java:215)
        at org.gradle.wrapper.Install.access$600(Install.java:27)
        at org.gradle.wrapper.Install$1.call(Install.java:75)
        at org.gradle.wrapper.Install$1.call(Install.java:48)
        at org.gradle.wrapper.ExclusiveFileAccessManager.access(ExclusiveFileAcc
essManager.java:69)
        at org.gradle.wrapper.Install.createDist(Install.java:48)
        at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:107)
        at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:61)
Command gradlew.bat failed with exit code 1
# platform remove

┌───────┬──────────┐
│ Usage │ Synopsis │
│       │
└───────┴──────────┘

General | $ tns platform remove android

Removes the selected platform from the platforms that the project currently targ
ets. After removing the target platform, you can no longer build and deploy your
 app on devices which run on the platform.

I tried to do it manually but the problem is still here.


#6

if you have git bash,
then do
rm -rf platforms from your project root


#7

Git bash works and I’ve removed platform android but it doesn’t solve the problem. Are there any possible solutions or I have to start from the very beginning?


#8

do you get the same error after removing and adding platform?


#9

Yes, absolutely the same


[17-11-25 12:45:47.152] (Info) Build started.
[17-11-25 12:45:50.781] (Info) Prepare step started.
[17-11-25 12:45:51.539] (Info) Prepare step completed.
[17-11-25 12:45:52.784] (Info) Upload step started.
[17-11-25 12:46:06.683] (Info) Upload step completed.
[17-11-25 12:46:07.548] (Info) Build step started.
[17-11-25 12:46:11.799] (Info) GRADLE_USER_HOME is /opt/docker_shared/94a57ecf1b9d0abe99536fb01c06c9306905bce1.gradle
[17-11-25 12:46:11.802] (Info) android Build Tooling revision 2017.11.20.1r
[17-11-25 12:46:11.804] (Info) Build Tooling Hostname e24b075b164c
[17-11-25 12:46:11.804] (Info) Unzip Project Files
[17-11-25 12:46:13.177] (Info) Executing before-prepare hook from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/hooks/before-prepare/nativescript-plugin-firebase.js
[17-11-25 12:46:13.187] (Info) Preparing project...
[17-11-25 12:46:13.192] (Info) Project successfully prepared (android)
[17-11-25 12:46:13.194] (Info) Executing after-prepare hook from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/hooks/after-prepare/firebase-build-gradle.js
[17-11-25 12:46:13.197] (Info) Configure firebase
[17-11-25 12:46:13.199] (Info) Executing after-prepare hook from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/hooks/after-prepare/firebase-copy-google-services.js
[17-11-25 12:46:13.202] (Info) Copy /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/app/App_Resources/Android/google-services.json to /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/google-services.json.
[17-11-25 12:46:13.204] (Info) Executing after-prepare hook from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/hooks/after-prepare/nativescript-plugin-firebase.js
[17-11-25 12:46:13.207] (Info) Building project...
[17-11-25 12:46:13.209] (Info) Gradle build...
[17-11-25 12:46:28.156] (Info) :config phase:  createDefaultIncludeFiles
[17-11-25 12:46:28.161] (Info) \t+found plugins: nativescript-plugin-firebase
[17-11-25 12:46:28.166] (Info) \t+found plugins: nativescript-geolocation
[17-11-25 12:46:28.168] (Info) \t+found plugins: nativescript-mapbox
[17-11-25 12:46:28.173] (Info) \t+found plugins: tns-core-modules-widgets
[17-11-25 12:46:28.176] (Info) :config phase:  createPluginsConfigFile
[17-11-25 12:46:28.181] (Info) \t Creating product flavors include.gradle file in /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations folder...
[17-11-25 12:46:28.183] (Info) \t Applying settings from /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/app/App_Resources/Android/settings.json
[17-11-25 12:46:28.188] (Info) :config phase:  pluginExtend
[17-11-25 12:46:28.193] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/nativescript-plugin-firebase/include.gradle
[17-11-25 12:46:29.972] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/nativescript-geolocation/include.gradle
[17-11-25 12:46:29.974] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/nativescript-mapbox/include.gradle
[17-11-25 12:46:29.979] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/tns-core-modules-widgets/include.gradle
[17-11-25 12:46:29.984] (Info) \t+applying configuration from: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/configurations/include.gradle
[17-11-25 12:46:29.994] (Info) :config phase:  addAarDependencies
[17-11-25 12:46:29.997] (Info) \t+adding dependency: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/libs/aar/widgets-release.aar
[17-11-25 12:46:29.997] (Info) \t+adding dependency: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/libs/aar/firebase-release.aar
[17-11-25 12:46:46.169] (Info) Running full build
[17-11-25 12:46:47.919] (Info) finished with reading lines with js files
[17-11-25 12:46:57.426] (Info) Exception in thread \"main\"
[17-11-25 12:46:57.428] (Info) java.lang.IllegalArgumentException: Class com.google.android.gms.auth.account.WorkAccountApi conflict: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/build/intermediates/exploded-aar/com.google.android.gms/play-services-auth-base/11.6.0/jars/classes.jar and /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/build/intermediates/exploded-aar/com.google.android.gms/play-services-auth-base/11.2.2/jars/classes.jar
[17-11-25 12:46:57.431] (Info) \tat com.telerik.metadata.ClassRepo.addToCache(ClassRepo.java:21)
[17-11-25 12:46:57.431] (Info) \tat com.telerik.metadata.Builder.build(Builder.java:38)
[17-11-25 12:46:57.433] (Info) \tat com.telerik.metadata.Generator.main(Generator.java:44)
[17-11-25 12:46:57.436] (Info) FAILURE: Build failed with an exception.
[17-11-25 12:46:57.436] (Info) * What went wrong:
[17-11-25 12:46:57.438] (Info) Execution failed for task ':buildMetadata'.
[17-11-25 12:46:57.441] (Info) > Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 1
[17-11-25 12:46:57.446] (Info) * Try:
[17-11-25 12:46:57.446] (Info) Run with
[17-11-25 12:46:57.451] (Info) --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
[17-11-25 12:46:57.453] (Info) Command ./gradlew failed with exit code 1
[17-11-25 12:46:57.453] (Info) # build android
[17-11-25 12:46:57.456] (Info) ┌─────────┬──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
[17-11-25 12:46:57.458] (Info) │ Usage   │ Synopsis                                                                                                                                                                                                                             │
[17-11-25 12:46:57.461] (Info) │ General │ $ tns build android [--compileSdk <API Level>] [--key-store-path <File Path> --key-store-password <Password> --key-store-alias <Name> --key-store-alias-password <Password>] [--release] [--static-bindings] [--copy-to <File Path>] │
[17-11-25 12:46:57.463] (Info) └─────────┴──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
[17-11-25 12:46:57.466] (Info) Builds the project for Android and produces an APK that you can manually deploy on device or in the native emulator.
[17-11-25 12:46:57.466] (Info) ### Options
[17-11-25 12:46:57.476] (Info) * --compileSdk - Sets the Android SDK that will be used to build the project.
[17-11-25 12:46:57.478] (Info) * --release - If set, produces a release build. Otherwise, produces a debug build. When set, you must also specify the --key-store-* options.
[17-11-25 12:46:57.481] (Info) * --key-store-path - Specifies the file path to the keystore file (P12) which you want to use to code sign your APK. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
[17-11-25 12:46:57.483] (Info) * --key-store-password - Provides the password for the keystore file specified with --key-store-path. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
[17-11-25 12:46:57.486] (Info) * --key-store-alias - Provides the alias for the keystore file specified with --key-store-path. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
[17-11-25 12:46:57.488] (Info) * --key-store-alias-password - Provides the password for the alias specified with --key-store-alias-password. You can use the --key-store-* options along with --release to produce a signed release build. You need to specify all --key-store-* options.
[17-11-25 12:46:57.488] (Info) * --copy-to - Specifies the file path where the built .apk will be copied. If it points to a non-existent directory, it will be created. If the specified value is directory, the original file name will be used.
[17-11-25 12:46:57.491] (Info) ### Attributes
[17-11-25 12:46:57.493] (Info) <API Level> is a valid Android API level. For example: 22, 23.
[17-11-25 12:46:57.493] (Info) Exception in thread \"main\" java.lang.IllegalArgumentException: Class com.google.android.gms.auth.account.WorkAccountApi conflict: /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/build/intermediates/exploded-aar/com.google.android.gms/play-services-auth-base/11.6.0/jars/classes.jar and /mnt/storage/builds/_/94a57ecf1b9d0abe99536fb01c06c9306905bce1/Firebase/platforms/android/build/intermediates/exploded-aar/com.google.android.gms/play-services-auth-base/11.2.2/jars/classes.jar
[17-11-25 12:46:57.496] (Info) \tat com.telerik.metadata.ClassRepo.addToCache(ClassRepo.java:21)
[17-11-25 12:46:57.498] (Info) \tat com.telerik.metadata.Builder.build(Builder.java:38)
[17-11-25 12:46:57.501] (Info) \tat com.telerik.metadata.Generator.main(Generator.java:44)
[17-11-25 12:46:57.501] (Info) FAILURE: Build failed with an exception.
[17-11-25 12:46:57.503] (Info) * What went wrong:
[17-11-25 12:46:57.506] (Info) Execution failed for task ':buildMetadata'.
[17-11-25 12:46:57.508] (Info) > Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 1
[17-11-25 12:46:57.511] (Info) * Try:
[17-11-25 12:46:57.513] (Info) Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
[17-11-25 12:46:57.513] (Info) Command ./gradlew failed with exit code 1
[17-11-25 12:46:57.516] (Info) bc_94a57ecf1b9d0abe99536fb01c06c9306905bce1_5ni0BHFmnqAceJMpsz
[17-11-25 12:46:58.211] (Error) Error detected during LiveSync on 0aef245f02b5b0dc for C:\Users\Nikita\nativescript-plugin-firebase-demo-old\Firebase. Error: Build failed.
[17-11-25 12:46:58.218] (Info) Stopped LiveSync on 0aef245f02b5b0dc for C:\Users\Nikita\nativescript-plugin-firebase-demo-old\Firebase.
[17-11-25 12:46:58.226] (Error) Couldn't enable debugging for 0aef245f02b5b0dc, Error: Couldn't enable debugging for 0aef245f02b5b0dc
    at Errors.fail (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\common\errors.js:125:28)
    at Errors.failWithoutHelp (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\common\errors.js:133:21)
    at LiveSyncService.<anonymous> (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:225:30)
    at Generator.next (<anonymous>)
    at C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:13:71
    at new Promise (<anonymous>)
    at __awaiter (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:9:12)
    at LiveSyncService.enableDebuggingCoreWithoutWaitingCurrentAction (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:222:16)
    at LiveSyncService.<anonymous> (C:\Users\Nikita\AppData\Roaming\npm\node_modules\nativescript\lib\services\livesync\livesync-service.js:262:25)
    at Generator.next (<anonymous>)