Android build failed error : :app:mergeDebugResources

i’m trying to build my app in android but getting this error

:app:mergeDebugResources

[string/fb_app_id] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/facebookconnect.xml   [string/fb_app_id] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/strings.xml: Error: Duplicate resources
[string/fb_app_name] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/facebookconnect.xml [string/fb_app_name] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/strings.xml: Error: Duplicate resources
:app:mergeDebugResources FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:mergeDebugResources'.
> [string/fb_app_id] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/facebookconnect.xml [string/fb_app_id] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/strings.xml: Error: Duplicate resources
  [string/fb_app_name] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/facebookconnect.xml       [string/fb_app_name] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/strings.xml: Error: Duplicate resources

* 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 18s
21 actionable tasks: 4 executed, 17 up-to-date
(node:3068) UnhandledPromiseRejectionWarning: Error: /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/gradlew: Command failed with exit code 1 Error output:
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:mergeDebugResources'.
> [string/fb_app_id] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/facebookconnect.xml [string/fb_app_id] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/strings.xml: Error: Duplicate resources
  [string/fb_app_name] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/facebookconnect.xml       [string/fb_app_name] /Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/strings.xml: Error: Duplicate resources

* 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 18s
    at ChildProcess.whenDone (/Users/anspireagency/Dropbox/Doctory_Project/platforms/android/cordova/node_modules/cordova-common/src/superspawn.js:169:23)
    at emitTwo (events.js:126:13)
    at ChildProcess.emit (events.js:214:7)
    at maybeClose (internal/child_process.js:925:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
(node:3068) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:3068) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.```


ionic info 

cli packages: (/usr/local/lib/node_modules)

@ionic/cli-utils  : 1.19.2
ionic (Ionic CLI) : 3.20.0

global packages:

cordova (Cordova CLI) : 8.0.0

local packages:

@ionic/app-scripts : 3.1.8
Cordova Platforms  : android 7.0.0 ios 4.5.4
Ionic Framework    : ionic-angular 3.9.2

System:

Android SDK Tools : 26.1.1
ios-deploy        : 1.9.2
ios-sim           : 6.1.2
Node              : v8.11.3
npm               : 5.6.0
OS                : macOS High Sierra
Xcode             : Xcode 9.2 Build version 9C40b

Environment Variables:

ANDROID_HOME : /Users/anspireagency/Library/Android/sdk/

Misc:

backend : pro```

any help guys please ?
@anna_liebt

Remove the plugins and platform.
Add them again

Hello,

no idea. If I follow the error message, then it seem it has something to do with your resources.

type or paste code here
```Error: Duplicate resources
Take look to the files erorr message provides and it entrys. Maybe you must only delete the doubbled entry.

Maybe it helps delete content of www folder and .sourcemaps. Additional  remove created resources in resource folder and in android and ios folder and xreate resources again. Maybe you should follow advice of smalwe. Maybe...

Best regards, anna-liebt

nothing change … same error

ok … thank you anna

Hello,
okay thank, it’s working?
I guess it is not working. In that case post your

/Users/anspireagency/Dropbox/Doctory_Project/platforms/android/app/src/main/res/values/strings.xml

Maybe someone see what is wrong with it.

Also no luck, with @smalwe 's advice?

Best regards, anna-liebt

hi anna
i have got BUILD SUCCESSFUL but now facebook not working
but facebook in ios working

this from config.xml
27%20PM
ionic info

cli packages: (/usr/local/lib/node_modules)

    @ionic/cli-utils  : 1.19.2
    ionic (Ionic CLI) : 3.20.0

global packages:

    cordova (Cordova CLI) : 8.0.0

local packages:

    @ionic/app-scripts : 3.1.8
    Cordova Platforms  : android 7.0.0 ios 4.5.4
    Ionic Framework    : ionic-angular 3.9.2

System:

    Android SDK Tools : 26.1.1
    ios-deploy        : 1.9.2
    ios-sim           : 6.1.2
    Node              : v8.11.3
    npm               : 5.6.0
    OS                : macOS High Sierra
    Xcode             : Xcode 9.2 Build version 9C40b

Environment Variables:

    ANDROID_HOME : /Users/anspireagency/Library/Android/sdk/

Misc:

    backend : pro

hello,
no idea because “it is not working” is not much information. Maybe, because it was something going wrong with entries you never have touched ( I guess), it is an idea to reinstall facebook related stuff.

Best regards, anna-liebt

someone has been able to solve the problem, I am having the same problem with facebook plugin