ChatKit icon indicating copy to clipboard operation
ChatKit copied to clipboard

Unable to resolve com.google.android:flexbox:1.0.0 in Gradle build

Open faithererer opened this issue 1 year ago • 7 comments

Describe the bug I am encountering an issue when trying to build my Android project. The error states that it cannot resolve the dependency com.google.android:flexbox:1.0.0.

Error message:

* What went wrong:
Execution failed for task ':app:processDebugAndroidTestManifest'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
   > Could not find com.google.android:flexbox:1.0.0.
     Searched in the following locations:
       - https://jitpack.io/com/google/android/flexbox/1.0.0/flexbox-1.0.0.pom
       - https://dl.google.com/dl/android/maven2/com/google/android/flexbox/1.0.0/flexbox-1.0.0.pom
       - https://repo.maven.apache.org/maven2/com/google/android/flexbox/1.0.0/flexbox-1.0.0.pom
     Required by:
         project :app
   > Could not find com.google.android:flexbox:1.0.0.
     Searched in the following locations:
       - https://jitpack.io/com/google/android/flexbox/1.0.0/flexbox-1.0.0.pom
       - https://dl.google.com/dl/android/maven2/com/google/android/flexbox/1.0.0/flexbox-1.0.0.pom
       - https://repo.maven.apache.org/maven2/com/google/android/flexbox/1.0.0/flexbox-1.0.0.pom
     Required by:
         project :app > com.github.stfalcon-studio:Chatkit:0.4.1

To Reproduce Steps to reproduce the behavior:

Add the dependency implementation 'com.github.stfalcon-studio:Chatkit:0.4.1' to the build.gradle file. Sync the project with Gradle files. The build fails with the above error message. Expected behavior The build should successfully resolve the dependency for the Flexbox library.

Screenshots N/A

Smartphone (please complete the following information):

Device: [e.g. Pixel 4] OS: [e.g. Android 10] Library Version: [e.g. 3.0.0]

faithererer avatar Jun 23 '24 14:06 faithererer

Facing same issue

anirudhawonderslate avatar Jul 12 '24 06:07 anirudhawonderslate

Any updates on this? I can't build my project

RoberV avatar Aug 05 '24 10:08 RoberV

I'm in the same situation.

ricardopereira avatar Aug 09 '24 14:08 ricardopereira

Facing same issue

mshaheer92 avatar Aug 12 '24 02:08 mshaheer92

Looks like a lot of old packages were removed from jcenter archives. You can fork the project and bump up the flexbox dependency from 1.0.0 to 3.0.0 in the build.gradle file:

implementation "com.google.android.flexbox:flexbox:3.0.0"

also add the google maven repo https://maven.google.com in the project build.gradle file:

allprojects {
    repositories {
        jcenter()
        google()
        maven { url "https://jitpack.io" }
        maven { url "https://maven.google.com"}
    }
}

Make a aar release build and include that instead of the current chatkit dependency, I also needed to add the flexbox dependency to the project using chatkit.

KhoalaS avatar Aug 17 '24 11:08 KhoalaS

Anyone still facing issue - Here is forked version until it is resolved on this repo

Jitpack-Chatkit github-chatkit

harsewaksingh13 avatar Sep 20 '24 11:09 harsewaksingh13

the easiest way is clone this problem and import as library, it's better when you need to modify some library's method, i am sure everyone need to modify it, such as 'grouping avatar by date' function

fukemy avatar May 12 '25 09:05 fukemy