0

I have module in Android app. This module uses the Airship library. I have imported this module in my project and used it.

Scenario: If both my app and module gradle has the Airship library, everything works fine.

But, I think adding the same library at both places does't make sense, hence i removed it from the the app gradle (As the app does not have direct dependency on Airship lib). But app is crashing with the following error

java.lang.NoClassDefFoundError: Failed resolution of: Lcom/urbanairship/AirshipConfigOptions;
abhishek maharajpet
  • 482
  • 1
  • 4
  • 18
  • So if it works when its in both the app and the module but not when its only in the module- doesn't that pretty much tell you what the solution should be? – Gabe Sechan Dec 22 '21 at 08:09
  • I am a little confused here. If we are creating separate module to handle a specific functionality, why is it necessary for the app gradle to include dependencies that are only required by module gradle? – abhishek maharajpet Dec 22 '21 at 11:50
  • similar question answered here https://stackoverflow.com/questions/36916991/transitive-dependencies-for-local-aar-library – abhishek maharajpet Dec 23 '21 at 03:40

0 Answers0