UISearchDisplayController Crashes in iOS 13 Beta

I know that UISearchDisplayController was depricated in iOS 8, but it has continued to work well through iOS 12. In iOS 13 Beta UISearchDisplayController crashes an app whenever the search bar keyboard is used. Has support for UISearchDisplayController been removed from iOS 13 or is this a bug in iOS 13 beta? UISearchDisplayController still compiles fine with no errors in Xcode, but crashes when run.

Replies

Have the same crash in iOS 13 beta4

I have the same issue... have you found any work around for this?

I changed my code over to UISearchController - something I should have done a long time ago. This eliminated the problem, but it did take a little effort to achieve an equivalent user interface since I am using selectedScope buttons.

I'm experiencing this, too. I realize that recoding for UISearchController is the preferred fix, but we're out of time on a project. Xcode still shows the UISearchDisplayController as deprecated. Has it actually been removed from iOS 13?

Hi I just came across this issue where my users were complaining that it was crashing on iOS 13, and so I installed my app and ran it from the App Store and realized that it was crashing. The debug logs mentioned the same issue with UISearchDisplayController. After much trial and error, I was about to give up. But then I realized that the problem is with XCode 11. When I was building with XCode 11 and running it on my iOS 13 device I was never able to reproduce the issue, but as soon as I would upload it to TestFlight and run it, it was crashing.


So then I went back and built my app with XCode 10.2.1 and pushed it up to TestFlight and "Tada"!! No crashes. So if you're like me and don't have the time or patience to refactor some code that worked for the last 5 years, then try this approach. I hope this helps.

In my case, I was also using the deprecated search UI which was appropriately flagged but ran fin on iOS 13 - 13.2 devices and sims.

However the App Store rejected an update to this longstanding app as crashing on launch. Turned out to be the execution while loading the offending viewController of a new method:

0   CoreFoundation               
0x1bd14fab0 __exceptionPreprocess + 224

1   libobjc.A.dylib             
0x1bce69028 objc_exception_throw + 59

2   CoreFoundation               
0x1bd03f2fc +[NSException raise:format:] + 111

3   UIKitCore                   
0x1c0ba3c2c UISearchDisplayControllerNoLongerSupported + 215

4   UIKitCore                   
0x1c0ba3f48 -[UISearchDisplayController initWithCoder:] + 87

5   UIFoundation                 
0x1c077d300 UINibDecoderDecodeObjectForValue + 731

i am also getting same issue , how you resolve this issue

Yup, this is exactly what I'm seeing (although I didn't try to build it in an earlier Xcode). Annoying.

Remove support to UISeachDisplayController and replace by UISeachController (Tip use same delegate methods)

We dont have "UISeachDisplayController" in our ionic/react capacitor project. Any other suggestions?

xcode 11.6