https://kotlinlang.org logo
#android
Title
# android
r

Riccardo Montagnin

10/18/2018, 9:20 PM
During the build I get the following error:
Copy code
> Task :app:kaptGenerateStubsDebugKotlin
e: error: cannot access Retrofit
  class file for retrofit2.Retrofit not found
  Consult the following stack trace for details.
  com.sun.tools.javac.code.Symbol$CompletionFailure: class file for retrofit2.Retrofit not found
The problem is that that class is present inside the following dependency:
implementation "com.squareup.retrofit2:retrofit:$retrofit_version"
When I switch from
implementation
to
compile
, the error disappears. What could it be?