2017-07-06 121 views
0

我收到了上述錯誤。我應用了thread以及one這個解決方案,但沒有效果。是否有一些模塊或類我想導入?任何幫助將不勝感激。Swift 3「線程1:信號SIGABRT」錯誤

Github上:https://github.com/joeavargas/BMI-Calc/tree/master/BMI%20Calc

夫特3/Xcode的8.3.3

error

從控制檯錯誤:

2017年7月6日08:20:28.252 BMI計算值[61662: 12276419] *因未捕獲異常'NSUnknownKeyException'而終止應用程序,原因:'[setValue:forUndefinedKey:]:此類不是密鑰編碼兼容的密鑰。 *第一擲調用堆棧: ( 0的CoreFoundation 0x000000010df6eb0b exceptionPreprocess + 171 1 libobjc.A.dylib 0x000000010b2fe141 objc_exception_throw + 48 2的CoreFoundation 0x000000010df6ea59 - [NSException提高] + 9 3基礎0x000000010ae1400b - [NSObject的(的NSKeyValueCoding)的setValue:forKey:] + 292 4的UIKit 0x000000010b96b994 - [UIViewController中的setValue:forKey:] + 87 5的UIKit 0x000000010bbd8a09 - [UIRuntimeOutletConnection連接] + 109 6的CoreFoundation 0x000000010df14e8d - [NSArray的makeObjectsPerformSelector:] + 269 7的UIKit 0x000000010bbd73bf - [ UINib實例化WithOwner:選擇:] + 1856 8的UIKit 0x000000010b971fc3 - [UIViewController中_loadViewFromNibNamed:束:] + 381 9的UIKit 0x000000010b9728d9 - [UIViewController中的loadView] + 177 10的UIKit 0x000000010b972c0a - [UIViewController中loadViewIfRequired] + 195 11的UIKit 0x000000010b97345a - [UIViewController中查看] + 27 12的UIKit 0x000000010b83b98a - [一個UIWindow addRootViewControllerViewIfPossible] + 65 13的UIKit 0x000000010b83c070 - [一個UIWindow _setHidden:強制:] + 294 14的UIKit 0x000000010b84eebe - [一個UIWindow makeKeyAndVisible] + 42 15的UIKit 0x000000010b7c837f - [UIApplication的_callInitializationDelegatesForMainScene:transitionContext :] + 4346 16 UIKit 0x00000 0010b7ce5e4 - [UIApplication的_runWithMainScene:transitionContext:完成:] + 1709 17的UIKit 0x000000010b7cb7f3 - [UIApplication的workspaceDidEndTransaction:] + 182個 18 FrontBoardServices 0x000000010f67e5f6 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK + 24個 19 FrontBoardServices 0x000000010f67e46d - [FBSSerialQueue _performNext] + 186個 20 FrontBoardServices 0x000000010f67e7f6 - [ FBSSerialQueue _performNextFromRunLoopSource] + 45 21的CoreFoundation 0x000000010df14c01 CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION + 17 22的CoreFoundation 0x000000010defa0cf __CFRunLoopDoSources0 + 527 23的CoreFoundation 0x000000010def95ff __CFRunLoopRun + 911 24的CoreFoundation 0x000000010def9016 CFRunLoopRunSpecific + 406 25的UIKit 0x000000010b7ca08f - [UIApplication的_run] + 468 26的UIKit 0x000000010b7d0134 UIApplicationMain + 159 27 BMI計算值0x000000010ad246f7主+ 55 28 libdyld.dylib 0x000000010ef0e65d啓動+ 1 ) 的libC++ ABI。dylib:與類型NSException的未捕獲的異常 (LLDB)結束

+0

請您分享它在調試日誌中說的內容 – penatheboss

+0

Interface Builder中很可能存在缺失或死亡連接。 – vadian

+0

從控制檯添加了錯誤。對不起,延遲的答覆...我工作夜班,我剛剛幾分鐘前醒了過來。 –

回答

0

最顯著信息是

this class is not key value coding-compliant for the key mass.

  • 選擇項目導航
  • 故事板或XIB文件選擇視圖控制器
  • 打開連接檢查器(⌥⌘6
  • 刪除連接到mass
+0

我看到兩個大量連接作爲一個選項來刪除。我認爲我刪除了未在代碼中聲明/使用的那個? –