Failed to resolve RXJava dependency

I am trying to run the following project: https://github.com/amitshekhariitbhu/RxJava2-Android-Samples

Relations:

dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) testCompile 'junit:junit:4.12' compile 'com.android.support:appcompat-v7:24.1.1' compile 'io.reactivex.rxjava2:rxjava:2.0.0' compile 'io.reactivex.rxjava2:rxandroid:2.0.0' } 

But I get the following error.

Error: (26, 13) Failed to resolve: io.reactivex.rxjava2: rxandroid: 2.0.0 Show in file
Show in Project Structure Dialog

Am I doing something wrong?

+5
source share
1 answer

I had a similar problem with RxKotlin, the IDE had Gradle offline. (Settings-> Gradle → Disable Offline).

In addition, I suggest checking that you have the correct version here .

This helped me set up RxKotlin because there was only a xyz version.

Gradle import work:

compile 'io.reactivex:rxkotlin:2.0.0-RC1'

0
source

Source: https://habr.com/ru/post/1261004/


All Articles