Undocumented changes in WebKit API in Xcode 16 break apps

Be warned! When developing your app in Xcode 16 be careful!!! The new SDK has changes that cause builds on Xcode Cloud and other non-beta Xcode to have bugs (EVEN WITH IOS TARGET SET LOWER).

This wasted 2 days of development time, but in WKNavigationDelegate, the webView(_:decidePolicyFor:decisionHandler:) method has a new type signature that will ONLY work in the latest SDK. The change was that the decisionHandler now has a @MainActor attribute. This causes Swift to recognize that it "almost" meets an optional requirement and suggests that you change it. If you change it, it will cause builds to not include the optional method.

Undocumented changes in WebKit API in Xcode 16 break apps
 
 
Q