Android Dagger2 + OkHttp + Retrofit dependency cycle error
Hey there I am using Dagger2 , Retrofit and OkHttp and I am facing dependency cycle issue. When providing OkHttp : @Provides @ApplicationScope OkHttpClient provideOkHttpClient(TokenAuthenticator auth,Dispatcher dispatcher){ return new OkHttpClient.Builder() .connectTimeout(Constants.CONNECT_TIMEOUT, TimeUnit.SECONDS) .readTimeout(Constants.READ_TIMEOUT,TimeUnit.SECONDS) .writeTimeout(Constants.WRITE_TIMEOUT,TimeUnit.SECONDS) .authenticator(auth) .dispatcher(dispatcher) .build(); } When providing Retrofit : @Provides @ApplicationScope Retrofit provideRetrofit(Resources resources,Gson gson,