I upgraded to kotlin 1.9.10 and AGP 8.1.0 and Anvi...
# squarelibraries
d
I upgraded to kotlin 1.9.10 and AGP 8.1.0 and Anvil 2.4.6 and now I get this error on every incremental compilation which is very weird
Copy code
error: ComponentProcessingStep was unable to process 'com.example.app.android.di.AppComponent' because 'anvil.module.com.example.feature.home.routing.di.HomeFlowComponentAnvilModule' could not be resolved.
  
  Dependency trace:
      => element (INTERFACE): com.example.feature.home.routing.di.HomeFlowComponent
      => annotation: @dagger.Subcomponent(modules={com.example.feature.home.routing.di.HomeFlowModule, com.example.feature.home.ui.di.HomeUiModule, anvil.module.com.example.feature.home.routing.di.HomeFlowComponentAnvilModule})
      => annotation value (TYPE_ARRAY): modules={com.example.feature.home.routing.di.HomeFlowModule, com.example.feature.home.ui.di.HomeUiModule, anvil.module.com.example.feature.home.routing.di.HomeFlowComponentAnvilModule}
      => annotation value (TYPE): modules=anvil.module.com.example.feature.home.routing.di.HomeFlowComponentAnvilModule
Only clean builds are successful, then it repeats again. I don't see any bugs on github about this, so I might have messed up somehow, but I'm not even sure what to look for. Any hints?
k
Dagger has been wonky for me as well like this, have to occasionally do
--rerun-tasks
😕
👀 1
r
Kotlin 1.8.20 came with a new incremental compiler. You might be running into https://github.com/square/anvil/issues/693
d
Thank you! I will try to disable this new incremental compiler and see how it goes.