Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by hyko on Friday July 10, 2020 @11:39AM
(#23792643)
Yes there is: a remote kill switch that prevents the third party SDK from loading. That puts you back in control of the software you’re shipping.
Fool me once, and all that.
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by saagarjha on Friday July 10, 2020 @12:01PM
(#23792882)
You have to be technically competent enough to know how to dynamically load a framework, though.
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by liuliu on Friday July 10, 2020 @01:52PM
(#23794256)
And most SDKs are provided as static frameworks. You have to be technically competent to know how to wrap a static framework as dynamic, and then use dlopen to load them properly with a rather high one-time runtime cost. A mess.
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by bognition on Friday July 10, 2020 @12:29PM
(#23793201)
For a tech company with a multi-billion dollar valuation this shouldn't be insurmountable
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by saagarjha on Friday July 10, 2020 @01:00PM
(#23793590)
Facebook knows how dynamic loading works. (At least, I think so…) However, their many clients may not, as a lot are not multi-billion dollar companies.
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by XCSme on Friday July 10, 2020 @10:56AM
(#23792099)
So there is no way to try {} catch {} it, right?
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by Sephiroth87 on Friday July 10, 2020 @11:00AM
(#23792156)
Not in this case, as it's not code explicitly called by the client, but automatically loaded on app launch...
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by saagarjha on Friday July 10, 2020 @12:02PM
(#23792892)
Yes, but 1. it’s hard to inject that as the crash happens very early at launch and 2. Objective-C exceptions of this type are not intended to be caught.
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by robterrell on Friday July 10, 2020 @12:54PM
(#23793516)
That's not strictly true, and anyway it's different for the app developer versus a library provider. If you're making a 3rd party SDK that can throw, you need to make it can catch those throws.
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by saagarjha on Friday July 10, 2020 @01:05PM
(#23793659)
NSInvalidArgumentException is not intended to be caught. You can, of course, but receiving one indicates a serious run-time error.
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by valuearb on Friday July 10, 2020 @11:59AM
(#23792865)
If it's an objective C exception, you can catch those with an objective c wrapper function. Ive done that before in my Swift projects.
Re:App suddenly crashing on startup due to FBSDKRestrictiveD...
by ryandrake on Friday July 10, 2020 @05:15PM
(#23796560)
> Other than remove the SDK, of course.
Bingo! App developer voluntarily pulled in a dependency which they didn't fully understand. When you bring in a dependency, it's not still someone else's code/problem, it becomes your problem.
Other than remove the SDK, of course.