eclipsesource / tabris-plugin-firebase

A firebase plugin for Tabris.js
https://tabrisjs.com
BSD 3-Clause "New" or "Revised" License
6 stars 5 forks source link

Build Fail on Android #61

Closed raphaelpreston closed 5 years ago

raphaelpreston commented 5 years ago

Problem description

Building the example project for Android fails upon :app:compileDebugKotlin in 3.0.0-beta1 and fails on a cordova version conflict in 2.6.3.

The entire error pastes are in the dropdowns below.

package.json specifies: "3.0.0-beta1" & tabris --version says 3.0.0-beta1
PS C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example> tabris build android
[./] npm run --if-present build:android
[./] npm run --if-present build
[./] Copying Cordova files to build/cordova ...
[./] Copying JavaScript files to build\cordova\www\app ...
[build\cordova\www\app] npm install --production
npm WARN app No repository field.
npm WARN app No license field.

added 1 package and audited 1 package in 0.668s
found 0 vulnerabilities

[./] Replacing variables in config.xml...
[C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin
[build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules\.bin\cordova platform add C:\Users\$USER\.tabris-cli\platforms\android\3.0.0-beta1 --no-update-notifier
Adding android project...
Creating Cordova project for the Android platform:
        Path: platforms\android
        Package: com.$BUNDLEID
        Name: Tabris.js_Firebase_Plugin_Example
        Activity: MainActivity
        Android target: android-27
Subproject Path: CordovaLib
Subproject Path: app
Android project created with cordova-android@7.1.0
Android Studio project detected
Android Studio project detected
Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project
Fetching plugin "https://github.com/eclipsesource/tabris-plugin-firebase.git" via git clone
Repository "https://github.com/eclipsesource/tabris-plugin-firebase.git" checked out to git ref "master".
Installing "tabris-plugin-firebase" for android
Subproject Path: CordovaLib
Subproject Path: app
[build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules\.bin\cordova build android --no-update-notifier
Android Studio project detected
ANDROID_HOME=C:\Users\$USER\AppData\Local\Android\sdk
JAVA_HOME=C:\Program Files\java\jdk1.8.0_101
studio

BUILD SUCCESSFUL in 1s
1 actionable task: 1 executed
Subproject Path: CordovaLib
Subproject Path: app
Starting a Gradle Daemon, 1 incompatible Daemon could not be reused, use --status for details
publishNonDefault is deprecated and has no effect anymore. All variants are now published.
The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead.
        at build_77vknwsxqlysq08cpheowl1qn.run(C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\build.gradle:151)
Configuration 'compile' in project ':app' is deprecated. Use 'implementation' instead.
Could not find google-services.json while looking in [src/debug]
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)
Could not find google-services.json while looking in [src/release]
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)
:CordovaLib:preBuild UP-TO-DATE
:CordovaLib:preDebugBuild UP-TO-DATE
:CordovaLib:compileDebugAidl
:CordovaLib:compileDebugRenderscript
:CordovaLib:checkDebugManifest
:CordovaLib:generateDebugBuildConfig
:CordovaLib:generateDebugResValues
:CordovaLib:generateDebugResources
:CordovaLib:packageDebugResources
:CordovaLib:platformAttrExtractor
:CordovaLib:processDebugManifest
:CordovaLib:prepareLintJar
:CordovaLib:processDebugJavaRes
:app:preBuild UP-TO-DATE
:app:preDebugBuild
:app:compileDebugAidl
:CordovaLib:packageDebugRenderscript NO-SOURCE
:app:compileDebugRenderscript
:app:checkDebugManifest
:app:generateDebugBuildConfig
:app:generateDebugResValues
:app:generateDebugResources
:app:processDebugGoogleServices
Parsing json file: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\google-services.json
:app:mergeDebugResources
:app:createDebugCompatibleScreenManifests
:app:processDebugManifest
:app:splitsDiscoveryTaskDebug
:app:prepareLintJar
:app:compileDebugNdk NO-SOURCE
:CordovaLib:mergeDebugShaders
:CordovaLib:compileDebugShaders
:CordovaLib:generateDebugAssets
:CordovaLib:mergeDebugAssets
:app:mergeDebugShaders
:app:compileDebugShaders
:app:generateDebugAssets
:app:mergeDebugAssets
:CordovaLib:compileDebugNdk NO-SOURCE
:CordovaLib:mergeDebugJniLibFolders
:CordovaLib:transformNativeLibsWithMergeJniLibsForDebug
:CordovaLib:transformNativeLibsWithIntermediateJniLibsForDebug
:app:mergeDebugJniLibFolders
:app:processDebugJavaRes NO-SOURCE
:app:validateSigningDebug
:CordovaLib:processDebugResources
:CordovaLib:compileDebugKotlin
:CordovaLib:generateDebugSources
:CordovaLib:javaPreCompileDebug
:CordovaLib:compileDebugJavaWithJavacNote: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

:CordovaLib:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug
:app:processDebugResources
:app:compileDebugKotline: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (6, 54): Unresolved reference: asSequence
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (38, 23): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch:
@InlineOnly public inline fun  Enumeration.asSequence(): Sequence defined in kotlin.sequences
public fun  Array.asSequence(): Sequence defined in kotlin.collections
public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections
public fun ByteArray.asSequence(): Sequence defined in kotlin.collections
public fun CharArray.asSequence(): Sequence defined in kotlin.collections
public fun CharSequence.asSequence(): Sequence defined in kotlin.text
public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections
public fun FloatArray.asSequence(): Sequence defined in kotlin.collections
public fun IntArray.asSequence(): Sequence defined in kotlin.collections
public fun LongArray.asSequence(): Sequence defined in kotlin.collections
public fun ShortArray.asSequence(): Sequence defined in kotlin.collections
public fun  Iterable.asSequence(): Sequence defined in kotlin.collections
public fun  Iterator.asSequence(): Sequence defined in kotlin.sequences
public fun  Map.asSequence(): Sequence> defined in kotlin.collections
@InlineOnly public inline fun  Sequence.asSequence(): Sequence defined in kotlin.sequences
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (38, 47): Unresolved reference: it
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (39, 55): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch:
@InlineOnly public inline fun  Enumeration.asSequence(): Sequence defined in kotlin.sequences
public fun  Array.asSequence(): Sequence defined in kotlin.collections
public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections
public fun ByteArray.asSequence(): Sequence defined in kotlin.collections
public fun CharArray.asSequence(): Sequence defined in kotlin.collections
public fun CharSequence.asSequence(): Sequence defined in kotlin.text
public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections
public fun FloatArray.asSequence(): Sequence defined in kotlin.collections
public fun IntArray.asSequence(): Sequence defined in kotlin.collections
public fun LongArray.asSequence(): Sequence defined in kotlin.collections
public fun ShortArray.asSequence(): Sequence defined in kotlin.collections
public fun  Iterable.asSequence(): Sequence defined in kotlin.collections
public fun  Iterator.asSequence(): Sequence defined in kotlin.sequences
public fun  Map.asSequence(): Sequence> defined in kotlin.collections
@InlineOnly public inline fun  Sequence.asSequence(): Sequence defined in kotlin.sequences
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (41, 59): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch:
@InlineOnly public inline fun  Enumeration.asSequence(): Sequence defined in kotlin.sequences
public fun  Array.asSequence(): Sequence defined in kotlin.collections
public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections
public fun ByteArray.asSequence(): Sequence defined in kotlin.collections
public fun CharArray.asSequence(): Sequence defined in kotlin.collections
public fun CharSequence.asSequence(): Sequence defined in kotlin.text
public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections
public fun FloatArray.asSequence(): Sequence defined in kotlin.collections
public fun IntArray.asSequence(): Sequence defined in kotlin.collections
public fun LongArray.asSequence(): Sequence defined in kotlin.collections
public fun ShortArray.asSequence(): Sequence defined in kotlin.collections
public fun  Iterable.asSequence(): Sequence defined in kotlin.collections
public fun  Iterator.asSequence(): Sequence defined in kotlin.sequences
public fun  Map.asSequence(): Sequence> defined in kotlin.collections
@InlineOnly public inline fun  Sequence.asSequence(): Sequence defined in kotlin.sequences
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (41, 96): Unresolved reference: it
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (9, 60): Unresolved reference: ObjectHandler
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (11, 3): 'type' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (13, 3): 'properties' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (13, 36): Unresolved reference: Property
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 7): Unresolved reference: BooleanProperty
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 55): Unresolved reference: setAnalyticsCollectionEnabled
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 85): Unresolved reference: it
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 7): Unresolved reference: StringProperty
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 38): Unresolved reference: setScreenName
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 52): Unresolved reference: it
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 7): Unresolved reference: StringProperty
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 34): Unresolved reference: setUserId
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 44): Unresolved reference: it
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (19, 3): 'create' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (21, 3): 'call' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (11, 22): Unresolved reference: app
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (12, 17): Unresolved reference: localbroadcastmanager
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (14, 41): Unresolved reference: ActivityState
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (15, 41): Unresolved reference: ActivityState
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (16, 41): Unresolved reference: ActivityState
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (28, 60): Unresolved reference: ActivityStateListener
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (30, 41): Unresolved reference: activityCreationIntent
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (35, 34): Unresolved reference: LocalBroadcastManager
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (38, 18): Unresolved reference: addActivityStateListener
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (44, 3): 'activityStateChanged' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (44, 52): Unresolved reference: ActivityState
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (46, 7): Unresolved reference: START
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (47, 7): Unresolved reference: NEW_INTENT
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (48, 7): Unresolved reference: STOP
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (94, 5): Unresolved reference: NotificationManagerCompat
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (8, 60): Unresolved reference: ObjectHandler
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (10, 3): 'type' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (12, 3): 'properties' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (12, 36): Unresolved reference: Property
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (13, 7): Unresolved reference: StringProperty
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (14, 7): Unresolved reference: StringProperty
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (15, 7): Unresolved reference: V8ObjectProperty
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (15, 40): Unresolved reference: launchData
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (18, 3): 'create' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (20, 3): 'call' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (27, 3): 'destroy' overrides nothing
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\NotificationOpenedReceiver.kt: (6, 17): Unresolved reference: localbroadcastmanager
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\NotificationOpenedReceiver.kt: (29, 7): Unresolved reference: LocalBroadcastManager
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseInstanceIDService.kt: (4, 17): Unresolved reference: localbroadcastmanager
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseInstanceIDService.kt: (14, 5): Unresolved reference: LocalBroadcastManager
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (13, 22): Unresolved reference: app
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (14, 22): Unresolved reference: app
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (15, 17): Unresolved reference: localbroadcastmanager
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (38, 10): Unresolved reference: LocalBroadcastManager
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (50, 9): Unresolved reference: NotificationManagerCompat
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (58, 12): Unresolved reference: NotificationCompat
e: C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (62, 19): Unresolved reference: NotificationCompat
 FAILED

40 actionable tasks: 40 executed
FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:compileDebugKotlin'.
\> Compilation error. See log for more details
package.json specifies: "^2.6.3" & tabris --version says 2.6.3
PS C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example> tabris build android
[./] npm run --if-present build:android
[./] npm run --if-present build
[./] Copying Cordova files to build/cordova ...
[./] Copying JavaScript files to build\cordova\www\app ...
[build\cordova\www\app] npm install --production
npm WARN app No repository field.
npm WARN app No license field.

updated 1 package and audited 1 package in 0.778s
found 0 vulnerabilities

[./] Replacing variables in config.xml...
[C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin
[build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules\.bin\cordova platform add C:\Users\$USER\.tabris-cli\platforms\android\2.6.2 --no-update-notifier
Adding android project...
Creating Cordova project for the Android platform:
        Path: platforms\android
        Package: com.$BUNDLEID
        Name: Tabris.js_Firebase_Plugin_Example
        Activity: MainActivity
        Android target: android-26
Subproject Path: CordovaLib
Android project created with cordova-android@6.3.0
Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project
Fetching plugin "https://github.com/eclipsesource/tabris-plugin-firebase.git" via git clone
Repository "https://github.com/eclipsesource/tabris-plugin-firebase.git" checked out to git ref "master".
Installing "tabris-plugin-firebase" for android
Plugin doesn't support this project's cordova-android version. cordova-android: 6.3.0, failed version requirement: >=7.0.0
Skipping 'tabris-plugin-firebase' for android
[build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules\.bin\cordova build android --no-update-notifier
ANDROID_HOME=C:\Users\$USER\AppData\Local\Android\sdk
JAVA_HOME=C:\Program Files\java\jdk1.8.0_101
Starting a Gradle Daemon (subsequent builds will be faster)
\> Task :wrapper

BUILD SUCCESSFUL in 5s
1 actionable task: 1 executed
Subproject Path: CordovaLib
Starting a Gradle Daemon (subsequent builds will be faster)
The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead.
        at build_4fdbjditvr5u93u6h9me72oy8.run(C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\build.gradle:152)
publishNonDefault is deprecated and has no effect anymore. All variants are now published.
:preBuild UP-TO-DATE
:CordovaLib:preBuild UP-TO-DATE
:CordovaLib:preDebugBuild UP-TO-DATE
:CordovaLib:checkDebugManifest
:CordovaLib:processDebugManifest
:preDebugBuild
:CordovaLib:compileDebugAidl
:compileDebugAidl
:CordovaLib:packageDebugRenderscript NO-SOURCE
:compileDebugRenderscript
:checkDebugManifest
:generateDebugBuildConfig
:generateDebugResValues
:generateDebugResources
:CordovaLib:compileDebugRenderscript
:CordovaLib:generateDebugResValues
:CordovaLib:generateDebugResources
:CordovaLib:packageDebugResources
:mergeDebugResources
:createDebugCompatibleScreenManifests
:processDebugManifest
:splitsDiscoveryTaskDebug
:CordovaLib:platformAttrExtractor
:CordovaLib:generateDebugBuildConfig
:CordovaLib:prepareLintJar
:CordovaLib:javaPreCompileDebug
:CordovaLib:processDebugJavaRes NO-SOURCE
:prepareLintJar
:compileDebugNdk NO-SOURCE
:mergeDebugShaders
:compileDebugShaders
:generateDebugAssets
:CordovaLib:mergeDebugShaders
:CordovaLib:compileDebugShaders
:CordovaLib:generateDebugAssets
:CordovaLib:mergeDebugAssets
:mergeDebugAssets
:extractTryWithResourcesSupportJarDebug
:mergeDebugJniLibFolders
:CordovaLib:compileDebugNdk NO-SOURCE
:CordovaLib:mergeDebugJniLibFolders
:CordovaLib:transformNativeLibsWithMergeJniLibsForDebug
:CordovaLib:transformNativeLibsWithIntermediateJniLibsForDebug
:processDebugJavaRes NO-SOURCE
:validateSigningDebug
:CordovaLib:processDebugResources
:processDebugResourcesC:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\build\intermediates\manifests\full\debug\AndroidManifest.xml:24: AAPT: error: resource style/Theme.Firebase (aka com.$BUNDLEID:style/Theme.Firebase) not found.

C:\Users\$USER\Documents\$APP\tabris-plugin-firebase-master 2\example\build\cordova\platforms\android\build\intermediates\manifests\full\debug\AndroidManifest.xml:24: error: resource style/Theme.Firebase (aka com.$BUNDLEID:style/Theme.Firebase) not found.
error: failed processing manifest.

Failed to execute aapt
com.android.ide.common.process.ProcessException: Failed to execute aapt
        at com.android.builder.core.AndroidBuilder.processResources(AndroidBuilder.java:796)
        at com.android.build.gradle.tasks.ProcessAndroidResources.invokeAaptForSplit(ProcessAndroidResources.java:551)
        at com.android.build.gradle.tasks.ProcessAndroidResources.doFullTaskAction(ProcessAndroidResources.java:285)
        at com.android.build.gradle.internal.tasks.IncrementalTask.taskAction(IncrementalTask.java:109)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:73)
        at org.gradle.api.internal.project.taskfactory.DefaultTaskClassInfoStore$IncrementalTaskAction.doExecute(DefaultTaskClassInfoStore.java:173)
        at org.gradle.api.internal.project.taskfactory.DefaultTaskClassInfoStore$StandardTaskAction.execute(DefaultTaskClassInfoStore.java:134)
        at org.gradle.api.internal.project.taskfactory.DefaultTaskClassInfoStore$StandardTaskAction.execute(DefaultTaskClassInfoStore.java:121)
        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter$1.run(ExecuteActionsTaskExecuter.java:122)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:197)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:107)
        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:111)
        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:92)
        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:70)
        at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:63)
        at org.gradle.api.internal.tasks.execution.ResolveTaskOutputCachingStateExecuter.execute(ResolveTaskOutputCachingStateExecuter.java:54)
        at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:58)
        at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:88)
        at org.gradle.api.internal.tasks.execution.ResolveTaskArtifactStateTaskExecuter.execute(ResolveTaskArtifactStateTaskExecuter.java:52)
        at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:52)
        at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:54)
        at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43) FAILED
35 actionable tasks: 35 executed

        at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:34)
        at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker$1.run(DefaultTaskGraphExecuter.java:248)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:197)
        at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:107)
        at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:241)
        at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:230)
        at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.processTask(DefaultTaskPlanExecutor.java:124)
        at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.access$200(DefaultTaskPlanExecutor.java:80)
        at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:105)
        at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:99)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionPlan.execute(DefaultTaskExecutionPlan.java:625)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionPlan.executeWithTask(DefaultTaskExecutionPlan.java:580)
        at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.run(DefaultTaskPlanExecutor.java:99)
        at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
        at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
        at java.lang.Thread.run(Thread.java:745)
Caused by: java.util.concurrent.ExecutionException: java.util.concurrent.ExecutionException: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
        at com.google.common.util.concurrent.AbstractFuture.getDoneValue(AbstractFuture.java:503)
        at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:482)
        at com.google.common.util.concurrent.AbstractFuture$TrustedFuture.get(AbstractFuture.java:79)
        at com.android.builder.core.AndroidBuilder.processResources(AndroidBuilder.java:794)
        ... 48 more
Caused by: java.util.concurrent.ExecutionException: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
        at com.google.common.util.concurrent.AbstractFuture.getDoneValue(AbstractFuture.java:503)
        at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:462)
        at com.google.common.util.concurrent.AbstractFuture$TrustedFuture.get(AbstractFuture.java:79)
        at com.android.builder.internal.aapt.v2.QueueableAapt2.lambda$makeValidatedPackage$1(QueueableAapt2.java:179)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        ... 1 more
Caused by: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
        at com.android.builder.png.AaptProcess$NotifierProcessOutput.handleOutput(AaptProcess.java:454)
        at com.android.builder.png.AaptProcess$NotifierProcessOutput.err(AaptProcess.java:411)
        at com.android.builder.png.AaptProcess$ProcessOutputFacade.err(AaptProcess.java:332)
        at com.android.utils.GrabProcessOutput$1.run(GrabProcessOutput.java:104)

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':processDebugResources'.
\> Failed to execute aapt

Environment

Code snippet

Nothing has been changed from the example except for:

mpost commented 5 years ago

The 3.0 zero build does not use the 3.0 platform. Did you specify the platform manually or does the cli pull it in? you can set an env var TABRIS_ANDROID_PLATFORM to a local dir so that the cli consumes the platform from that location.

mpost commented 5 years ago

Also make sure to use the 3.0 tabris cli

raphaelpreston commented 5 years ago

Thanks @mpost, but I'm not quite sure what you mean by your comments. In order to help you diagnose my problem I've created a step-by-step way to replicate the exact errors I'm getting.

Steps

  1. Download the plugin
  2. Navigate to tabris-plugin-firebase-master/example
  3. Use Windows PowerShell to run npm i (unsure if I need to do this)
    Output
    PS C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example> npm i
    npm notice created a lockfile as package-lock.json. You should commit this file.
    npm WARN example No repository field.
    npm WARN example No license field.

added 1 package and audited 1 package in 0.765s found 0 vulnerabilities

  1. Run tabris run android
    Output
    PS C:\Users\$USER\Documents\$APP\test\tabris-plugin-firebase-master\example> tabris run android
    [./] npm run --if-present build:android
    [./] npm run --if-present build
    [./] Copying Cordova files to build/cordova ...
    [./] Copying JavaScript files to build\cordova\www\app ...
    [build\cordova\www\app] npm install --production
    npm notice created a lockfile as package-lock.json. You should commit this file.
    npm WARN app No repository field.
    npm WARN app No license field.

added 1 package and audited 1 package in 0.578s found 0 vulnerabilities

[./] Replacing variables in config.xml... [./] Downloading android platform version 3.0.0-beta2-dev.20190207... Unable to download platform: Unexpected status code 404


  1. I don't know why this happens, but changing to 3.0.0-beta1 fixes it. So, I open example/package.json and change the tabris dependency from "nightly" to "3.0.0-beta1".
  2. Run tabris run android
    Output
    PS C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example> tabris run android
    [./] npm run --if-present build:android
    [./] npm run --if-present build
    [./] Copying Cordova files to build/cordova ...
    [./] Copying JavaScript files to build\cordova\www\app ...
    [build\cordova\www\app] npm install --production
    npm WARN app No repository field.
    npm WARN app No license field.

added 1 package and audited 1 package in 0.789s found 0 vulnerabilities

[./] Replacing variables in config.xml... [C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova platform add C:\Users\$USER.tabris-cli\platforms\android\3.0.0-beta1 --no-update-notifier Adding android project... Creating Cordova project for the Android platform: Path: platforms\android Package: com.eclipsesource.tabris.firebase.example Name: Tabris.js_Firebase_Plugin_Example Activity: MainActivity Android target: android-27 Subproject Path: CordovaLib Subproject Path: app Android project created with cordova-android@7.1.0 Android Studio project detected Android Studio project detected Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project Failed to restore plugin "tabris-plugin-firebase" from config.xml. You might need to try adding it again. Error: Cannot find plugin.xml for plugin "..". Please try adding it again. [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova run android --no-update-notifier Android Studio project detected Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project Failed to restore plugin "tabris-plugin-firebase" from config.xml. You might need to try adding it again. Error: Cannot find plugin.xml for plugin "..". Please try adding it again. ANDROID_HOME=C:\Users\$USER\AppData\Local\Android\sdk JAVA_HOME=C:\Program Files\java\jdk1.8.0_101 studio

BUILD SUCCESSFUL in 1s 1 actionable task: 1 executed Subproject Path: CordovaLib Subproject Path: app publishNonDefault is deprecated and has no effect anymore. All variants are now published. The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead. at build_cb6qxpfzczmounlzpctn2kdsa.run(C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\build.gradle:150) :CordovaLib:preBuild UP-TO-DATE :CordovaLib:preDebugBuild UP-TO-DATE :CordovaLib:compileDebugAidl :CordovaLib:compileDebugRenderscript :CordovaLib:checkDebugManifest :CordovaLib:generateDebugBuildConfig :CordovaLib:generateDebugResValues :CordovaLib:generateDebugResources :CordovaLib:packageDebugResources :CordovaLib:platformAttrExtractor :CordovaLib:processDebugManifest :CordovaLib:prepareLintJar :CordovaLib:processDebugJavaRes :app:preBuild UP-TO-DATE :app:preDebugBuild :app:compileDebugAidl :CordovaLib:packageDebugRenderscript NO-SOURCE :app:compileDebugRenderscript :app:checkDebugManifest :app:generateDebugBuildConfig :app:generateDebugResValues :app:generateDebugResources :app:mergeDebugResources :app:createDebugCompatibleScreenManifests :app:processDebugManifest :app:splitsDiscoveryTaskDebug :app:prepareLintJar :app:compileDebugNdk NO-SOURCE :CordovaLib:mergeDebugShaders :CordovaLib:compileDebugShaders :CordovaLib:generateDebugAssets :CordovaLib:mergeDebugAssets :app:mergeDebugShaders :app:compileDebugShaders :app:generateDebugAssets :app:mergeDebugAssets :CordovaLib:compileDebugNdk NO-SOURCE :CordovaLib:mergeDebugJniLibFolders :CordovaLib:transformNativeLibsWithMergeJniLibsForDebug :CordovaLib:transformNativeLibsWithIntermediateJniLibsForDebug :app:mergeDebugJniLibFolders :app:processDebugJavaRes NO-SOURCE :app:validateSigningDebug :CordovaLib:processDebugResources :CordovaLib:compileDebugKotlin :CordovaLib:generateDebugSources :CordovaLib:javaPreCompileDebug :CordovaLib:compileDebugJavaWithJavacNote: Some input files use or override a deprecated API. Note: Recompile with -Xlint:deprecation for details.

:CordovaLib:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug :app:processDebugResources :app:compileDebugKotlin :app:generateDebugSources :app:javaPreCompileDebug :app:compileDebugJavaWithJavac :app:compileDebugSources :app:transformClassesWithStackFramesFixerForDebug :app:transformClassesWithDesugarForDebug :app:transformClassesWithDexBuilderForDebug :app:transformDexArchiveWithExternalLibsDexMergerForDebug :app:transformDexArchiveWithDexMergerForDebug :app:transformNativeLibsWithMergeJniLibsForDebug :app:transformResourcesWithMergeJavaResForDebug :app:packageDebug :app:assembleDebug :app:cdvBuildDebug

BUILD SUCCESSFUL in 41s 49 actionable tasks: 49 executed Built the following apk(s): C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\build\outputs\apk\debug\app-debug.apk ANDROID_HOME=C:\Users\$USER\AppData\Local\Android\sdk JAVA_HOME=C:\Program Files\java\jdk1.8.0_101 No target specified, deploying to device 'FA7470000812'. none Skipping build... Built the following apk(s): C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\build\outputs\apk\debug\app-debug.apk Using apk: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\build\outputs\apk\debug\app-debug.apk Package name: com.eclipsesource.tabris.firebase.example LAUNCH SUCCESS

  1. The APK seems to be successfully built, but early in the output it says "Failed to restore plugin "tabris-plugin-firebase" from config.xml", so for some reason it's not finding the plugin. So to fix that, I navigate to example/cordova/config.xml and change the spec property of the <plugin> tag to be "https://github.com/eclipsesource/tabris-plugin-firebase.git" instead of "../".
  2. Run tabris clean
  3. Run tabris run android
    Output
    PS C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example> tabris run android
    [./] npm run --if-present build:android
    [./] npm run --if-present build
    [./] Copying Cordova files to build/cordova ...
    [./] Copying JavaScript files to build\cordova\www\app ...
    [build\cordova\www\app] npm install --production
    npm WARN app No repository field.
    npm WARN app No license field.

added 1 package and audited 1 package in 0.743s found 0 vulnerabilities

[./] Replacing variables in config.xml... [C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova platform add C:\Users\$USER.tabris-cli\platforms\android\3.0.0-beta1 --no-update-notifier Adding android project... Creating Cordova project for the Android platform: Path: platforms\android Package: com.eclipsesource.tabris.firebase.example Name: Tabris.js_Firebase_Plugin_Example Activity: MainActivity Android target: android-27 Subproject Path: CordovaLib Subproject Path: app Android project created with cordova-android@7.1.0 Android Studio project detected Android Studio project detected Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project Fetching plugin "https://github.com/eclipsesource/tabris-plugin-firebase.git" via git clone Repository "https://github.com/eclipsesource/tabris-plugin-firebase.git" checked out to git ref "master". Installing "tabris-plugin-firebase" for android Subproject Path: CordovaLib Subproject Path: app [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova run android --no-update-notifier Android Studio project detected Error: No "google-services.json" file found in /cordova.Required by plugin "tabris-plugin-firebase" (Android). The command C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova exited with 1

  1. Now that I'm receiving this error, I know that the plugin is being found. So I go to my Android app in my Firebase project from the Firebase Console and download the google-services.json file into the example/cordova folder.
  2. Run tabris clean
  3. Run tabris run android
    Output
    PS C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example> tabris run android
    [./] npm run --if-present build:android
    [./] npm run --if-present build
    [./] Copying Cordova files to build/cordova ...
    [./] Copying JavaScript files to build\cordova\www\app ...
    [build\cordova\www\app] npm install --production
    npm WARN app No repository field.
    npm WARN app No license field.

added 1 package and audited 1 package in 0.698s found 0 vulnerabilities

[./] Replacing variables in config.xml... [C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova platform add C:\Users\$USER.tabris-cli\platforms\android\3.0.0-beta1 --no-update-notifier Adding android project... Creating Cordova project for the Android platform: Path: platforms\android Package: com.eclipsesource.tabris.firebase.example Name: Tabris.js_Firebase_Plugin_Example Activity: MainActivity Android target: android-27 Subproject Path: CordovaLib Subproject Path: app Android project created with cordova-android@7.1.0 Android Studio project detected Android Studio project detected Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project Fetching plugin "https://github.com/eclipsesource/tabris-plugin-firebase.git" via git clone Repository "https://github.com/eclipsesource/tabris-plugin-firebase.git" checked out to git ref "master". Installing "tabris-plugin-firebase" for android Subproject Path: CordovaLib Subproject Path: app [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova run android --no-update-notifier Android Studio project detected ANDROID_HOME=C:\Users\$USER\AppData\Local\Android\sdk JAVA_HOME=C:\Program Files\java\jdk1.8.0_101 studio

BUILD SUCCESSFUL in 1s 1 actionable task: 1 executed Subproject Path: CordovaLib Subproject Path: app publishNonDefault is deprecated and has no effect anymore. All variants are now published. The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead. at build_cb6qxpfzczmounlzpctn2kdsa.run(C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\build.gradle:151) Configuration 'compile' in project ':app' is deprecated. Use 'implementation' instead. Could not find google-services.json while looking in [src/debug] registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection) Could not find google-services.json while looking in [src/release] registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection) :CordovaLib:preBuild UP-TO-DATE :CordovaLib:preDebugBuild UP-TO-DATE :CordovaLib:compileDebugAidl :CordovaLib:compileDebugRenderscript :CordovaLib:checkDebugManifest :CordovaLib:generateDebugBuildConfig :CordovaLib:generateDebugResValues :CordovaLib:generateDebugResources :CordovaLib:packageDebugResources :CordovaLib:platformAttrExtractor :CordovaLib:processDebugManifest :CordovaLib:prepareLintJar :CordovaLib:processDebugJavaRes :app:preBuild UP-TO-DATE :app:preDebugBuild :app:compileDebugAidl :CordovaLib:packageDebugRenderscript NO-SOURCE :app:compileDebugRenderscript :app:checkDebugManifest :app:generateDebugBuildConfig :app:generateDebugResValues :app:generateDebugResources :app:processDebugGoogleServices Parsing json file: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\google-services.json :app:processDebugGoogleServices FAILED

17 actionable tasks: 17 executed FAILURE: Build failed with an exception.

* What went wrong: Execution failed for task ':app:processDebugGoogleServices'. > No matching client found for package name 'com.eclipsesource.tabris.firebase.example'

* Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 2s The command C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova exited with 1


  1. From what I can tell, this error is caused by a mismatch within the package names. So I navigate to example/config.xml and change the id property of the <widget> tag from "com.eclipsesource.tabris.firebase.example" to the name of my package, as specified in google-services.json (specifically in the client[0].client_info.android_client_info.package_name tag).
  2. Run tabris clean
  3. Run tabris run android
    Output
    PS C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example> tabris run android
    [./] npm run --if-present build:android
    [./] npm run --if-present build
    [./] Copying Cordova files to build/cordova ...
    [./] Copying JavaScript files to build\cordova\www\app ...
    [build\cordova\www\app] npm install --production
    npm WARN app No repository field.
    npm WARN app No license field.

added 1 package and audited 1 package in 0.938s found 0 vulnerabilities

[./] Replacing variables in config.xml... [C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova platform add C:\Users\$USER.tabris-cli\platforms\android\3.0.0-beta1 --no-update-notifier Adding android project... Creating Cordova project for the Android platform: Path: platforms\android Package: com.<$packageID> Name: Tabris.js_Firebase_Plugin_Example Activity: MainActivity Android target: android-27 Subproject Path: CordovaLib Subproject Path: app Android project created with cordova-android@7.1.0 Android Studio project detected Android Studio project detected Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project Fetching plugin "https://github.com/eclipsesource/tabris-plugin-firebase.git" via git clone Repository "https://github.com/eclipsesource/tabris-plugin-firebase.git" checked out to git ref "master". Installing "tabris-plugin-firebase" for android Subproject Path: CordovaLib Subproject Path: app [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova run android --no-update-notifier Android Studio project detected ANDROID_HOME=C:\Users\$USER\AppData\Local\Android\sdk JAVA_HOME=C:\Program Files\java\jdk1.8.0_101 studio Starting a Gradle Daemon, 1 incompatible and 2 stopped Daemons could not be reused, use --status for details

BUILD SUCCESSFUL in 6s 1 actionable task: 1 executed Subproject Path: CordovaLib Subproject Path: app Starting a Gradle Daemon, 1 incompatible and 2 stopped Daemons could not be reused, use --status for details publishNonDefault is deprecated and has no effect anymore. All variants are now published. The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead. at build_cb6qxpfzczmounlzpctn2kdsa.run(C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\build.gradle:151) Configuration 'compile' in project ':app' is deprecated. Use 'implementation' instead. Could not find google-services.json while looking in [src/debug] registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection) Could not find google-services.json while looking in [src/release] registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection) :CordovaLib:preBuild UP-TO-DATE :CordovaLib:preDebugBuild UP-TO-DATE :CordovaLib:compileDebugAidl :CordovaLib:compileDebugRenderscript :CordovaLib:checkDebugManifest :CordovaLib:generateDebugBuildConfig :CordovaLib:generateDebugResValues :CordovaLib:generateDebugResources :CordovaLib:packageDebugResources :CordovaLib:platformAttrExtractor :CordovaLib:processDebugManifest :CordovaLib:prepareLintJar :CordovaLib:processDebugJavaRes :app:preBuild UP-TO-DATE :app:preDebugBuild :app:compileDebugAidl :CordovaLib:packageDebugRenderscript NO-SOURCE :app:compileDebugRenderscript :app:checkDebugManifest :app:generateDebugBuildConfig :app:generateDebugResValues :app:generateDebugResources :app:processDebugGoogleServices Parsing json file: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\google-services.json :app:mergeDebugResources :app:createDebugCompatibleScreenManifests :app:processDebugManifest :app:splitsDiscoveryTaskDebug :app:prepareLintJar :app:compileDebugNdk NO-SOURCE :CordovaLib:mergeDebugShaders :CordovaLib:compileDebugShaders :CordovaLib:generateDebugAssets :CordovaLib:mergeDebugAssets :app:mergeDebugShaders :app:compileDebugShaders :app:generateDebugAssets :app:mergeDebugAssets :CordovaLib:compileDebugNdk NO-SOURCE :CordovaLib:mergeDebugJniLibFolders :CordovaLib:transformNativeLibsWithMergeJniLibsForDebug :CordovaLib:transformNativeLibsWithIntermediateJniLibsForDebug :app:mergeDebugJniLibFolders :app:processDebugJavaRes NO-SOURCE :app:validateSigningDebug :CordovaLib:processDebugResources :CordovaLib:compileDebugKotlin :CordovaLib:generateDebugSources :CordovaLib:javaPreCompileDebug :CordovaLib:compileDebugJavaWithJavacNote: Some input files use or override a deprecated API. Note: Recompile with -Xlint:deprecation for details.

:CordovaLib:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug :app:processDebugResources :app:compileDebugKotline: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (6, 54): Unresolved reference: asSequence e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (38, 23): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: @InlineOnly public inline fun Enumeration.asSequence(): Sequence defined in kotlin.sequences public fun Array.asSequence(): Sequence defined in kotlin.collections public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections public fun ByteArray.asSequence(): Sequence defined in kotlin.collections public fun CharArray.asSequence(): Sequence defined in kotlin.collections public fun CharSequence.asSequence(): Sequence defined in kotlin.text public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections public fun FloatArray.asSequence(): Sequence defined in kotlin.collections public fun IntArray.asSequence(): Sequence defined in kotlin.collections public fun LongArray.asSequence(): Sequence defined in kotlin.collections public fun ShortArray.asSequence(): Sequence defined in kotlin.collections public fun Iterable.asSequence(): Sequence defined in kotlin.collections public fun Iterator.asSequence(): Sequence defined in kotlin.sequences public fun <K, V> Map<out Any, [ERROR : Explicit type argument expected for V]>.asSequence(): Sequence<Map.Entry<Any, [ERROR : Explicit type argument expected for V]>> defined in kotlin.collections @InlineOnly public inline fun Sequence.asSequence(): Sequence defined in kotlin.sequences e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (38, 47): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (39, 55): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: @InlineOnly public inline fun Enumeration.asSequence(): Sequence defined in kotlin.sequences public fun Array.asSequence(): Sequence defined in kotlin.collections public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections public fun ByteArray.asSequence(): Sequence defined in kotlin.collections public fun CharArray.asSequence(): Sequence defined in kotlin.collections public fun CharSequence.asSequence(): Sequence defined in kotlin.text public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections public fun FloatArray.asSequence(): Sequence defined in kotlin.collections public fun IntArray.asSequence(): Sequence defined in kotlin.collections public fun LongArray.asSequence(): Sequence defined in kotlin.collections public fun ShortArray.asSequence(): Sequence defined in kotlin.collections public fun Iterable.asSequence(): Sequence defined in kotlin.collections public fun Iterator.asSequence(): Sequence defined in kotlin.sequences public fun <K, V> Map<out String, [ERROR : Explicit type argument expected for V]>.asSequence(): Sequence<Map.Entry<String, [ERROR : Explicit type argument expected for V]>> defined in kotlin.collections @InlineOnly public inline fun Sequence.asSequence(): Sequence defined in kotlin.sequences e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (41, 59): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: @InlineOnly public inline fun Enumeration.asSequence(): Sequence defined in kotlin.sequences public fun Array.asSequence(): Sequence defined in kotlin.collections public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections public fun ByteArray.asSequence(): Sequence defined in kotlin.collections public fun CharArray.asSequence(): Sequence defined in kotlin.collections public fun CharSequence.asSequence(): Sequence defined in kotlin.text public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections public fun FloatArray.asSequence(): Sequence defined in kotlin.collections public fun IntArray.asSequence(): Sequence defined in kotlin.collections public fun LongArray.asSequence(): Sequence defined in kotlin.collections public fun ShortArray.asSequence(): Sequence defined in kotlin.collections public fun Iterable.asSequence(): Sequence defined in kotlin.collections public fun Iterator.asSequence(): Sequence defined in kotlin.sequences public fun <K, V> Map<out Any, [ERROR : Explicit type argument expected for V]>.asSequence(): Sequence<Map.Entry<Any, [ERROR : Explicit type argument expected for V]>> defined in kotlin.collections @InlineOnly public inline fun Sequence.asSequence(): Sequence defined in kotlin.sequences e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (41, 96): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (9, 60): Unresolved reference: ObjectHandler e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (11, 3): 'type' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (13, 3): 'properties' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (13, 36): Unresolved reference: Property e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 7): Unresolved reference: BooleanProperty e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 55): Unresolved reference: setAnalyticsCollectionEnabled e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 85): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 7): Unresolved reference: StringProperty e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 38): Unresolved reference: setScreenName e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 52): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 7): Unresolved reference: StringProperty e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 34): Unresolved reference: setUserId e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 44): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (19, 3): 'create' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (21, 3): 'call' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (11, 22): Unresolved reference: app e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (12, 17): Unresolved reference: localbroadcastmanager e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (14, 41): Unresolved reference: ActivityState e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (15, 41): Unresolved reference: ActivityState e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (16, 41): Unresolved reference: ActivityState e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (28, 60): Unresolved reference: ActivityStateListener e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (30, 41): Unresolved reference: activityCreationIntent e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (35, 34): Unresolved reference: LocalBroadcastManager e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (38, 18): Unresolved reference: addActivityStateListener e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (44, 3): 'activityStateChanged' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (44, 52): Unresolved reference: ActivityState e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (46, 7): Unresolved reference: START e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (47, 7): Unresolved reference: NEW_INTENT e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (48, 7): Unresolved reference: STOP e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (94, 5): Unresolved reference: NotificationManagerCompat e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (8, 60): Unresolved reference: ObjectHandler e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (10, 3): 'type' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (12, 3): 'properties' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (12, 36): Unresolved reference: Property e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (13, 7): Unresolved reference: StringProperty e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (14, 7): Unresolved reference: StringProperty e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (15, 7): Unresolved reference: V8ObjectProperty e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (15, 40): Unresolved reference: launchData e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (18, 3): 'create' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (20, 3): 'call' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (27, 3): 'destroy' overrides nothing e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\NotificationOpenedReceiver.kt: (6, 17): Unresolved reference: localbroadcastmanager e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\NotificationOpenedReceiver.kt: (29, 7): Unresolved reference: LocalBroadcastManager e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseInstanceIDService.kt: (4, 17): Unresolved reference: localbroadcastmanager e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseInstanceIDService.kt: (14, 5): Unresolved reference: LocalBroadcastManager e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (13, 22): Unresolved reference: app e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (14, 22): Unresolved reference: app e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (15, 17): Unresolved reference: localbroadcastmanager e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (38, 10): Unresolved reference: LocalBroadcastManager e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (50, 9): Unresolved reference: NotificationManagerCompat e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (58, 12): Unresolved reference: NotificationCompat e: C:\Users\$USER\Documents\$APP\replicate steps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (62, 19): Unresolved reference: NotificationCompat FAILED

40 actionable tasks: 40 executed FAILURE: Build failed with an exception.

* What went wrong: Execution failed for task ':app:compileDebugKotlin'. > Compilation error. See log for more details

* Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 38s


The final error is the error that I made the original post for. Hopefully this makes it easier to figure out what my problem is! Thanks in advance.

cookieguru commented 5 years ago

@raphaelpreston See add the plugin to your project; the plugin is downloaded automatically as part of the build process, no need to download anything manually

mpost commented 5 years ago

@raphaelpreston You might be right about updating the examples app id in the config.xml of the example since the firebase support is tied to a specific app id. we will update the example README.

Regarding your current compile errors that sounds very much like the incorrect tabris-android platform which does not include the correct files. The platform is auto downloaded for you i presume? You did not specify a local path to the platform via the TABRIS_ANDROID_PLATFORM env var? The platform can be downloaded from here (need to be signed in).

mpost commented 5 years ago

regarding the app id the google-services.json provided by the user, it could also reference an app which would have the same id as the example app: com.eclipsesource.tabris.firebase.example. Both approaches should work.

raphaelpreston commented 5 years ago

@raphaelpreston See add the plugin to your project; the plugin is downloaded automatically as part of the build process, no need to download anything manually

@cookieguru I was a bit unclear about what exactly I was downloading; I wasn't downloading the plugin to install it, I was downloading it so I could get the example project inside the repo running.

raphaelpreston commented 5 years ago

@mpost I realized that there might have been a conflict because I was running tabris-cli@3.0.0-beta1, and the dependency for the firebase example says nightly, so I installed tabris-cli@nightly.

In regard to your response, here's how I attempted to follow your instructions:

Steps

added 1 package and audited 1 package in 0.936s found 0 vulnerabilities

[./] Replacing variables in config.xml... [C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova platform add "C:\Users\$USER\Documents\$APP\ANDROID PLATFORM\tabris-android" --no-update-notifier Adding android project... Creating Cordova project for the Android platform: Path: platforms\android Package: com.<$PACKAGE_ID> Name: Tabris.js_Firebase_Plugin_Example Activity: MainActivity Android target: android-27 Subproject Path: CordovaLib Subproject Path: app Android project created with cordova-android@7.1.0 Android Studio project detected Android Studio project detected Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project Installing "tabris-plugin-firebase" for android Subproject Path: CordovaLib Subproject Path: app Saved plugin info for "tabris-plugin-firebase" to config.xml --save flag or autosave detected Saving android@C:\Users\$USER\Documents\$APP\ANDROID PLATFORM\tabris-android into config.xml file ... [build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova run android --no-update-notifier Android Studio project detected ANDROID_HOME=C:\Users\$USER\AppData\Local\Android\sdk JAVA_HOME=C:\Program Files\java\jdk1.8.0_101 studio Starting a Gradle Daemon (subsequent builds will be faster)

BUILD SUCCESSFUL in 5s 1 actionable task: 1 executed Subproject Path: CordovaLib Subproject Path: app Starting a Gradle Daemon (subsequent builds will be faster) publishNonDefault is deprecated and has no effect anymore. All variants are now published. The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead. at build_bzogsxz4a5oespmlguk4rtfx5.run(C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\build.gradle:151) Configuration 'compile' in project ':app' is deprecated. Use 'implementation' instead. Could not find google-services.json while looking in [src/debug] registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection) Could not find google-services.json while looking in [src/release] registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection) :CordovaLib:preBuild UP-TO-DATE :CordovaLib:preDebugBuild UP-TO-DATE :CordovaLib:compileDebugAidl :CordovaLib:compileDebugRenderscript :CordovaLib:checkDebugManifest :CordovaLib:generateDebugBuildConfig :CordovaLib:generateDebugResValues :CordovaLib:generateDebugResources :CordovaLib:packageDebugResources :CordovaLib:platformAttrExtractor :CordovaLib:processDebugManifest :CordovaLib:prepareLintJar :CordovaLib:processDebugJavaRes :app:preBuild UP-TO-DATE :app:preDebugBuild :app:compileDebugAidl :CordovaLib:packageDebugRenderscript NO-SOURCE :app:compileDebugRenderscript :app:checkDebugManifest :app:generateDebugBuildConfig :app:generateDebugResValues :app:generateDebugResources :app:processDebugGoogleServices Parsing json file: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\google-services.json :app:mergeDebugResources :app:createDebugCompatibleScreenManifests :app:processDebugManifest :app:splitsDiscoveryTaskDebug :app:prepareLintJar :app:compileDebugNdk NO-SOURCE :CordovaLib:mergeDebugShaders :CordovaLib:compileDebugShaders :CordovaLib:generateDebugAssets :CordovaLib:mergeDebugAssets :app:mergeDebugShaders :app:compileDebugShaders :app:generateDebugAssets :app:mergeDebugAssets :CordovaLib:compileDebugNdk NO-SOURCE :CordovaLib:mergeDebugJniLibFolders :CordovaLib:transformNativeLibsWithMergeJniLibsForDebug :CordovaLib:transformNativeLibsWithIntermediateJniLibsForDebug :app:mergeDebugJniLibFolders :app:processDebugJavaRes NO-SOURCE :app:validateSigningDebug :CordovaLib:processDebugResources :CordovaLib:compileDebugKotlin :CordovaLib:generateDebugSources :CordovaLib:javaPreCompileDebug :CordovaLib:compileDebugJavaWithJavacNote: Some input files use or override a deprecated API. Note: Recompile with -Xlint:deprecation for details.

:CordovaLib:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug :app:processDebugResources :app:compileDebugKotline: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (6, 54): Unresolved reference: asSequence e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (38, 23): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: @InlineOnly public inline fun Enumeration.asSequence(): Sequence defined in kotlin.sequences public fun Array.asSequence(): Sequence defined in kotlin.collections public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections public fun ByteArray.asSequence(): Sequence defined in kotlin.collections public fun CharArray.asSequence(): Sequence defined in kotlin.collections public fun CharSequence.asSequence(): Sequence defined in kotlin.text public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections public fun FloatArray.asSequence(): Sequence defined in kotlin.collections public fun IntArray.asSequence(): Sequence defined in kotlin.collections public fun LongArray.asSequence(): Sequence defined in kotlin.collections public fun ShortArray.asSequence(): Sequence defined in kotlin.collections public fun Iterable.asSequence(): Sequence defined in kotlin.collections public fun Iterator.asSequence(): Sequence defined in kotlin.sequences public fun <K, V> Map<out Any, [ERROR : Explicit type argument expected for V]>.asSequence(): Sequence<Map.Entry<Any, [ERROR : Explicit type argument expected for V]>> defined in kotlin.collections @InlineOnly public inline fun Sequence.asSequence(): Sequence defined in kotlin.sequences e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (38, 47): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (39, 55): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: @InlineOnly public inline fun Enumeration.asSequence(): Sequence defined in kotlin.sequences public fun Array.asSequence(): Sequence defined in kotlin.collections public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections public fun ByteArray.asSequence(): Sequence defined in kotlin.collections public fun CharArray.asSequence(): Sequence defined in kotlin.collections public fun CharSequence.asSequence(): Sequence defined in kotlin.text public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections public fun FloatArray.asSequence(): Sequence defined in kotlin.collections public fun IntArray.asSequence(): Sequence defined in kotlin.collections public fun LongArray.asSequence(): Sequence defined in kotlin.collections public fun ShortArray.asSequence(): Sequence defined in kotlin.collections public fun Iterable.asSequence(): Sequence defined in kotlin.collections public fun Iterator.asSequence(): Sequence defined in kotlin.sequences public fun <K, V> Map<out String, [ERROR : Explicit type argument expected for V]>.asSequence(): Sequence<Map.Entry<String, [ERROR : Explicit type argument expected for V]>> defined in kotlin.collections @InlineOnly public inline fun Sequence.asSequence(): Sequence defined in kotlin.sequences e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (41, 59): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: @InlineOnly public inline fun Enumeration.asSequence(): Sequence defined in kotlin.sequences public fun Array.asSequence(): Sequence defined in kotlin.collections public fun BooleanArray.asSequence(): Sequence defined in kotlin.collections public fun ByteArray.asSequence(): Sequence defined in kotlin.collections public fun CharArray.asSequence(): Sequence defined in kotlin.collections public fun CharSequence.asSequence(): Sequence defined in kotlin.text public fun DoubleArray.asSequence(): Sequence defined in kotlin.collections public fun FloatArray.asSequence(): Sequence defined in kotlin.collections public fun IntArray.asSequence(): Sequence defined in kotlin.collections public fun LongArray.asSequence(): Sequence defined in kotlin.collections public fun ShortArray.asSequence(): Sequence defined in kotlin.collections public fun Iterable.asSequence(): Sequence defined in kotlin.collections public fun Iterator.asSequence(): Sequence defined in kotlin.sequences public fun <K, V> Map<out Any, [ERROR : Explicit type argument expected for V]>.asSequence(): Sequence<Map.Entry<Any, [ERROR : Explicit type argument expected for V]>> defined in kotlin.collections @InlineOnly public inline fun Sequence.asSequence(): Sequence defined in kotlin.sequences e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\Analytics.kt: (41, 96): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (9, 60): Unresolved reference: ObjectHandler e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (11, 3): 'type' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (13, 3): 'properties' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (13, 36): Unresolved reference: Property e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 7): Unresolved reference: BooleanProperty e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 55): Unresolved reference: setAnalyticsCollectionEnabled e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (14, 85): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 7): Unresolved reference: StringProperty e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 38): Unresolved reference: setScreenName e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (15, 52): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 7): Unresolved reference: StringProperty e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 34): Unresolved reference: setUserId e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (16, 44): Unresolved reference: it e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (19, 3): 'create' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\analytics\AnalyticsHandler.kt: (21, 3): 'call' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (11, 22): Unresolved reference: app e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (12, 17): Unresolved reference: localbroadcastmanager e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (14, 41): Unresolved reference: ActivityState e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (15, 41): Unresolved reference: ActivityState e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (16, 41): Unresolved reference: ActivityState e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (28, 60): Unresolved reference: ActivityStateListener e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (30, 41): Unresolved reference: activityCreationIntent e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (35, 34): Unresolved reference: LocalBroadcastManager e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (38, 18): Unresolved reference: addActivityStateListener e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (44, 3): 'activityStateChanged' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (44, 52): Unresolved reference: ActivityState e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (46, 7): Unresolved reference: START e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (47, 7): Unresolved reference: NEW_INTENT e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (48, 7): Unresolved reference: STOP e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\Messaging.kt: (94, 5): Unresolved reference: NotificationManagerCompat e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (8, 60): Unresolved reference: ObjectHandler e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (10, 3): 'type' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (12, 3): 'properties' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (12, 36): Unresolved reference: Property e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (13, 7): Unresolved reference: StringProperty e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (14, 7): Unresolved reference: StringProperty e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (15, 7): Unresolved reference: V8ObjectProperty e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (15, 40): Unresolved reference: launchData e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (18, 3): 'create' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (20, 3): 'call' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\MessagingHandler.kt: (27, 3): 'destroy' overrides nothing e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\NotificationOpenedReceiver.kt: (6, 17): Unresolved reference: localbroadcastmanager e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\NotificationOpenedReceiver.kt: (29, 7): Unresolved reference: LocalBroadcastManager e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseInstanceIDService.kt: (4, 17): Unresolved reference: localbroadcastmanager e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseInstanceIDService.kt: (14, 5): Unresolved reference: LocalBroadcastManager e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (13, 22): Unresolved reference: app e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (14, 22): Unresolved reference: app e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (15, 17): Unresolved reference: localbroadcastmanager e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (38, 10): Unresolved reference: LocalBroadcastManager e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (50, 9): Unresolved reference: NotificationManagerCompat e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (58, 12): Unresolved reference: NotificationCompat e: C:\Users\$USER\Documents\$APP\newsteps\tabris-plugin-firebase-master\example\build\cordova\platforms\android\app\src\main\java\com\eclipsesource\firebase\messaging\TabrisFirebaseMessagingService.kt: (62, 19): Unresolved reference: NotificationCompat FAILED

40 actionable tasks: 40 executed FAILURE: Build failed with an exception.

* What went wrong: Execution failed for task ':app:compileDebugKotlin'. > Compilation error. See log for more details

* Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 48s The command C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova exited with 1

If you look at the output, you'll see it's the same error from before. Furthermore, because the output says

[build/cordova] C:\Users\$USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova platform add "C:\Users\$USER\Documents\Notify_App\ANDROID PLATFORM\tabris-android" --no-update-notifier

I know it found the folder that I downloaded, meaning that the problem must not be the incorrect tabris-android platform. I performed the steps above with tabris-cli@nightly, but just to see if it would fix anything I reinstalled tabris-cli@3.0.0-beta1 and ran it, but it resulted in the same error.

mpost commented 5 years ago

hi @raphaelpreston i am investigating what might cause your issue but ran into an issue on the latest nightly tabris-cli caused by cordova (does not affect the 3.0-beta1 cli). We opened an issue for that here. Please stay tuned for more feedback.

mpost commented 5 years ago

I was able to reproduce the build error you reported. While i can't yet judge what causes the issue it will work with the nightly android platform of 3.x (due out tonight) and the master branch of the plugin.

raphaelpreston commented 5 years ago

Unfortunately, it's still not working... although, it is throwing a different error now! I created a repo and uploaded all the files from the example, without changing anything (except for the spec property in config.xml to appropriately point to the plugin). I'm using the online build service to build, and here is a little snippet of where the error is thrown:

Adding android project...
Failed to require PlatformApi instance for platform "android". Using polyfill instead.
Running command: /home/travis/.tabris-cli/platforms/android/3.0.0-beta2-dev.20190214/bin/create /home/travis/build/eclipsesource/tabris-js-build-template/build/build/cordova/platforms/android com.eclipsesource.tabris.firebase.example "Firebase Plugin Example for Tabris.js" --cli
internal/modules/cjs/loader.js:583
    throw err;
    ^
Error: Cannot find module 'cordova-common'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
    at Function.Module._load (internal/modules/cjs/loader.js:507:25)
    at Module.require (internal/modules/cjs/loader.js:637:17)
    at require (internal/modules/cjs/helpers.js:22:18)
    at Object. (/home/travis/.tabris-cli/platforms/android/3.0.0-beta2-dev.20190214/bin/create:22:20)
    at Module._compile (internal/modules/cjs/loader.js:689:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
    at Module.load (internal/modules/cjs/loader.js:599:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
    at Function.Module._load (internal/modules/cjs/loader.js:530:3)
Command finished with error code 1: /home/travis/.tabris-cli/platforms/android/3.0.0-beta2-dev.20190214/bin/create /home/travis/build/eclipsesource/tabris-js-build-template/build/build/cordova/platforms/android,com.eclipsesource.tabris.firebase.example,Firebase Plugin Example for Tabris.js,--cli
Error: /home/travis/.tabris-cli/platforms/android/3.0.0-beta2-dev.20190214/bin/create: Command failed with exit code 1
    at ChildProcess.whenDone (/home/travis/.nvm/versions/node/v10.15.1/lib/node_modules/tabris-cli/node_modules/cordova-common/src/superspawn.js:169:23)
    at ChildProcess.emit (events.js:189:13)
    at maybeClose (internal/child_process.js:970:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
The command /home/travis/.nvm/versions/node/v10.15.1/lib/node_modules/tabris-cli/node_modules/.bin/cordova exited with 1

I'm running the build service with the following settings: capture


I tried building locally too, and I got a different error. First I got the expected error that there is no google-services.json file so I downloaded it from Firebase and put it in the correct directory. I cleaned and ran it again and this is the error I'm getting now:

:app:processDebugGoogleServices
Found com.google.firebase:firebase-messaging:17.3.4, but version 16.0.7 is needed for the google-services plugin.
:app:processDebugGoogleServices FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:processDebugGoogleServices'.
> 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 16.0.7.

17 actionable tasks: 17 executed
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 13s

This error occurs with the cli at both 3.0.0-beta1 and at 3.0.0-beta1-dev.20190214

mpost commented 5 years ago

Hi Rapheal. Thanks for all your detailed feedback. We have fixed the issue you are describing in the nightly builds. So you should be able to build locally when you put nightly in your package.json. You will also need to use the nightly tabris-cli (from the master branch) and finally rename the example folder to eg .example due to a bug in the cordova-cli.

Please give it another shoot and thanks for your patients.

raphaelpreston commented 5 years ago

@mpost thanks for helping me resolve this. Unfortunately, I followed your steps and I'm still receiving errors. Here's what I did:

added 1 package and audited 1 package in 0.805s found 0 vulnerabilities

[./] Replacing variables in config.xml... [C:\Users\USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin [build/cordova] C:\Users\USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova platform add "C:\Users\USER\Documents\APP\ANDROID PLATFORM\tabris-android" --no-update-notifier Adding android project... Creating Cordova project for the Android platform: Path: platforms\android Package: com.eclipsesource.tabris.firebase.example Name: Firebase_Plugin_Example_for_Tabris.js Activity: MainActivity Android target: android-27 Subproject Path: CordovaLib Subproject Path: app Android project created with cordova-android@7.1.0 Android Studio project detected Android Studio project detected Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project Failed to restore plugin "tabris-plugin-firebase" from config.xml. You might need to try adding it again. Error: Invalid Plugin! .. needs a valid package.json --save flag or autosave detected Saving android@C:\Users\USER\Documents\APP\ANDROID PLATFORM\tabris-android into config.xml file ... The command C:\Users\USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova exited with 1 PS C:\Users\USER\Documents\APP\2-18\tabris-plugin-firebase-master.example> tabris clean Removing build/ folder PS C:\Users\USER\Documents\APP\2-18\tabris-plugin-firebase-master.example> tabris run android

[./] npm run --if-present build:android [./] npm run --if-present build [./] Copying Cordova files to build/cordova ... [./] Copying JavaScript files to build\cordova\www\app ... [build\cordova\www\app] npm install --production npm notice created a lockfile as package-lock.json. You should commit this file. npm WARN app No repository field. npm WARN app No license field.

added 1 package and audited 1 package in 0.803s found 0 vulnerabilities

[./] Replacing variables in config.xml... [C:\Users\USER\AppData\Roaming\npm\node_modules\tabris-cli\src\services] npm bin [build/cordova] C:\Users\USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova platform add "C:\Users\USER\Documents\APP\ANDROID PLATFORM\tabris-android" --no-update-notifier Adding android project... Creating Cordova project for the Android platform: Path: platforms\android Package: com.eclipsesource.tabris.firebase.example Name: Firebase_Plugin_Example_for_Tabris.js Activity: MainActivity Android target: android-27 Subproject Path: CordovaLib Subproject Path: app Android project created with cordova-android@7.1.0 Android Studio project detected Android Studio project detected Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project Installing "tabris-plugin-firebase" for android Subproject Path: CordovaLib Subproject Path: app Saved plugin info for "tabris-plugin-firebase" to config.xml --save flag or autosave detected Saving android@C:\Users\USER\Documents\APP\ANDROID PLATFORM\tabris-android into config.xml file ... [build/cordova] C:\Users\USER\AppData\Roaming\npm\node_modules\tabris-cli\node_modules.bin\cordova run android --no-update-notifier Android Studio project detected ANDROID_HOME=C:\Users\USER\AppData\Local\Android\sdk JAVA_HOME=C:\Program Files\java\jdk1.8.0_101 studio Starting a Gradle Daemon, 1 incompatible and 2 stopped Daemons could not be reused, use --status for details

BUILD SUCCESSFUL in 6s 1 actionable task: 1 executed Subproject Path: CordovaLib Subproject Path: app Starting a Gradle Daemon, 1 incompatible and 2 stopped Daemons could not be reused, use --status for details publishNonDefault is deprecated and has no effect anymore. All variants are now published. The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead. at build_7wfggksbrsnhwlupaxsh45lkt.run(C:\Users\USER\Documents\APP\2-18\tabris-plugin-firebase-master.example\build\cordova\platforms\android\app\build.gradle:151) Configuration 'compile' in project ':app' is deprecated. Use 'implementation' instead. Could not find google-services.json while looking in [src/debug] registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection) Could not find google-services.json while looking in [src/release] registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection) :CordovaLib:preBuild UP-TO-DATE :CordovaLib:preDebugBuild UP-TO-DATE :CordovaLib:compileDebugAidl :CordovaLib:compileDebugRenderscript :CordovaLib:checkDebugManifest :CordovaLib:generateDebugBuildConfig :CordovaLib:generateDebugResValues :CordovaLib:generateDebugResources :CordovaLib:packageDebugResources :CordovaLib:platformAttrExtractor :CordovaLib:processDebugManifest :CordovaLib:prepareLintJar :CordovaLib:processDebugJavaRes :app:preBuild UP-TO-DATE :app:preDebugBuild :app:compileDebugAidl :CordovaLib:packageDebugRenderscript NO-SOURCE :app:compileDebugRenderscript :app:checkDebugManifest :app:generateDebugBuildConfig :app:generateDebugResValues :app:generateDebugResources :app:processDebugGoogleServices Found com.google.firebase:firebase-messaging:17.3.4, but version 16.0.7 is needed for the google-services plugin. :app:processDebugGoogleServices FAILED

FAILURE: Build failed with an exception.

BUILD FAILED in 12s

As you can see, this is the same error as my previous comment. Also, just to be sure, I changed the id in config to match my google-services.json project ID but that didn't fix anything. I also cleared my gradle cache but that didn't help either.

mpost commented 5 years ago

Here we are looking at on oversight on our part. We will update the 3.0.0-beta1-dev.XXXX to beta2.

Update: https://github.com/eclipsesource/tabris-js-cli/commit/bb3030083ee469639ab380694ea273871085f06e

That being said, how do you "download" the zip file for the plugin? It should be sufficient to git clone and rename the "example" folder to ".example". Than run regular npm install and tabris build android

Below i have attached the build output when i run tabris build android on Windows with the nightly cli checked out from gtihub repo (and made available on the cli by running npm install and npm link inside the tabris-js-cli folder)

tabris build android
mpost@MP-Dell MINGW64 ~/git/tabris-plugin-firebase/.example (master)                                                                                                                           
$ tabris build android                                                                                                                                                                         
[./] npm run --if-present build:android                                                                                                                                                        
[./] npm run --if-present build                                                                                                                                                                
[./] Copying Cordova files to build/cordova ...                                                                                                                                                
[./] Copying JavaScript files to build\cordova\www\app ...                                                                                                                                     
[build\cordova\www\app] npm install --production                                                                                                                                               
npm WARN app No repository field.                                                                                                                                                              
npm WARN app No license field.                                                                                                                                                                 

audited 1 package in 0.761s                                                                                                                                                                    
found 0 vulnerabilities                                                                                                                                                                        

[./] Replacing variables in config.xml...                                                                                                                                                      
[./] Downloading android platform version 3.0.0-beta2-dev.20190220...                                                                                                                          
[./] Extracting platform...                                                                                                                                                                    
[C:\Users\mpost\git\tabris-js-cli\src\services] npm bin                                                                                                                                        
[build/cordova] C:\Users\mpost\git\tabris-js-cli\node_modules\.bin\cordova platform add C:\Users\mpost\.tabris-cli\platforms\android\3.0.0-beta2-dev.20190220 --no-update-notifier             
Adding android project...                                                                                                                                                                      
Creating Cordova project for the Android platform:                                                                                                                                             
        Path: platforms\android                                                                                                                                                                
        Package: com.eclipsesource.tabris.firebase.example                                                                                                                                     
        Name: Firebase_Plugin_Example_for_Tabris.js                                                                                                                                            
        Activity: MainActivity                                                                                                                                                                 
        Android target: android-28                                                                                                                                                             
Subproject Path: CordovaLib                                                                                                                                                                    
Subproject Path: app                                                                                                                                                                           
Android project created with cordova-android@8.0.0                                                                                                                                             
Discovered plugin "tabris-plugin-firebase" in config.xml. Adding it to the project                                                                                                             
Installing "tabris-plugin-firebase" for android                                                                                                                                                
Subproject Path: CordovaLib                                                                                                                                                                    
Subproject Path: app                                                                                                                                                                           
Saved plugin info for "tabris-plugin-firebase" to config.xml                                                                                                                                   
--save flag or autosave detected                                                                                                                                                               
Saving android@C:\Users\mpost\.tabris-cli\platforms\android\3.0.0-beta2-dev.20190220 into config.xml file ...                                                                                  
[build/cordova] C:\Users\mpost\git\tabris-js-cli\node_modules\.bin\cordova build android --no-update-notifier                                                                                  
Checking Java JDK and Android SDK versions                                                                                                                                                     
ANDROID_SDK_ROOT=undefined (recommended setting)                                                                                                                                               
ANDROID_HOME=C:\Users\mpost\AppData\Local\Android\android-sdk (DEPRECATED)                                                                                                                     
:wrapper                                                                                                                                                                                       

BUILD SUCCESSFUL                                                                                                                                                                               

Total time: 1.798 secs                                                                                                                                                                         
Subproject Path: CordovaLib                                                                                                                                                                    
Subproject Path: app                                                                                                                                                                           

> Configure project :app                                                                                                                                                                       
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)                                                                                                       
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)                                                                                                       

> Transform kotlin-stdlib-common.jar (org.jetbrains.kotlin:kotlin-stdlib-common:1.3.21) with JetifyTransform                                                                                   
> Transform kotlin-stdlib-common.jar (org.jetbrains.kotlin:kotlin-stdlib-common:1.3.21) with IdentityTransform                                                          

...build output continues...

raphaelpreston commented 5 years ago

Whoops, it appears that I had forgotten to run npm i in my previous step. However, I went back and tried again with 3.0.0-beta1-dev.20190217 (running npm i this time), but it still failed on app:ProcessDebugGoogleServices with the same error as my previous comment. So that wasn't the problem.

Also, to answer your question, I'm downloading the plugin from the repo itself in .zip file format, and then extracting it. I realize I could clone it with git too, but I prefer this method.

Steps

At this point, I took a look at your build output and realized that our cordova-android versions were differing, yours being at 8.0.0 and mine at 7.1.0. Then I remembered that I still had my TABRIS_ANDROID_VERSION environment variable set from this comment. So, I deleted the environmental variable, and then performed the following.

This fixed the problem. The APK was build successfully and deployed to my device, and the app ran successfully and the token was printed on the screen.


So, in closing, these are the specific instructions that I follow to make the entire thing work from scratch. I'm not going to be renaming the /example folder because even when I rename it still says it can't install the plugin.

Steps


I also tested this with tabris-cli@3.0.0-beta1 and it works too. Seems like the issue was needing the cordova-android at 8.0.0 and not 7.1.0, meaning that as long as the tabris dependency in package.json is nightly, it should work.

Thank you all for the help. I'll leave this open for you to close if you'd like.

mpost commented 5 years ago

Good to hear that we have solved the issue. It is unfortunate that the one tipp i gave previously (about the env var) lead to another error down the road.

I was hoping to see the output of a working build would give a clue of what is going on.

Btw.... installing the tabris-cli@nightly now will give you the correct version name "beta2" as you can see under the "versions" tab https://www.npmjs.com/package/tabris-cli

mpost commented 5 years ago

If you feel the problems are resolved you should close the issue.