flipper icon indicating copy to clipboard operation
flipper copied to clipboard

Jetpack Compose plugin artifact pulls an unpublished dependency

Open rciovati opened this issue 1 year ago • 5 comments

🐛 Bug Report

Related to https://github.com/facebook/flipper/issues/2366#issuecomment-1842473245

The Jetpack Compose plugin has a dependency on an .aar that is not published, making it currently unusable:

https://github.com/facebook/flipper/blob/6b44de3fb395db990c851cc6a25521cc23fb0323/android/plugins/jetpack-compose/build.gradle#L35

To Reproduce

  • Add the dependency with debugImplementation("com.facebook.flipper:flipper-jetpack-compose-plugin:0.250.0")
  • Build the app and observe the error:
> Could not resolve all files for configuration ':app:standardDebugRuntimeClasspath'.
   > Could not find flipper:inspection-lib:unspecified.
     Searched in the following locations:
       - file:/Users/user/.m2/repository/flipper/inspection-lib/unspecified/inspection-lib-unspecified.pom
       - file:/Users/user/ghq/omitted/Frontpage-Android/jetified-libs/flipper/inspection-lib/unspecified/inspection-lib-unspecified.pom
       - https://omitted/artifactory/omitted-maven-prod/flipper/inspection-lib/unspecified/inspection-lib-unspecified.pom
     Required by:
         project :app > com.facebook.flipper:flipper-jetpack-compose-plugin:0.250.0

Environment

Not relevant

rciovati avatar Jun 14 '24 08:06 rciovati

Hi folks, wanted to see if any updates or workarounds, thank you

digitalbuddha avatar Jul 17 '24 16:07 digitalbuddha

Any update on this?

lx-felipe avatar Sep 18 '24 15:09 lx-felipe

Hi everyone. I have published that library and you can run the compose plugin as described here https://github.com/0xera/inspection-lib

0xera avatar Sep 23 '24 07:09 0xera

Btw, thanks to the Flipper team for the great plugin

0xera avatar Sep 25 '24 19:09 0xera

I found that inspection-lib could be replaced with androidx.inspection:inspection lib, but cannot be resolved from maven. https://mvnrepository.com/artifact/androidx.inspection/inspection/1.0.0

Another solution, if you don't want to use aar from external repository: Download .aar from androidx.dev: https://androidx.dev/snapshots/builds/12527636/artifacts androidx.inspection-inspection-all-12527636-1.0.0-SNAPSHOT.zip Include aar file in project libs dir.

    implementation(group = "", name = "inspection-1.0.0-20241021.073440-1", ext = "aar")

    modules {
        module("flipper:inspection-lib") {
            replacedBy("androidx.inspection:inspection")
        }
    }
    
    implementation("com.facebook.flipper:flipper-jetpack-compose-plugin:0.267.1") {
        exclude(group = "flipper", module = "inspection-lib")
    }

darekbx avatar Oct 21 '24 10:10 darekbx