Reputation: 3712
I am trying to use Kotlin within my existing android project. It uses many third party libraries like Android Annotations, Dagger, Glide etc. After making few necessary standard changes in build.gradle file I am getting this error.
error: no suitable constructor found for RequestManager(Glide,Lifecycle,RequestManagerTreeNode,Context) constructor RequestManager.RequestManager(Glide,Lifecycle,RequestManagerTreeNode) is not applicable (actual and formal argument lists differ in length) constructor RequestManager.RequestManager(Glide,Lifecycle,RequestManagerTreeNode,RequestTracker,ConnectivityMonitorFactory) is not applicable (actual and formal argument lists differ in length)
This error is in the auto generated file GlideRequest.java. I am not getting any clue how to fix this. What possibly I could be missing here? Any help is appreciated.
Upvotes: 0
Views: 301
Reputation: 3712
I was making a silly mistake which caused this error. In case if any one else runs into similar issue, make sure that library and it's compiler(kapt/annotation processor) using the same version. e.g-
kapt "com.github.bumptech.glide:compiler:$glideVersion"
compile com.github.bumptech.glide:glide:$glideVersion"
I had two different versions above by mistake.
Upvotes: 3