iOS 应用程序在转换为 Swift 3 后未启动

iOS app is not launching after converting to Swift 3

我已将现有应用程序转换为 Swift 3,但是当我尝试从 Xcode 启动它时,没有任何反应。

确切地说,应用程序已成功安装、打开,但仅显示白屏。没有构建时或运行时错误。

我在 private func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool 中放置了断点,但它没有到达那里。

在模拟器中启动会在控制台中打印以下内容:

2016-09-19 14:52:47.881377 ProjectName[63797:9522206] bundleid: com.company.ProjectName, enable_level: 0, persist_level: 0, propagate_with_activity: 0

2016-09-19 14:52:47.897791 ProjectName[63797:9522206] subsystem: com.apple.siri, category: Intents, enable_level: 1, persist_level: 1, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 0, privacy_setting: 0, enable_private_data: 0

2016-09-19 14:52:47.933007 ProjectName[63797:9525057] subsystem: com.apple.UIKit, category: HIDEventFiltered, enable_level: 0, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 1, privacy_setting: 2, enable_private_data: 0

2016-09-19 14:52:47.936713 ProjectName[63797:9525057] subsystem: com.apple.UIKit, category: HIDEventIncoming, enable_level: 0, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 1, privacy_setting: 2, enable_private_data: 0

2016-09-19 14:52:48.006885 ProjectName[63797:9525049] subsystem: com.apple.BaseBoard, category: MachPort, enable_level: 1, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 0, privacy_setting: 0, enable_private_data: 0

2016-09-19 14:52:48.039142 ProjectName[63797:9522206] subsystem: com.apple.UIKit, category: StatusBar, enable_level: 0, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 1, privacy_setting: 2, enable_private_data: 0

2016-09-19 14:52:48.142475 ProjectName[63797:9522206] subsystem: com.apple.BackBoardServices.fence, category: App, enable_level: 1, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 0, privacy_setting: 0, enable_private_data: 0

设备:iPhoneSE iOS9.3.5

模拟器:6 和 SE,均为 iOS10.0

帮忙?任何人?请。

产品 -> 方案 -> 编辑方案 然后在左侧的 运行 部分,select 参数选项卡 -> 环境变量:

OS_ACTIVITY_MODE 值:禁用。

从Cocoapods中移除框架,通过复制项目中的SDK手动安装。

尝试替换

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool {

对此:

func applicationDidFinishLaunching(_ application: UIApplication) {