braze-inc / braze-cordova-sdk

Public repo for the Braze Cordova SDK
https://www.braze.com
Other
21 stars 63 forks source link

Error in cordova build ios #63

Closed danielraban closed 3 years ago

danielraban commented 3 years ago

Getting an error on the plugin when building ios


    CompileC /Users/user/Library/Developer/Xcode/DerivedData/*-fxbgdyqqvfwighamjjjqkirwzpya/Build/Intermediates.noindex/*.build/Debug-iphonesimulator/*.build/Objects-normal/x86_64/IDFADelegate.o /Users/user/*/*/platforms/ios/*/Plugins/cordova-plugin-appboy/IDFADelegate.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
xcodebuild: Command failed with exit code 65
[ERROR] An error occurred while running subprocess cordova.

        cordova build ios exited with exit code 65.
radixdev commented 3 years ago

Can you share which version of the cordova plugin you're using?

danielraban commented 3 years ago

@radixdev

cordova plugin add https://github.com/appboy/appboy-cordova-sdk#master

danielraban commented 3 years ago

@radixdev it also fails for android


WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'.
It will be removed in version 5.0 of the Android Gradle plugin.
For more information, see http://d.android.com/r/tools/update-dependency-configurations.html.

FAILURE: Build failed with an exception.

* Where:
Script '/Users/user/hathway/panda-ui/platforms/android/cordova-plugin-appboy/panda-build-extras.gradle' line: 28

* What went wrong:
A problem occurred evaluating project ':app'.
> Failed to apply plugin [class 'com.google.gms.googleservices.GoogleServicesPlugin']
   > Cannot add extension with name 'googleServices', as there is an extension already registered with that name.

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

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

BUILD FAILED in 923ms
Command failed with exit code 1: /Users/user/hathway/panda-ui/platforms/android/gradlew cdvBuildDebug -b /Users/user/hathway/panda-ui/platforms/android/build.gradle
Error: Command failed with exit code 1: /Users/user/hathway/panda-ui/platforms/android/gradlew cdvBuildDebug -b /Users/user/hathway/panda-ui/platforms/android/build.gradle
    at makeError (/Users/user/hathway/panda-ui/platforms/android/cordova/node_modules/execa/lib/error.js:59:11)
    at handlePromise (/Users/user/hathway/panda-ui/platforms/android/cordova/node_modules/execa/index.js:114:26)
    at process._tickCallback (internal/process/next_tick.js:68:7)
[ERROR] An error occurred while running subprocess cordova.

        cordova build android --verbose exited with exit code 1.
iliraga commented 3 years ago

Almost our full team (5 developers) have the same issue. We worked around by removing the cordova plugin for development, and re-adding it for the actual release. But it's very annoying, any workaround for this?

danielraban commented 3 years ago

@iliraga we have a much more detailed thread going on here. https://github.com/Appboy/appboy-cordova-sdk/issues/52