最近刚刚学习ios的快速开发框架beeframework就遇到了个棘手的问题,在iOS 9.1下面会报类似的错
*** Assertion failure in -[UIApplication _runWithMainScene:transitionContext:completion:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKit_Sim/UIKit-3505.16/UIApplication.m:3294
*** Terminating app due to uncaught exception ‘NSInternalInconsistencyException‘, reason: ‘Application windows are expected to have a root view controller at the end of application launch‘ *** First throw call stack: /*省略*/ libc++abi.dylib: terminating with uncaught exception of type NSException (lldb) 这是因为iOS9 不允许在didFinishLaunchingWithOptions
结束了之后,还没有设置 window 的rootViewController
。但是在appdelegate里看到uiwindow初始化的时候都有rootviewController,后来在询问高人后才发现,beeframework有个自定义的window叫beeUIWindow,所有继承了这个类的都会导致程序崩溃,查看调用关系发现都是service的一些东西继承了这个类 因此需要暂时规避这个崩溃问题的就需要在Bee_Precompile.h中把开发模式关掉,即
#define __BEE_DEVELOPMENT__ (__OFF__)
时间: 2024-10-25 08:19:24