空 Swift 项目的 Springboard 意外退出
Posted
技术标签:
【中文标题】空 Swift 项目的 Springboard 意外退出【英文标题】:Springboard Quit Unexpectedly for Empty Swift Project 【发布时间】:2015-03-10 02:41:06 【问题描述】:我创建了一个新的 swift 项目,并没有对项目进行任何更改。这只是一个空的 swift 项目。如果我选择在 iPhone 6 上运行,跳板会崩溃。但如果我选择其他的(如 iPhone 5s 或可调整大小的 iPhone,甚至是 iPhone 6 Plus),空项目就可以正常工作。
有人知道我的 xcode 有什么问题吗?我应该如何处理这个问题?
错误消息太长,我无法在此处附上整条消息。我会选择一些对我来说很重要的部分。
Process: SpringBoard [1047]
Path: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/CoreServices/SpringBoard.app/SpringBoard
Identifier: SpringBoard
Version: 1.0 (50)
Code Type: X86-64 (Native)
Parent Process: launchd_sim [1035]
Responsible: launchd_sim [1035]
User ID: 501
OS Version: Mac OS X 10.10.2 (14C109)
Report Version: 11
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** setObjectForKey: key cannot be nil'
terminating with uncaught exception of type NSException
abort() called
CoreSimulator 110.4 - Device: iPhone 6 - Runtime: ios 8.1 (12B411) - DeviceType: iPhone 6
External Modification Summary:
Calls made by other processes targeting this process:
task_for_pid: 0
thread_create: 0
thread_set_state: 0
Calls made by this process:
task_for_pid: 0
thread_create: 0
thread_set_state: 0
Calls made by all processes on this machine:
task_for_pid: 714
thread_create: 0
thread_set_state: 160
VM Region Summary:
ReadOnly portion of Libraries: Total=283.3M resident=110.5M(39%) swapped_out_or_unallocated=172.8M(61%)
Writable regions: Total=176.0M written=49.6M(28%) resident=67.4M(38%) swapped_out=0K(0%) unallocated=108.6M(62%)
REGION TYPE VIRTUAL
=========== =======
CG raster data 2252K
CoreAnimation 324K
CoreData Object IDs 4100K
CoreServices 524K
CoreUI image data 240K
Dispatch continuations 8192K
Foundation 4K
Image IO 12K
Kernel Alloc Once 8K
MALLOC 105.3M
MALLOC (admin) 32K
OpenGL GLSL 128K
SQLite page cache 128K
STACK GUARD 56.1M
Stack 21.8M
VM_ALLOCATE 16.7M
__DATA 35.2M
__GLSLBUILTINS 952K
__LINKEDIT 70.9M
__TEXT 212.5M
__UNICODE 544K
mapped file 89.9M
shared memory 68K
=========== =======
TOTAL 625.5M
Model: MacBookAir6,2, BootROM MBA61.0099.B18, 2 processors, Intel Core i5, 1.3 GHz, 4 GB, SMC 2.13f15
Graphics: Intel HD Graphics 5000, Intel HD Graphics 5000, Built-In
Memory Module: BANK 0/DIMM0, 2 GB, DDR3, 1600 MHz, 0x02FE, 0x45424A3230554638454455302D474E2D4620
Memory Module: BANK 1/DIMM0, 2 GB, DDR3, 1600 MHz, 0x02FE, 0x45424A3230554638454455302D474E2D4620
AirPort: spairport_wireless_card_type_airport_extreme (0x14E4, 0x117), Broadcom BCM43xx 1.0 (7.15.159.13.12)
Bluetooth: Version 4.3.2f6 15235, 3 services, 27 devices, 1 incoming serial ports
Network Service: Wi-Fi, AirPort, en0
Network Service: Thunderbolt Bridge, Ethernet, bridge0
Serial ATA Device: APPLE SSD SD0256F, 251 GB
USB Device: Internal Memory Card Reader
USB Device: BRCM20702 Hub
USB Device: Bluetooth USB Host Controller
Thunderbolt Bus: MacBook Air, Apple Inc., 23.6
【问题讨论】:
在您的项目中,搜索 setObjectForKey,或搜索使用键和对象创建字典的代码,记录键。 嗨,我已经搜索了整个项目,但没有找到。 :( Xcode 将我带到名为 AppDelegate.swift 的文件,并显示“线程 1:信号 SIGTERM”。AppDelegate.swift 文件是自动生成的。 【参考方案1】:在我将 Xcode 更新到最新版本后,问题自动解决了。
如果您对该问题有可能的答案,仍然欢迎您回答该问题。
【讨论】:
以上是关于空 Swift 项目的 Springboard 意外退出的主要内容,如果未能解决你的问题,请参考以下文章