facebook / flipper

A desktop debugging platform for mobile developers.
https://fbflipper.com/
MIT License
13.36k stars 955 forks source link

[maven] flipper-fresco-plugin not bumped to 0.183.0 #4565

Closed RichardFevrier closed 1 year ago

RichardFevrier commented 1 year ago

🐛 Bug Report

Hello, flipper-fresco-plugin has not been updated to 0.183.0 on maven resulting on react-native builds fail. Would you mind bumping the version there? 🙂

Best regards

passy commented 1 year ago

The Fresco plugin is no longer published together with Flipper itself. Can you share where the build fails?

RichardFevrier commented 1 year ago

If you look into the latest build.gradle (under android/app/) produced by npx react-native init ProjectName You will find this:

dependencies {
    // The version of react-native is set by the React Native Gradle Plugin
    implementation("com.facebook.react:react-android")

    implementation("androidx.swiperefreshlayout:swiperefreshlayout:1.0.0")

    debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}")
    debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
        exclude group:'com.squareup.okhttp3', module:'okhttp'
    }

    debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}")
    if (hermesEnabled.toBoolean()) {
        implementation("com.facebook.react:hermes-android")
    } else {
        implementation jscFlavor
    }
}

So probably either flipper-fresco-plugin needs to be bumped or the latest react-native-cli needs to remove this dependency.

passy commented 1 year ago

I see. We won't be bumping the dependency going forwards so the correct way for now would be to hard-code the Fresco plugin version to the last published release in the template.

cortinico commented 1 year ago

I see. We won't be bumping the dependency going forwards so the correct way for now would be to hard-code the Fresco plugin version to the last published release in the template.

Hey, Nicola from React Native here 👋

@passy what's the reason why flipper-fresco-plugin won't be bumped anymore in the future?

How about just removing the flipper-fresco-plugin entirely from the template. and let to the user the possibility to eventually add it if they wish

passy commented 1 year ago

Hey @cortinico! 👋

We've moved Fresco out of this repository into theirs. So the release cycle is now no longer coupled with that if Flipper.

arnaudambro commented 1 year ago

what is the solution then ?

cortinico commented 1 year ago

what is the solution then ?

For React Native 0.72, we'll ship with Flipper 0.182.0 so no changes are required on your end. If you want to bump the Flipper version, you'll have to edit your android/app/build.gradle as follows:

dependencies {
    // The version of react-native is set by the React Native Gradle Plugin
    implementation("com.facebook.react:react-android")

    implementation("androidx.swiperefreshlayout:swiperefreshlayout:1.0.0")

    debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}")
    debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
        exclude group:'com.squareup.okhttp3', module:'okhttp'
    }

-   debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}")
+   debugImplementation("com.facebook.flipper:flipper-fresco-plugin:0.182.0")
}
FusionReaction commented 1 year ago

@arnaudambro one solution would be to update your android/gradle.properties file with the following, anything higher than version 0.182.0 will fail at the moment

# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.182.0
mark-zacharias commented 1 year ago

This took a while to figure out for me. I've created a PR I think will help most folks figure this out sooner. https://github.com/facebook/flipper/pull/4734

tfreitas90 commented 1 year ago

Should we do what he says here? https://github.com/facebook/flipper/pull/4734#issuecomment-1554292382

cortinico commented 1 year ago

React Native 0.73 will contain the bump of Flipper to the correct version + the bump of the Fresco plugin.

This issue can be closed as there are no actionables