转换为 Swift 3 后,iOS 应用程序未启动
<p><p>我已将现有应用程序转换为 Swift 3,但当我尝试从 Xcode 启动它时,没有任何反应。 </p>
<p>确切地说,应用程序已成功安装、打开,但只显示白屏。没有构建时或运行时错误。 </p>
<p>我在 <code>private func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: ?) -> Bool</code> 中设置了断点,但它没有到达那里。 </p>
<p>在模拟器中启动会在控制台中打印以下内容:</p>
<pre><code>2016-09-19 14:52:47.881377 ProjectName bundleid: com.company.ProjectName, enable_level: 0, persist_level: 0, propagate_with_activity: 0
2016-09-19 14:52:47.897791 ProjectName 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 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 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 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 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 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
</code></pre>
<p>设备:iPhone SE iOS 9.3.5</p>
<p>模拟器:6 和 SE,均为 iOS 10.0</p>
<p>帮助?任何人?请。 </p></p>
<br><hr><h1><strong>Best Answer-推荐答案</ strong></h1><br>
<p><p>产品 -> 方案 -> 编辑方案 然后在左侧的运行部分,选择参数选项卡 -> 环境变量:</p>
<p><code>OS_ACTIVITY_MODE</code> 到值:禁用。</p>
<p>从 Cocoapods 中移除框架,通过复制项目中的 SDK 手动安装。</p></p>
<p style="font-size: 20px;">关于转换为 Swift 3 后,iOS 应用程序未启动,我们在Stack Overflow上找到一个类似的问题:
<a href="https://stackoverflow.com/questions/39573485/" rel="noreferrer noopener nofollow" style="color: red;">
https://stackoverflow.com/questions/39573485/
</a>
</p>
页:
[1]