Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash in FBSDKRestrictiveDataFilterManager.m line 80 #1374

Closed
5 tasks done
clayjonezie opened this issue May 6, 2020 · 139 comments
Closed
5 tasks done

Crash in FBSDKRestrictiveDataFilterManager.m line 80 #1374

clayjonezie opened this issue May 6, 2020 · 139 comments

Comments

@clayjonezie
Copy link

clayjonezie commented May 6, 2020

Checklist

Environment

Describe your dev environment here, giving as many details as possible. If you have them, make sure to include:

  • Xcode Version: 11.4.1
  • FBSDK 6.5.0 (at time of build)

Goals

What do you want to achieve?

We are using FBSDK in our app as an authentication option

Expected Results

What do you expect to happen?

I would like FBSDK to not crash

Actual Results

What actually happened? Can you provide a stack trace?

FBSDK is crashing at a large volume.

Steps to Reproduce

What are the steps necessary to reproduce this issue?

I'm not sure yet, this is happening intermittently (but at a high volume) in the field.

Code Samples & Details

Fatal Exception: NSInvalidArgumentException
0  CoreFoundation                 0x1a5c2896c __exceptionPreprocess
1  libobjc.A.dylib                0x1a5941028 objc_exception_throw
2  CoreFoundation                 0x1a5b26dcc -[NSOrderedSet initWithSet:copyItems:]
3  CoreFoundation                 0x1a5c2d048 ___forwarding___
4  CoreFoundation                 0x1a5c2f3a0 _CF_forwarding_prep_0
5  FBSDKCoreKit                   0x1039830cc +[FBSDKRestrictiveDataFilterManager updateFilters:] + 80 (FBSDKRestrictiveDataFilterManager.m:80)
6  FBSDKCoreKit                   0x103985f34 +[FBSDKServerConfigurationManager processLoadRequestResponse:error:appID:] + 240 (FBSDKServerConfigurationManager.m:240)
7  FBSDKCoreKit                   0x103985750 __78+[FBSDKServerConfigurationManager loadServerConfigurationWithCompletionBlock:]_block_invoke + 161 (FBSDKServerConfigurationManager.m:161)
8  FBSDKCoreKit                   0x103969c5c -[FBSDKGraphRequestMetadata invokeCompletionHandlerForConnection:withResults:error:] + 41 (FBSDKGraphRequestMetadata.m:41)
9  FBSDKCoreKit                   0x103967534 __82-[FBSDKGraphRequestConnection processResultBody:error:metadata:canNotifyDelegate:]_block_invoke + 806 (FBSDKGraphRequestConnection.m:806)
10 FBSDKCoreKit                   0x103967428 -[FBSDKGraphRequestConnection processResultBody:error:metadata:canNotifyDelegate:] + 839 (FBSDKGraphRequestConnection.m:839)
11 FBSDKCoreKit                   0x103967038 __64-[FBSDKGraphRequestConnection completeWithResults:networkError:]_block_invoke + 788 (FBSDKGraphRequestConnection.m:788)
12 CoreFoundation                 0x1a5bfa66c __NSARRAY_IS_CALLING_OUT_TO_A_BLOCK__
13 CoreFoundation                 0x1a5af822c -[__NSArrayM enumerateObjectsWithOptions:usingBlock:]
14 FBSDKCoreKit                   0x103966dfc -[FBSDKGraphRequestConnection completeWithResults:networkError:] + 767 (FBSDKGraphRequestConnection.m:767)
15 FBSDKCoreKit                   0x1039662b0 -[FBSDKGraphRequestConnection completeFBSDKURLSessionWithResponse:data:networkError:] + 634 (FBSDKGraphRequestConnection.m:634)
16 FBSDKCoreKit                   0x10396443c __36-[FBSDKGraphRequestConnection start]_block_invoke_3 + 242 (FBSDKGraphRequestConnection.m:242)
17 libdispatch.dylib              0x1a58ccb7c _dispatch_call_block_and_release
18 libdispatch.dylib              0x1a58cdfd8 _dispatch_client_callout
19 libdispatch.dylib              0x1a58d9cc8 _dispatch_main_queue_callback_4CF
20 CoreFoundation                 0x1a5ba3cc8 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__
21 CoreFoundation                 0x1a5b9ea24 __CFRunLoopRun
22 CoreFoundation                 0x1a5b9df40 CFRunLoopRunSpecific
23 GraphicsServices               0x1afe2e534 GSEventRunModal
24 UIKitCore                      0x1a9d29580 UIApplicationMain
25 AllTrails                      0x10233876c main + 21 (UIDevice+Storage.swift:21)
26 libdyld.dylib                  0x1a5a1ce18 start
@mmdock
Copy link

mmdock commented May 6, 2020

similar crash log: SDK version 5.6.0

Fatal Exception: NSInvalidArgumentException
0 CoreFoundation 0x1a5d4c96c __exceptionPreprocess
1 libobjc.A.dylib 0x1a5a65028 objc_exception_throw
2 CoreFoundation 0x1a5c4adcc -[NSOrderedSet initWithSet:copyItems:]
3 CoreFoundation 0x1a5d51048 forwarding
4 CoreFoundation 0x1a5d533a0 _CF_forwarding_prep_0
5 FBSDKCoreKit 0x10174a2e0 +[FBSDKRestrictiveDataFilterManager updateFilters:] + 68 (FBSDKRestrictiveDataFilterManager.m:68)
6 FBSDKCoreKit 0x10174cbac +[FBSDKServerConfigurationManager processLoadRequestResponse:error:appID:] + 258 (FBSDKServerConfigurationManager.m:258)
7 FBSDKCoreKit 0x10174c418 __78+[FBSDKServerConfigurationManager loadServerConfigurationWithCompletionBlock:]_block_invoke + 162 (FBSDKServerConfigurationManager.m:162)
8 FBSDKCoreKit 0x10173c740 -[FBSDKGraphRequestMetadata invokeCompletionHandlerForConnection:withResults:error:] + 41 (FBSDKGraphRequestMetadata.m:41)
9 FBSDKCoreKit 0x10173a030 __82-[FBSDKGraphRequestConnection processResultBody:error:metadata:canNotifyDelegate:]_block_invoke + 801 (FBSDKGraphRequestConnection.m:801)
10 FBSDKCoreKit 0x101739f24 -[FBSDKGraphRequestConnection processResultBody:error:metadata:canNotifyDelegate:] + 834 (FBSDKGraphRequestConnection.m:834)
11 FBSDKCoreKit 0x101739b34 __64-[FBSDKGraphRequestConnection completeWithResults:networkError:]_block_invoke + 783 (FBSDKGraphRequestConnection.m:783)
12 CoreFoundation 0x1a5d1e66c NSARRAY_IS_CALLING_OUT_TO_A_BLOCK
13 CoreFoundation 0x1a5c1c22c -[__NSArrayM enumerateObjectsWithOptions:usingBlock:]
14 FBSDKCoreKit 0x1017398f8 -[FBSDKGraphRequestConnection completeWithResults:networkError:] + 762 (FBSDKGraphRequestConnection.m:762)
15 FBSDKCoreKit 0x101738db4 -[FBSDKGraphRequestConnection completeFBSDKURLSessionWithResponse:data:networkError:] + 629 (FBSDKGraphRequestConnection.m:629)
16 FBSDKCoreKit 0x101736f90 __36-[FBSDKGraphRequestConnection start]_block_invoke_3 + 242 (FBSDKGraphRequestConnection.m:242)
17 libdispatch.dylib 0x1a59f0b7c _dispatch_call_block_and_release
18 libdispatch.dylib 0x1a59f1fd8 _dispatch_client_callout
19 libdispatch.dylib 0x1a59fdcc8 _dispatch_main_queue_callback_4CF
20 CoreFoundation 0x1a5cc7cc8 CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE
21 CoreFoundation 0x1a5cc2a24 __CFRunLoopRun
22 CoreFoundation 0x1a5cc1f40 CFRunLoopRunSpecific
23 GraphicsServices 0x1aff52534 GSEventRunModal
24 UIKitCore 0x1a9e4d580 UIApplicationMain
25 Her 0x10008b8e8 main + 11 (main.swift:11)
26 libdyld.dylib 0x1a5b40e18 start

@ericrwolfe
Copy link

I'm also seeing a large spike in crashes in the past two hours with the same stack trace. FBSDKCoreKit 6.0.0, Xcode 11.3.1.

@hberberoglu
Copy link

hberberoglu commented May 6, 2020

We are also experiencing this. It started suddenly about ~1 hour ago. iOSv5.15.1

Fatal Exception: NSInvalidArgumentException
0  CoreFoundation                 0x181c16d8c __exceptionPreprocess
1  libobjc.A.dylib                0x180dd05ec objc_exception_throw
2  CoreFoundation                 0x181c24098 __methodDescriptionForSelector
3  CoreFoundation                 0x181c1c5c8 ___forwarding___
4  CoreFoundation                 0x181b0241c _CF_forwarding_prep_0
5  MyAppName            0x100f2ab98 +[FBSDKRestrictiveDataFilterManager updateFilters:] + 68 (FBSDKRestrictiveDataFilterManager.m:68)
6  MyAppName            0x100f2d790 +[FBSDKServerConfigurationManager processLoadRequestResponse:error:appID:] + 258 (FBSDKServerConfigurationManager.m:258)
7  MyAppName            0x100f1e120 __69+[FBSDKGraphRequestPiggybackManager addServerConfigurationPiggyback:]_block_invoke + 151 (FBSDKGraphRequestPiggybackManager.m:151)
8  MyAppName            0x100f1ca10 -[FBSDKGraphRequestMetadata invokeCompletionHandlerForConnection:withResults:error:] + 41 (FBSDKGraphRequestMetadata.m:41)
9  MyAppName            0x100f1a170 __82-[FBSDKGraphRequestConnection processResultBody:error:metadata:canNotifyDelegate:]_block_invoke + 801 (FBSDKGraphRequestConnection.m:801)
10 MyAppName            0x100f1a054 -[FBSDKGraphRequestConnection processResultBody:error:metadata:canNotifyDelegate:] + 834 (FBSDKGraphRequestConnection.m:834)
11 MyAppName            0x100f19c64 __64-[FBSDKGraphRequestConnection completeWithResults:networkError:]_block_invoke + 783 (FBSDKGraphRequestConnection.m:783)
12 CoreFoundation                 0x181af0a20 -[__NSArrayM enumerateObjectsWithOptions:usingBlock:]
13 MyAppName            0x100f19a08 -[FBSDKGraphRequestConnection completeWithResults:networkError:] + 762 (FBSDKGraphRequestConnection.m:762)
14 MyAppName            0x100f18e98 -[FBSDKGraphRequestConnection completeFBSDKURLSessionWithResponse:data:networkError:] + 629 (FBSDKGraphRequestConnection.m:629)
15 MyAppName            0x100f16f7c __36-[FBSDKGraphRequestConnection start]_block_invoke_3 + 242 (FBSDKGraphRequestConnection.m:242)
16 libdispatch.dylib              0x181508aa0 _dispatch_call_block_and_release
17 libdispatch.dylib              0x181508a60 _dispatch_client_callout
18 libdispatch.dylib              0x18151565c _dispatch_main_queue_callback_4CF$VARIANT$mp
19 CoreFoundation                 0x181bbf070 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__
20 CoreFoundation                 0x181bbcbc8 __CFRunLoopRun
21 CoreFoundation                 0x181adcda8 CFRunLoopRunSpecific
22 GraphicsServices               0x183ac1020 GSEventRunModal
23 UIKit                          0x18baf9758 UIApplicationMain
24 MyAppName            0x100daf99c main + 16 (main.m:16)
25 libdyld.dylib                  0x18156dfc0 start

@snowtema
Copy link

snowtema commented May 6, 2020

The same problem. My app crashing on live users...

@kevinmun
Copy link

kevinmun commented May 6, 2020

Also experiencing huge amount of crashes, still persisting, @tianqibt , any time to resolution or thread where we can check this out?

@rromanchuk
Copy link

this again

@kevinmun
Copy link

kevinmun commented May 6, 2020

let's merge this into #1373

@Yelles
Copy link

Yelles commented May 6, 2020

many apps (Spotify, Viber, etc) are crashing right now... Seems to be a Facebook SDK related issue

@lucas-tl
Copy link

lucas-tl commented May 6, 2020

We are also affected by this. Please move slower and break fewer things. Thank you.

@johnkassebaum
Copy link

What parameterizes 'few' for you?

@pangia
Copy link

pangia commented May 6, 2020

crashing our entire userbase.

@johnkassebaum
Copy link

Ours too

@willswire
Copy link

Pinterest, GroupMe apps crashing on launch.

Also, huge iCloud outage right now - mail hasn't been delivered since 6 PM EST yesterday!! Not sure if it's related or not.

@andyjohns
Copy link

Yeah, same here. All users regardless if they use FB to login or not.

@rromanchuk
Copy link

this is the second time now this SDK has deadmanswitched because of a remote config. I can make my own branching mistakes i dont need additional. Not trying to pile on, but this is not the first time you guys have bricked apps due to release management. It feels a little more nefarious than your typical "server changed response and model now breaks".

@juanchoabdon
Copy link

Same error here!

@johnkassebaum
Copy link

Still crashing 30 minutes after your revert. Are you sure you reverted the right thing?

@daniel-beard
Copy link

daniel-beard commented May 6, 2020

@tianqibt "a few minutes" isn't really an acceptable response for a crash that's taken down our entire userbase. Still crashing for me.

What steps in the future will be taken to prevent this?

@AndrewYab
Copy link

Are you sure this has been reverted correctly? Our apps are still crashing...

@DanielRaouf
Copy link

Affected by this as well. That is very urgent.

@ArielDemarco
Copy link

ArielDemarco commented May 6, 2020

The change needs a some time to be propagated to all server. Some apps already seen the crash stopped. We also turned off the feature. It will be effective within a few minutes.

How much time shall we consider "normal" to wait? Still seeing crashes in our app.

@bruno1308
Copy link

bruno1308 commented May 6, 2020

Don't fire the intern! We all make mistakes!!

Edit: the world is already hard as is. Put yourself in the shoes of the team that is responsible for this. They must be stressed a.f. knowing that they are crashing the whole iOS ecosystem.
So stop pressuring them and give them time to peacefully make their fixes. Life goes on.

@tinder-nathanglass
Copy link

Crashing on launch! Please address!

@marcoviz
Copy link

marcoviz commented May 6, 2020

Same here!

@alfonsomestre
Copy link

Same!

@Kastet
Copy link

Kastet commented May 6, 2020

This is insane, half of the apps on my phone aren't launching!

@AndrewYab
Copy link

Our apps are still crashing. This is unbelievable. Please find a fix urgently!

@scf4
Copy link

scf4 commented May 6, 2020

"lefb-pad"

@tinder-maxwellelliott
Copy link

Server side change is already reverted. The crash will vanish.

TLDR; it didn't stop crashing

@PascalJedi
Copy link

Is the new slogan,
"Move fast and break the whole mobile iOS app ecosystem!"

@pepejeria
Copy link

https://www.theverge.com/2020/5/6/21250023/facebook-sdk-login-spotify-tinder-tiktok-ios-iphone-crash

“Earlier today, a new release of Facebook included a change that triggered crashes for some users in some apps using the Facebook iOS SDK,” a Facebook spokesperson said in a statement to The Verge. “We identified the issue quickly and resolved it. We apologize for any inconvenience.”

@mqlsq
Copy link

mqlsq commented May 7, 2020

启动后你他娘的瞎更新啥?能不能安分一点儿???

我们的所有App都中招

我们也是,损失惨重

@mifi
Copy link

mifi commented May 7, 2020

This is why I like to keep the number of native dependencies in my react-native apps to the minimum

@syedanabimam
Copy link

image

@elecCore
Copy link

elecCore commented May 7, 2020

启动后你他娘的瞎更新啥?能不能安分一点儿???

我们的所有App都中招

我们也是,损失惨重

心都碎了,苦苦维持线上1‰的崩溃率,一个更新给我拉升了2%纯涨了2%!是2%!不是2‰!

@AustinConlon
Copy link

This thread should be canonized in the Computer History Museum.

@DeepakTivari
Copy link

Facebook and their spywares

@dongshuju
Copy link

启动后你他娘的瞎更新啥?能不能安分一点儿???

我们的所有App都中招

我们也是,损失惨重

心都碎了,苦苦维持线上1‰的崩溃率,一个更新给我拉升了2%纯涨了2%!是2%!不是2‰!

一夜回到解放前

@AustinConlon
Copy link

In 2014 Facebook updated the company mantra and it was a wonderful thought. Any chance we could have it added to this repository's README?

tumblr_n4uvx6ZXSk1sxqyhyo1_1280

@santaasus
Copy link

I have some issue in restrictiveParams[eventName][@"is_deprecated_event"], but there isn't condition for dictionary like [restrictiveParams objectForKey], there is force unwrap by key

@AustinConlon
Copy link

All rise for the Facebook iOS SDK anthem.

Anti-Patterns
Coding practices you should avoid
Anti-Patterns
So your app don’t crater like a meteoroid

Whether you’re a newbie or here since NeXTSTEP 3.3
There’s a chance you’ve picked up some bad habits
So take my advice, make your code play nice
Or the bugs will multiply like rabbits
Doo, doo da doo doo

Anti-Patterns
Yeah, you know they’re gonna bite you somewhere down the line
Anti-Patterns
Even if the code seems to work at the time

@RubenKelevra
Copy link

Quite interesting how many apps report each startup to Facebook... probably with the user ID.

You should consider to remove the Facebook functionality from your app entirely.

@balazserd
Copy link

Quite interesting how many apps report each startup to Facebook... probably with the user ID.

You should consider to remove the Facebook functionality from your app entirely.

Yup. If you actually look at what Facebook does is it immediately sends all device info + carrier and also adds an advertisement ID.

I bet a lot of apps don't disclose this information in their privacy policies.

@PatoGuereque
Copy link

I don't know what's scarier, the fact that this basically acted as a remote kill switch for hundreds of apps or that the SDK silently sends data on startup

@allenday
Copy link

allenday commented May 7, 2020

Maybe it's time to reverse-engineering FB SDK and making a real open source FB login SDK.

Maybe it's time that we take responsibility for managing our own private keys and move beyond SSO services for personal data.

@ArtFeel
Copy link

ArtFeel commented May 7, 2020

@balazserd It also swizzle all your UIView, UITextField, UIControl, etc., and add StoreKit observer, to know all about what your users see and theirs purchases.

@allenday
Copy link

allenday commented May 7, 2020

I don't know what's scarier, the fact that this basically acted as a remote kill switch for hundreds of apps or that the SDK silently sends data on startup

The functional code should be scary to you.

The kill switch should be scary to FB.

The latter because it raised FB's intentional behavior of harvesting user data to the level of awareness of developers.

@nirui
Copy link

nirui commented May 7, 2020

In 2014 Facebook updated the company mantra and it was a wonderful thought. Any chance we could have it added to this repository's README?

tumblr_n4uvx6ZXSk1sxqyhyo1_1280

The app crashed while trying to output INFRASTRUCTURE.

@cailinpitt
Copy link

This was a real eye-opening experience. Might have to stop using a lot of the apps that have been communicating with Facebook without my knowledge.

@behdaad
Copy link

behdaad commented May 7, 2020

Let this be a lesson to all of us. We all make mistakes, even the best of us. Stay safe, stay humble.

@petermjones
Copy link

Facebook fixing the server configuration is not good enough. At least two things must be done:

  1. SDK should not crash, regardless of what information comes back from Facebook's servers.
  2. Full transparency as to why it is connecting and what information is being shared.

As App writers, we're deliberately ignoring the fact that the more dependencies you have, the more brittle our systems become. We need to re-think that strategy.

@tianqibt
Copy link
Contributor

tianqibt commented May 7, 2020

A new release of Facebook included a change that triggered crashes for some users in some apps using the Facebook iOS SDK. We identified the issue quickly and resolved it. We apologize for any inconvenience

@tianqibt tianqibt closed this as completed May 7, 2020
@krunalsshah
Copy link

Thanks for fixing the issue.

Our iOS app is still reporting crashes, for others, not sure if the apps have recovered 100%? @tianqibt what do your monitoring tools show?

We'd appreciate more details.

  • Why does the initialization call fire at launch time, and not lazily loaded?
  • Is there a way to configure the SDK such that it could lazily load? And could that change propogate to react-native-fbsdk?

Snippet from our error monitoring & reporting tool, still alerting the crash.

-[__NSCFBoolean objectForKeyedSubscript:]: unrecognized selector sent to instance 0x1e8da5d00

@timuren
Copy link

timuren commented May 7, 2020

How many apps out there still appear to be impacted?

@akhilpothana
Copy link

Facebook fixing the server configuration is not good enough. At least two things must be done:

  1. SDK should not crash, regardless of what information comes back from Facebook's servers.
  2. Full transparency as to why it is connecting and what information is being shared.

As App writers, we're deliberately ignoring the fact that the more dependencies you have, the more brittle our systems become. We need to re-think that strategy.

@petermjones exactly! especially the fact that even a large well versed tech company's sdk can break

@lordzsolt
Copy link

Thanks for fixing the issue.

Our iOS app is still reporting crashes, for others, not sure if the apps have recovered 100%? @tianqibt what do your monitoring tools show?

We'd appreciate more details.

  • Why does the initialization call fire at launch time, and not lazily loaded?
  • Is there a way to configure the SDK such that it could lazily load? And could that change propogate to react-native-fbsdk?

Snippet from our error monitoring & reporting tool, still alerting the crash.

-[__NSCFBoolean objectForKeyedSubscript:]: unrecognized selector sent to instance 0x1e8da5d00

How would you expect Facebook to track all your users if they don't fire at first launch?

@virtadpt
Copy link

virtadpt commented May 7, 2020

They are going to be the new NSA I presume.

"Going to be?"

@kconner
Copy link

kconner commented May 7, 2020

A new release of Facebook included a change that triggered crashes for some users in some apps using the Facebook iOS SDK. We identified the issue quickly and resolved it. We apologize for any inconvenience

@tianqibt To be clear, are you saying this was fixed on the server side, and released apps should no longer exhibit the crash? It's not necessary to update apps with a new Facebook SDK version?

@facebook facebook locked as resolved and limited conversation to collaborators May 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests