thebergamo / react-native-fbsdk-next

MIT License
633 stars 165 forks source link

support version 17 of facebook sdk with privacy manifests #507

Closed brainbicycle closed 3 weeks ago

brainbicycle commented 1 month ago

🐛 Bug Report

Apple is going to start enforcing new requirements on commonly used sdks May 1, 2024: https://developer.apple.com/support/third-party-SDK-requirements/ The Facebook sdk belongs to this list. Version 17 of the Facebook sdk includes privacy manifests to comply with these requirements. Currently this wrapper only supports up to version 16. (I know this just got released just want to make sure this is on radar, thanks for the library!).

To Reproduce

Install this library in your project. Generate a privacy report in Xcode and/or submit a beta to TestFlight.

Expected Behavior

The privacy manifest for the Facebook sdk is included in this privacy report. Additionally on submitting a beta warnings are not generated by App Store connect regarding the apis used by the Facebook sdk.

Code Example

N/A

Environment

N/A

uzaymacar commented 1 month ago

+1, thanks for opening the issue @brainbicycle!

fengmin2611 commented 1 month ago

I hope to hear about plans for a release that supports Facebook SDK 17 soon. Thank you,

15matias15 commented 1 month ago

check #506

TowhidKashem commented 1 month ago

Really looking forward to this one since this is the only facebook sdk for RN atm!

RKakushev commented 3 weeks ago

@mikehardy hi. Will you update this library till May 1, 2024?

joaquinvaz commented 3 weeks ago

506 there is a PR open for this already, only needs merge

mikehardy commented 3 weeks ago

Everyone's in luck, I need this for my app ;-) Haven't checked in this repo in a while, lemme see about getting the native SDK up to date

mikehardy commented 3 weeks ago

Should be released in v13 which just launched, this issue wasn't connected to the PR that closed it but was #506

Please please please 🙏 if there are problems, post PRs - took me a big time box to manage this repo today and I do not have a lot of time to test+fix things, we're a community and I/we need the help. :-) thank you

brainbicycle commented 3 weeks ago

appreciate it thanks so much! will try to more proactively PR in future

avyasradicle commented 2 weeks ago

Pod install is throwing error:

[!] CocoaPods could not find compatible versions for pod "FBSDKLoginKit": In snapshot (Podfile): FBSDKLoginKit (= 16.3.1, ~> 16.3.1)

In Podfile: react-native-fbsdk-next (from ../node_modules/react-native-fbsdk-next) was resolved to 13.0.0, which depends on react-native-fbsdk-next/Login (= 13.0.0) was resolved to 13.0.0, which depends on FBSDKLoginKit (~> 17.0.0)

Specs satisfying the FBSDKLoginKit (= 16.3.1, > 16.3.1), FBSDKLoginKit (> 17.0.0) dependency were found, but they required a higher minimum deployment target.

We are not using facebook login functionality in our app. We are using it just to enable facebook ads.

efstathiosntonas commented 2 weeks ago

@avyasradicle run pod update on the ios folder

nemapranay commented 1 day ago

Hi, it worked fine in iOS but having issues with android.

as i am trying to run android build

react-native:0.64.2 react-native-fbsdk-next: 13.0.0

issue:

app/node_modules/react-native-fbsdk-next/android/src/main/java/com/facebook/reactnative/androidsdk/RCTLoginButton.java:66: error: cannot find symbol mEventDispatcher.dispatchEvent(new RCTLoginButtonEvent(UIManagerHelper.getSurfaceId(context), getId(), event)); ^ symbol: method getSurfaceId(ReactContext) location: class UIManagerHelper

/RCTLoginButton.java:89: error: cannot find symbol mEventDispatcher.dispatchEvent(new RCTLoginButtonEvent(UIManagerHelper.getSurfaceId(context), getId(), event)); ^ symbol: method getSurfaceId(ReactContext) location: class UIManagerHelper

app/node_modules/react-native-fbsdk-next/android/src/main/java/com/facebook/reactnative/androidsdk/RCTLoginButton.java:101: error: cannot find symbol mEventDispatcher.dispatchEvent(new RCTLoginButtonEvent(UIManagerHelper.getSurfaceId(context), getId(), event)); ^ symbol: method getSurfaceId(ReactContext)

app/node_modules/react-native-fbsdk-next/android/src/main/java/com/facebook/reactnative/androidsdk/RCTLoginButtonEvent.java:13: error: no suitable constructor found for Event(int,int) super(surfaceId,viewTag); ^ constructor Event.Event() is not applicable (actual and formal argument lists differ in length) constructor Event.Event(int) is not applicable (actual and formal argument lists differ in length)

app/node_modules/react-native-fbsdk-next/android/src/main/java/com/facebook/reactnative/androidsdk/FBProfileModule.java:50: warning: non-varargs call of varargs method with inexact argument type for last parameter; callback.invoke(null);

Like this 7 errors i got

Can some one please help here with solution ? CC: @mikehardy @efstathiosntonas

mikehardy commented 1 day ago

The expectation that react native 0.64 will work is mildly humorous. Way out of support