Unexpected Crash when Navigating Back from UINavigationController in iOS 16
I've encountered a strange issue with I tried several approaches but none seem to work. I've been banging my head against this for hours. I'm working with a crash in my iOS 16 application when navigating back from a `UINavigationController`. The app works fine until I push a new view controller, but when I try to navigate back, it crashes with a SIGABRT behavior. I've checked the console output, and I see the following behavior message: `*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'Unable to interpret the URL'`. Here's a snippet of my code: ```swift class FirstViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() let button = UIButton(type: .system) button.setTitle("Go to Second View", for: .normal) button.addTarget(self, action: #selector(navigateToSecond), for: .touchUpInside) view.addSubview(button) } @objc func navigateToSecond() { let secondVC = SecondViewController() navigationController?.pushViewController(secondVC, animated: true) } } class SecondViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() view.backgroundColor = .white } } ``` I've also made sure to set the `navigationController` property correctly and there are no missing configurations in my Info.plist file related to URL schemes. This scenario only happens on devices running iOS 16, and the back navigation works perfectly on earlier versions. I've tried cleaning the build folder and restarting the simulator, but nothing seems to help. Any insights on what might be causing this crash? Thanks in advance! What's the best practice here? This issue appeared after updating to Swift 3.11. Is there a better approach? Any help would be greatly appreciated! What would be the recommended way to handle this?