zendesk / react-native-sunshine-conversations

React Native wrapper for Smooch.io
MIT License
36 stars 26 forks source link

Android dependency 'com.github.bumptech.glide:glide' has different version for the compile (4.6.1) and runtime (4.7.1) classpath. You should manually set the same version via DependencyResolution #60

Closed shtefanilie closed 5 years ago

shtefanilie commented 5 years ago

Ok, so I did what the Android instructions asked for, and after running react-native run-android I get this error:

Execution failed for task ':app:preDebugBuild'.
> Android dependency 'com.github.bumptech.glide:glide' has different version for the compile (4.6.1) and runtime (4.7.1) classpath. You should manually set the same version via DependencyResolution

I then wenrt into build.gradle and added these two lines above the implements for smooch:

    implementation 'com.github.bumptech.glide:glide:4.7.1'
    annotationProcessor 'com.github.bumptech.glide:compiler:4.7.1'

The error that I get now is:

android/app/src/main/AndroidManifest.xml:45:13-72 Error:
        Attribute provider#android.support.v4.content.FileProvider@authorities value=(com.company.SMOOCH_FILE_PROVIDER) from [io.smooch:ui:5.14.4] AndroidManifest.xml:45:13-72
        is also present at [:rn-fetch-blob] AndroidManifest.xml:38:13-60 value=(com.company.provider).
        Suggestion: add 'tools:replace="android:authorities"' to <provider> element at AndroidManifest.xml:43:9-51:20 to override.
android/app/src/main/AndroidManifest.xml:50:17-51 Error:
        Attribute meta-data#android.support.FILE_PROVIDER_PATHS@resource value=(@xml/file_paths) from [io.smooch:ui:5.14.4] AndroidManifest.xml:50:17-51
        is also present at [:rn-fetch-blob] AndroidManifest.xml:43:17-55 value=(@xml/provider_paths).
        Suggestion: add 'tools:replace="android:resource"' to <meta-data> element at AndroidManifest.xml to override.
shtefanilie commented 5 years ago

Problem related to another dependency rn-fetch-blob which uses android support v4 instead of v7. To fix, add the following to your AndroidManifest.xml:

  1. xmlns:tools="http://schemas.android.com/tools" to the manifest tag 2.<meta-data android:name="com.google.android.gms.version" android:value="@integer/google_play_services_version" /> inside the aplication tag 3.tools:node="replace" to the application tag.