NativeScript-Angular: nsRouterLink opens component on Android, but does not on iOS - nativescript

Opening new window using nsRouterLink works on Android but not on iOS.
Tapping this button:
<Button text="Tap me to open child component" [nsRouterLink]="['../child']" ></Button>
Works nicely on Android but crashes app on iOS.
Here is a Playground mock-up:
NativeScript Playground sample
Here is iOS crash log:
[Test iPhone]: The Preview app has terminated unexpectedly. Please run it again to get a detailed crash report.
[Test iPhone]: 2019-07-02 11:59:59.665 nsplaydev[1064:606206] ***** Fatal JavaScript exception - application has been terminated. *****
2019-07-02 11:59:59.665 nsplaydev[1064:606206] Native stack trace:
1 0x1013473b0 NativeScript::reportFatalErrorBeforeShutdown(JSC::ExecState*, JSC::Exception*, bool)
2 0x101378db4 NativeScript::FFICallback<NativeScript::ObjCMethodCallback>::ffiClosureCallback(ffi_cif*, void*, void**, void*)
3 0x101dddfa4 ffi_closure_SYSV_inner
4 0x101de01b4 .Ldo_closure
5 0x1bbdfb6e4 <redacted>
6 0x1bbdfbdb0 <redacted>
7 0x1bbd53578 <redacted>
8 0x1bbd674b8 <redacted>
9 0x1bbd688e0 <redacted>
10 0x1bbd4baf0 <redacted>
11 0x1bc836ed0 <redacted>
12 0x194091a20 <redacted>
13 0x1940969c8 <redacted>
14 0x193ff92d0 <redacted>
15 0x194027330 <redacted>
16 0x194027f20 <redacted>
17 0x18fb6e5f8 <redacted>
18 0x18fb69320 <redacted>
19 0x18fb6989c <redacted>
20 0x18fb690b0 CFRunLoopRunSpecific
21 0x191d6979c GSEventRunModal
22 0x1bc39f978 UIApplicationMain
23 0x101de0044 ffi_call_SYSV
24 0x101ddd6c4 ffi_call_int
25 0x101ddd1c0 ffi_call
26 0x10130cb80 NativeScript::FunctionWrapper::call(JSC::ExecState*)
27 0x101ddc268 llint_entry
28 0x101ddb6c4 llint_entry
29 0x101ddb6c4 llint_entry
30 0x101ddb6c4 llint_entry
31 0x101ddb6c4 llint_entry
2019-07-02 11:59:59.675 nsplaydev[1064:606206] JavaScript stack trace:
2019-07-02 11:59:59.675 nsplaydev[1064:606206] 1 #file:///app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js:134:25
2 eachChildView#file:///app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js:125:28
3 eachLayoutChild#file:///app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js:133:23
4 onMeasure#file:///app/tns_modules/tns-core-modules/ui/layouts/grid-layout/grid-layout.js:107:25
5 measure#file:///app/tns_modules/tns-core-modules/ui/core/view/view.js:55:21
6 measureChild#file:///app/tns_modules/tns-core-modules/ui/core/view/view-common.js:929:20
7 onMeasure#file:///app/tns_modules/tns-core-modules/ui/action-bar/action-bar.js:302:44
8 measure#file:///app/tns_modules/tns-core-modules/ui/core/view/view.js:55:21
9 layoutInternal#file:///app/tns_modules/tns-core-modules/ui/action-bar/action-bar.js:132:17
10 update#file:///app/tns_modules/tns-core-modules/ui/action-bar/action-bar.js:202:26
11 onLoaded#file:///app/tns_modules/tns-core-modules/ui/page/page.js:240:28
12 #file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:311:93
13 callFunctionWithSuper#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:304:9
14 callLoaded#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:311:31
15 loadView#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:439:22
16 _addViewCore#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:434:20
17 _addView#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:420:22
18 viewWillAppear#file:///app/tns_modules/tns-core-modules/ui/page/page.js:81:23
19 UIApplicationMain#[native code]
20 _start#file:///app/tns_modules/tns-core-modules/application/application.js:277:22
21 run#file:///app/tns_modules/tns-core-modules/application/application.js:309:9
22 bootstrapNativeScriptApp#file:///app/tns_modules/nativescript-angular/platform-common.js:205:22
23 bootstrapApp#file:///app/tns_modules/nativescript-angular/platform-common.js:106:34
24 bootstrapModule#file:///app/tns_modules/nativescript-angular/platform-common.js:90:22
25 anonymous#file:///app/main.js:8:57
26 evaluate#[native code]
27 moduleEvaluation#[native code]
28 promiseReactionJob#[native code]
2019-07-02 11:59:59.676 nsplaydev[1064:606206] JavaScript error:
file:///app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js:134:25: JS ERROR TypeError: undefined is not a function (near '...cv._eachLayoutView...')
2019-07-02 11:59:59.678 nsplaydev[1064:606206] PlayLiveSync: Uncaught Exception
2019-07-02 11:59:59.679 nsplaydev[1064:606206] PlayLiveSync: Sending crash report
2019-07-02 12:00:03.681 nsplaydev[1064:606206] *** JavaScript call stack:
(
0 UIApplicationMain#[native code]
1 _start#file:///app/tns_modules/tns-core-modules/application/application.js:277:22
2 run#file:///app/tns_modules/tns-core-modules/application/application.js:309:9
3 bootstrapNativeScriptApp#file:///app/tns_modules/nativescript-angular/platform-common.js:205:22
4 bootstrapApp#file:///app/tns_modules/nativescript-angular/platform-common.js:106:34
5 bootstrapModule#file:///app/tns_modules/nativescript-angular/platform-common.js:90:22
6 anonymous#file:///app/main.js:8:57
7 evaluate#[native code]
8 moduleEvaluation#:1:11
9 promiseReactionJob#:1:11
)
2019-07-02 12:00:03.681 nsplaydev[1064:606206] *** Terminating app due to uncaught exception 'NativeScript encountered a fatal error: TypeError: undefined is not a function (near '...cv._eachLayoutView...')
at
1 #file:///app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js:134:25
2 eachChildView#file:///app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js:125:28
3 eachLayoutChild#file:///app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js:133:23
4 onMeasure#file:///app/tns_modules/tns-core-modules/ui/layouts/grid-layout/grid-layout.js:107:25
5 measure#file:///app/tns_modules/tns-core-modules/ui/core/view/view.js:55:21
6 measureChild#file:///app/tns_modules/tns-core-modules/ui/core/view/view-common.js:929:20
7 onMeasure#file:///app/tns_modules/tns-core-modules/ui/action-bar/action-bar.js:302:44
8 measure#file:///app/tns_modules/tns-core-modules/ui/core/view/view.js:55:21
9 layoutInternal#file:///app/tns_modules/tns-core-modules/ui/action-bar/action-bar.js:132:17
10 update#file:///app/tns_modules/tns-core-modules/ui/action-bar/action-bar.js:202:26
11 onLoaded#file:///app/tns_modules/tns-core-modules/ui/page/page.js:240:28
12 #file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:311:93
13 callFunctionWithSuper#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:304:9
14 callLoaded#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:311:31
15 loadView#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:439:22
16 _addViewCore#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:434:20
17 _addView#file:///app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js:420:22
18 viewWillAppear#file:///app/tns_modules/tns-core-modules/ui/page/page.js:81:23
19 UIApplicationMain#[native code]
20 _start#file:///app/tns_modules/tns-core-modules/application/application.js:277:22
21 run#file:///app/tns_modules/tns-core-modules/application/application.js:309:9
22 bootstrapNativeScriptApp#file:///app/tns_modules/nativescript-angular/platform-common.js:205:22
23 bootstrapApp#file:///app/tns_modules/nativescript-angular/platform-common.js:106:34
24 bootstrapModule#file:///app/tns_modules/nativescript-angular/platform-common.js:90:22
25 anonymous#file:///app/main.js:8:57
26 evaluate#[native code]
27 moduleEvaluation#[native code]
28 promiseReactionJob#[native code]
', reason: '(null)'
*** First throw call stack:
(0x18fbdd27c 0x18edb79f8 0x1013477f4 0x101378db4 0x101dddfa4 0x101de01b4 0x1bbdfb6e4 0x1bbdfbdb0 0x1bbd53578 0x1bbd674b8 0x1bbd688e0 0x1bbd4baf0 0x1bc836ed0 0x194091a20 0x1940969c8 0x193ff92d0 0x194027330 0x194027f20 0x18fb6e5f8 0x18fb69320 0x18fb6989c 0x18fb690b0 0x191d6979c 0x1bc39f978 0x101de0044 0x101ddd6c4 0x101ddd1c0 0x10130cb80 0x101ddc268 0x101ddb6c4 0x101ddb6c4 0x101ddb6c4 0x101ddb6c4 0x101ddb6c4 0x101ddb6c4 0x101dd412c 0x101bd4abc 0x101d8e520 0x101324570 0x101463268 0x101ddc13c 0x101ddb6c4 0x101ddb6c4 0x101dd412c 0x101bd4abc 0x101d8e684 0x10145e668 0x10131b90c 0x101385930 0x10115db14 0x100a833f0 0x18f62e8e0)
libc++abi.dylib: terminating with uncaught exception of type NSException
2019-07-02 12:00:03.682 nsplaydev[1064:606206] PlayLiveSync: Uncaught Exception
To sum it up, something is wrong in NativeScript when it compiles for iOS:
2019-07-02 11:59:59.676 nsplaydev[1064:606206] JavaScript error:
file:///app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js:134:25: JS ERROR TypeError: undefined is not a function (near '...cv._eachLayoutView...')
Since I develop on Windows, I'm unable to debug iphone, tried to use osx vmware image but Sidekick doesn't work well in there...

It had nothing to do with nsRouterLink the bug was actually in your code on child.component.html
<ActionBar class="action-bar">
<GridLayout rows="auto" columns="*">
<NavigationButton icon="res://back" tap="onDrawerButtonTap"></NavigationButton>
<Label row="0" horizontalAlignment="center" text="This be child"></Label>
</GridLayout>
</ActionBar>
<Button text="child works!"></Button>
You can not place NavigationButton inside your custom layout, it should be direct child of ActionBar, so the code below should work
<ActionBar class="action-bar">
<NavigationButton icon="res://back" tap="onDrawerButtonTap"></NavigationButton>
<GridLayout rows="auto" columns="*">
<Label row="0" horizontalAlignment="center" text="This be child"></Label>
</GridLayout>
</ActionBar>
<Button text="child works!"></Button>

Related

Cant run app Nativescript on iOS but runs on android

Cant run app Nativescript on iOS but runs on android
My code works ok android with no problems but in iOS i get those erros below.
and i have no ideia why, what im missing ???? Its a plugin? Module?
Any help would be good cuz im lost here. thanks
when i run tns run ios --env.aot --env.uglify.
the erros i get when running the app :
***** Fatal JavaScript exception - application has been terminated. *****
Native stack trace:
1 0x10fe3991f NativeScript::reportFatalErrorBeforeShutdown(JSC::ExecState*, JSC::Exception*, bool)
2 0x10fe71b60 NativeScript::FFICallback<NativeScript::ObjCMethodCallback>::ffiClosureCallback(ffi_cif*, void*, void**, void*)
3 0x110812dd6 ffi_closure_unix64_inner
4 0x1108137fa ffi_closure_unix64
5 0x114515d22 -[CALayer layoutSublayers]
6 0x11451a9fc CA::Layer::layout_if_needed(CA::Transaction*)
7 0x114526d58 CA::Layer::layout_and_display_if_needed(CA::Transaction*)
8 0x11449624a CA::Context::commit_transaction(CA::Transaction*)
9 0x1144cd606 CA::Transaction::commit()
10 0x116f942c3 __34-[UIApplication _firstCommitBlock]_block_invoke_2
11 0x115a97cbc __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__
12 0x115a97480 __CFRunLoopDoBlocks
13 0x115a91d04 __CFRunLoopRun
14 0x115a914d2 CFRunLoopRunSpecific
15 0x11b8af2fe GSEventRunModal
16 0x116f7afc2 UIApplicationMain
17 0x11081363d ffi_call_unix64
18 0x12db4cf70
JavaScript stack trace:
1 #file:///node_modules/tns-core-modules/ui/content-view/content-view.js:44:0
2 _eachLayoutView#file:///node_modules/tns-core-modules/ui/core/view/view-common.js:1015:0
3 #file:///node_modules/tns-core-modules/ui/proxy-view-container/proxy-view-container.js:45:0
4 eachChildView#file:///node_modules/tns-core-modules/ui/layouts/layout-base-common.js:125:0
5 _eachLayoutView#file:///node_modules/tns-core-modules/ui/proxy-view-container/proxy-view-container.js:43:0
6 get#file:///node_modules/tns-core-modules/ui/content-view/content-view.js:38:0
7 onMeasure#file:///node_modules/tns-core-modules/ui/page/page.js:272:0
8 measure#file:///node_modules/tns-core-modules/ui/core/view/view.js:55:0
9 measureChild#file:///node_modules/tns-core-modules/ui/core/view/view-common.js:954:0
10 i#file:///node_modules/tns-core-modules/ui/core/view/view.js:636:0
11 viewDidLayoutSubviews#file:///node_modules/tns-core-modules/ui/page/page.js:192:0
12 UIApplicationMain#[native code]
13 S#file:///node_modules/tns-core-modules/application/application.js:277:0
14 run#file:///node_modules/tns-core-modules/application/application.js:305:0
15 bootstrapNativeScriptApp#file:///node_modules/nativescript-angular/platform-common.js:205:0
16 bootstrapApp#file:///node_modules/nativescript-angular/platform-common.js:106:0
17 bootstrapModuleFactory#file:///node_modules/nativescript-angular/platform-common.js:77:0
18 #file:///app/bundle.js:72:449
19 ./main.ts#file:///app/bundle.js:72:477
20 k#file:///src/webpack/bootstrap:750:0
21 n#file:///src/webpack/bootstrap:43:0
22 r#file:///src/webpack/bootstrap:30:0
23 anonymous#file:///src/$_lazy_route_resource lazy namespace object:2:0
24 evaluate#[nat<…>
JavaScript error:
file:///node_modules/tns-core-modules/ui/content-view/content-view.js:44:0 JS ERROR Error: More than one layout child inside a
1 UIApplicationMain#[native code]
2 S#file:///node_modules/tns-core-modules/application/application.js:277:0
3 run#file:///node_modules/tns-core-modules/application/application.js:305:0
4 bootstrapNativeScriptApp#file:///node_modules/nativescript-angular/platform-common.js:205:0
5 bootstrapApp#file:///node_modules/nativescript-angular/platform-common.js:106:0
6 bootstrapModuleFactory#file:///node_modules/nativescript-angular/platform-common.js:77:0
7 #file:///app/bundle.js:72:449
8 ./main.ts#file:///app/bundle.js:72:477
9 k#file:///src/webpack/bootstrap:750:0
10 n#file:///src/webpack/bootstrap:43:0
11 r#file:///src/webpack/bootstrap:30:0
12 anonymous#file:///src/$_lazy_route_resource lazy namespace object:2:0
13 evaluate#[native code]
14 moduleEvaluation#:1:11
15 promiseReactionJob#:1:11
Somewhere in your source, usually at the root of a particular component's html/xml, you have a view that is only rendered on iOS. However, because it fails on iOS and not Android, it is likely that you have not placed the similar restriction on the other top-level element.
<ios>
<Label text="only iOS"></Label>
</ios>
<Label text="only Android"></Label> <!-- Error; is present in template for both!! -->
It is hard for me to guess where exactly the issue might be, but I'd suggest having a look through your templates for the usage of ios.
Well in ios u cant have free templates floating arround everything was too be inside a LayoutContainer
Android (Works) iOS (Don't Work)
<GridLayout>
(... Content)
</GridLayout>
<GridLayout>
(... More Content)
</GridLayout>
Android (Works) iOS (Works)
<GridLayout> // MAIN CHILD
(... Content)
<GridLayout>
(... More Content)
</GridLayout>
</GridLayout>

How to debug nativescript throwing "NativeScript caught signal 11." error?

I have created a plugin for nativescript ios which was working fine until recently I updated the pod version.
Now, when I run the plugin, I get this error:
NativeScript caught signal 11.
I have already double checked the typings and there was no typo or parameter mismatch there.
NativeScript caught signal 11.
Native Stack:
1 0x104c6cf70 sig_handler(int)
2 0x1f46f99dc <redacted>
3 0x104c5e768 NativeScript::ObjCMethodWrapper::postInvocation(NativeScript::FFICall*, JSC::ExecState*, NativeScript::FFICall::Invocation&)
4 0x104bf500c NativeScript::FunctionWrapper::call(JSC::ExecState*)
5 0x1056d7a58 llint_entry
6 0x1056d6eb4 llint_entry
7 0x1056d6eb4 llint_entry
8 0x1056d6eb4 llint_entry
9 0x1056d7318 llint_entry
10 0x1056d6eb4 llint_entry
11 0x1056d7318 llint_entry
12 0x1056d6e4c llint_entry
13 0x1056d6e4c llint_entry
14 0x1056d6eb4 llint_entry
15 0x1056d6eb4 llint_entry
16 0x1056d6e4c llint_entry
17 0x1056d6eb4 llint_entry
18 0x1056cf91c vmEntryToJavaScript
19 0x1054ce84c JSC::Interpreter::executeCall(JSC::ExecState*, JSC::JSObject*, JSC::CallType, JSC::CallData const&, JSC::JSValue, JSC::ArgList const&)
20 0x104c61238 NativeScript::FFICallback<NativeScript::ObjCMethodCallback>::callFunction(JSC::JSValue const&, JSC::ArgList const&, void*)
21 0x104c60d58 NativeScript::ObjCMethodCallback::ffiClosureCallback(void*, void**, void*)
22 0x104c6142c NativeScript::FFICallback<NativeScript::ObjCMethodCallback>::ffiClosureCallback(ffi_cif*, void*, void**, void*)
23 0x1056d9794 ffi_closure_SYSV_inner
24 0x1056dc1b4 .Ldo_closure
25 0x2213f1040 <redacted>
26 0x220e9a1c8 <redacted>
27 0x220e9a4e8 <redacted>
28 0x220e99554 <redacted>
29 0x221428304 <redacted>
30 0x22142952c <redacted>
31 0x22140959c <redacted>
JS Stack:
1 initWithConfiguration#[native code]
2 start#file:///app/tns_modules/nativescript-nsjumioplugin/nsjumioplugin.js:22:97
3 onSelectSingleTap#file:///app/app/pages/user/info/identification/identification.component.js:109:33
4 #:34:44
5 callWithDebugContext#file:///app/tns_modules/#angular/core/bundles/core.umd.js:24198:34
6 dispatchEvent#file:///app/tns_modules/#angular/core/bundles/core.umd.js:20577:40
7 #file:///app/tns_modules/nativescript-angular/renderer.js:238:31
8 onInvoke#file:///app/tns_modules/#angular/core/bundles/core.umd.js:17344:43
9 run#file:///app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js:138:49
10 zonedCallback#file:///app/tns_modules/nativescript-angular/renderer.js:237:27
11 notify#file:///app/tns_modules/tns-core-modules/data/observable/observable.js:110:31
12 _emit#file:///app/tns_modules/tns-core-modules/data/observable/observable.js:127:24
13 tap#file:///app/tns_modules/tns-core-modules/ui/button/button.js:216:24
14 UIApplicationMai<\M-b\M^#\M-&>
In my case, I have used this command to run the app
tns run ios --bundle --no-hmr --clean --log trace
Or maybe IP blocked on OneSignal's servers
This may help you:
I've got NativeScript caught signal 11 while using RadSideDrawer.
I've tried to use drawerContentSize="drawerSize" instead of correct [drawerContentSize]="drawerSize" (since drawerSize is a getter in my ts file)
So generally I may assume that it may happen if you forget square brackets (sometimes)
It seems the signal 11 error is a general error that can be caused by many things that others mentioned in comments.
In my case, my IP was blocked by OneSignal's servers.

Crash on Xcode Run

i run project that imported from Unity3D.
then at XCode i try to run to my iPad.
Apps can builded and installed but when running it crash (sometime just blank screen).
at Xcode i got below error, but i dont understand what these error means ?
CrashReporter: initialized
2018-10-23 11:11:36.341 flashcards[318:26427] -> registered mono modules 0x1ee2e00
-> applicationDidFinishLaunching()
2018-10-23 11:11:37.789 flashcards[318:26427] Metal GPU Frame Capture Enabled
2018-10-23 11:11:37.790 flashcards[318:26427] Metal API Validation Disabled
-> applicationDidBecomeActive()
Renderer: PowerVR SGX 543
Vendor: Imagination Technologies
Version: OpenGL ES 2.0 IMGSGX543-124.1
GLES: 2
GL_OES_depth_texture GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_texture_float GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_vertex_array_object GL_EXT_blend_minmax GL_EXT_color_buffer_half_float GL_EXT_debug_label GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_draw_instanced GL_EXT_instanced_arrays GL_EXT_map_buffer_range GL_EXT_occlusion_query_boolean GL_EXT_pvrtc_sRGB GL_EXT_read_format_bgra GL_EXT_separate_shader_objects GL_EXT_shader_framebuffer_fetch GL_EXT_shader_texture_lod GL_EXT_shadow_samplers GL_EXT_sRGB GL_EXT_texture_filter_anisotropic GL_EXT_texture_rg GL_EXT_texture_storage GL_APPLE_clip_distance GL_APPLE_color_buffer_packed_float GL_APPLE_copy_texture_levels GL_APPLE_framebuffer_multisample GL_APPLE_rgb_422 GL_APPLE_sync GL_APPLE_texture_format_BGRA8888 GL_APPLE_texture_max_level GL_APPLE_texture_packed_float GL_IMG_read_format GL_IMG_texture_comp
ression_pvrtc
OPENGL LOG: Creating OpenGL ES 2.0 graphics device ; Context level <OpenGL ES 2.0> ; Context handle 359353072
Initialize engine version: 2017.4.8f1 (5ab7f4878ef1)
WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
ERROR: 0:38: Use of undeclared identifier 'gl_FragDepthEXT'
Note: Creation of internal variant of shader 'Hidden/Internal-MotionVectors' failed.
WARNING: Shader Unsupported: 'Hidden/Internal-MotionVectors' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/Internal-MotionVectors' - Setting to default shader.
WARNING: Shader Unsupported: 'Hidden/BlitToDepth' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/BlitToDepth' - Setting to default shader.
WARNING: Shader Unsupported: 'Hidden/BlitToDepth_MSAA' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/BlitToDepth_MSAA' - Setting to default shader.
WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
ERROR: 0:14: Use of undeclared identifier 'gl_FragDepthEXT'
Note: Creation of internal variant of shader 'Hidden/BlitCopyWithDepth' failed.
WARNING: Shader Unsupported: 'Hidden/BlitCopyWithDepth' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/BlitCopyWithDepth' - Setting to default shader.
The referenced script on this Behaviour (Game Object 'Scene Variables') is missing!
(Filename: Line: 1758)
The referenced script on this Behaviour (Game Object 'Scene Variables') is missing!
(Filename: Line: 1758)
The referenced script on this Behaviour (Game Object 'IAPManager') is missing!
(Filename: Line: 1758)
The referenced script on this Behaviour (Game Object 'IAPManager') is missing!
(Filename: Line: 1758)
The referenced script on this Behaviour (Game Object 'IAPManager') is missing!
(Filename: Line: 1758)
UnloadTime: 9.446791 ms
2018-10-23 11:11:45.250 flashcards[318:26427] *** Assertion failure in -[UnityDefaultViewController supportedInterfaceOrientations], /Users/mac/Downloads/snowy_eng_ios_noads/Classes/UI/UnityViewControllerBase+iOS.mm:93
2018-10-23 11:11:48.218 flashcards[318:26427] Uncaught exception: NSInternalInconsistencyException: UnityDefaultViewController should be used only if unity is set to autorotate
(
0 CoreFoundation 0x20a37933 <redacted> + 150
1 libobjc.A.dylib 0x201d2e17 objc_exception_throw + 38
2 CoreFoundation 0x20a377f1 <redacted> + 0
3 Foundation 0x2121b529 <redacted> + 92
4 flashcards 0x0008849f -[UnityDefaultViewController supportedInterfaceOrientations] + 302
5 flashcards 0x000a2ce3 -[UnityAppController application:supportedInterfaceOrientationsForWindow:] + 174
6 flashcards 0x0128d0f8 GADiTunesMetadataForFileAtPath + 12068
7 flashcards 0x01348570 GADODiskUsageStatisticsWithError + 3488
8 flashcards 0x0134848c GADODiskUsageStatisticsWithError + 3260
9 flashcards 0x01252f84 GADOCategories_NSArray_GADOJSONAdditions + 15060
10 flashcards 0x013112cc GADODispatchAsyncSafeMainQueue + 64
11 flashcards 0x01252e40 GADOCategories_NSArray_GADOJSONAdditions + 14736
12 flashcards 0x01143531 -[GADURewardBasedVideoAd loadRequest:withAdUnitID:] + 78
13 flashcards 0x011403ff GADURequestRewardBasedVideoAd + 76
14 flashcards 0x00278c4d RewardBasedVideoAdClient_LoadAd_m483440913 + 34
15 flashcards 0x0026c8ab RewardBasedVideoAd_LoadAd_m4208741079 + 90
16 flashcards 0x0023bdaf z_reward_ads_Start_m1587933392 + 102
17 flashcards 0x010f0ce5 _Z31RuntimeInvoker_Void_t1185182177PFvvEPK10MethodInfoPvPS4_ + 10
18 flashcards 0x01d66793 _ZN6il2cpp2vm7Runtime6InvokeEPK10MethodInfoPvPS5_PP15Il2CppException + 118
19 flashcards 0x016d91b3 _Z23scripting_method_invoke18ScriptingMethodPtr18ScriptingObjectPtrR18ScriptingArgumentsP21ScriptingExceptionPtrb + 66
20 flashcards 0x016dffdd _ZN19ScriptingInvocation6InvokeEP21ScriptingExceptionPtrb + 38
21 flashcards 0x016e4a73 _ZN13MonoBehaviour30InvokeMethodOrCoroutineCheckedE18ScriptingMethodPtr18ScriptingObjectPtrP21ScriptingExceptionPtr + 1198
22 flashcards 0x016e4bd1 _ZN13MonoBehaviour30InvokeMethodOrCoroutineCheckedE18ScriptingMethodPtr18ScriptingObjectPtr + 46
23 flashcards 0x016e3f3d _ZN13MonoBehaviour16DelayedStartCallEP6ObjectPv + 46
24 flashcards 0x01578339 _ZN18DelayedCallManager6UpdateEi + 430
25 flashcards 0x0162b699 _Z10PlayerLoopv + 520
26 flashcards 0x0147fb0d _ZL19UnityPlayerLoopImplb + 22
27 flashcards 0x000915c5 UnityRepaint + 220
28 flashcards 0x0009147d -[UnityAppController(Rendering) repaintDisplayLink] + 76
29 libMTLInterpose.dylib 0x05cec865 -[DYDisplayLinkInterposer forwardDisplayLinkCallback:] + 276
30 QuartzCore 0x23093a0b <redacted> + 106
31 QuartzCore 0x23093857 <redacted> + 594
32 IOMobileFramebuffer 0x2277a50b <redacted> + 86
33 IOKit 0x20c88759 IODispatchCalloutFromCFMessage + 256
34 CoreFoundation 0x209e637d <redacted> + 132
35 CoreFoundation 0x209fa5b3 <redacted> + 34
36 CoreFoundation 0x209f9cc7 <redacted> + 342
37 CoreFoundation 0x209f80d9 <redacted> + 1688
38 CoreFoundation 0x20947229 CFRunLoopRunSpecific + 520
39 CoreFoundation 0x20947015 CFRunLoopRunInMode + 108
40 GraphicsServices 0x21f37ac9 GSEventRunModal + 160
41 UIKit 0x2501b189 UIApplicationMain + 144
42 flashcards 0x00087f9f main + 206
43 libdyld.dylib 0x205ef873 <redacted> + 2
and i got exception at here :
gsCrashReporterUEHandler NSUncaughtExceptionHandler * (flashcards`uncaught_exception_handler) 0x01bf1a38
any idea, what error i found here ?
In your crash log I can see this error:
Uncaught exception: NSInternalInconsistencyException: UnityDefaultViewController should be used only if unity is set to autorotate.
This means Unity should set Screen.orientation to ScreenOrientation.AutoRotation.
You can check if some code in your Unity3D project set the Screen.orientation to any other code and check in "Unity Build setting" Default Orientation is "Auto Rotation".
We got this crash report also, and many of them
I've read somewhere (maybe in Unity forum) that it's being caused by Ads that showing in different orientation, when the game is back from Ads, the orientation did not restore correctly so Unity log the ASSERT.
They suggested that we just need open the exported XCode project and comment out the ASSERT line 111 in the file UnityViewControllerBase+iOS.mm
Well, we did and it's working for us!!!
//
// Just in case the attached screenshot expires
//
- (NSUInteger)supportedInterfaceOrientations
{
//NSAssert(UnityShouldAutorotate(), #"UnityDefaultViewController should be used only if unity is set to autorotate");
return EnabledAutorotationInterfaceOrientations();
}

Issues after updated to Xcode 5

I had my iOS App up to 98% completed on Xcode 4.6 and iOS 6.1 and it's working OK.
But then problems begin when I try to update my Xcode to version 5 and the SDK to iOS 7.
When I try to run the app on Xcode 5 but with iOS 6.1 it continues working ok, but when I tried to run on SDK 7 I have these issues:
2013-12-17 19:44:47.656 myAPP[2207:70b] *** Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<MKUserLocation 0x9d9af90> valueForUndefinedKey:]: this class is not key value coding-compliant for the key distanceAnnotation.'
*** First throw call stack:
(
0 CoreFoundation 0x01bf65e4 __exceptionPreprocess + 180
1 libobjc.A.dylib 0x019798b6 objc_exception_throw + 44
2 CoreFoundation 0x01c866a1 -[NSException raise] + 17
3 Foundation 0x0142d8ca -[NSObject(NSKeyValueCoding) valueForUndefinedKey:] + 282
4 Foundation 0x0139a921 _NSGetUsingKeyValueGetter + 81
5 Foundation 0x01399f5b -[NSObject(NSKeyValueCoding) valueForKey:] + 260
6 Foundation 0x013b9a5a -[NSObject(NSKeyValueCoding) valueForKeyPath:] + 409
7 Foundation 0x013c68c6 _sortedObjectsUsingDescriptors + 380
8 Foundation 0x013c66d7 -[NSMutableArray(NSKeyValueSorting) sortUsingDescriptors:] + 578
9 myapp
0x00009e50 -[mapa mapViewDidFinishLoadingMap:] + 496
10 MapKit 0x0037e974 -[MKMapView mapViewDidFinishLoadingTiles:] + 78
11 VectorKit 0x050a3ade -[VKMapView mapDidFinishLoadingTiles:] + 78
12 VectorKit 0x050abe4e -[VKMapCanvas mapModelDidFinishLoadingTiles:] + 46
13 VectorKit 0x050b82cd -[VKMapModel didStopLoadingTilesWithError:] + 77
14 VectorKit 0x051ae2e1 -[VKTileProvider didStopLoadingTilesWithError:] + 49
15 VectorKit 0x051b1c99 -[VKTileSource didFinishWithNetwork] + 73
16 VectorKit 0x051c3aa3 __41-[VKResourcesTileSource performDownload:]_block_invoke73 + 51
17 GeoServices 0x04bb98a6 ___ZNK49-[GEOTileLoaderInternal _loadedTile:forKey:info:]66__49-[GEOTileLoaderInternal _loadedTile:forKey:info:]_block_invoke3$_1clERKN8LoadItem9RequesterE_block_invoke_2 + 85
18 libdispatch.dylib 0x021f77f8 _dispatch_call_block_and_release + 15
19 libdispatch.dylib 0x0220c4b0 _dispatch_client_callout + 14
20 libdispatch.dylib 0x021fa75e _dispatch_main_queue_callback_4CF + 340
21 CoreFoundation 0x01c5ba5e __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 14
22 CoreFoundation 0x01b9c6bb __CFRunLoopRun + 1963
23 CoreFoundation 0x01b9bac3 CFRunLoopRunSpecific + 467
24 CoreFoundation 0x01b9b8db CFRunLoopRunInMode + 123
25 GraphicsServices 0x033579e2 GSEventRunModal + 192
26 GraphicsServices 0x03357809 GSEventRun + 104
27 UIKit 0x004dad3b UIApplicationMain + 1225
28 FarmValencia 0x000029ad main + 141
29 libdyld.dylib 0x0249e70d start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Theres simply not enough information to correctly debug this item.
I can recommend however that you add a Breakpoint for all Exceptions
Here is an example of adding an All Exception breakpoint in XCode 4. The process is the same in XCode 5
http://www.alauda.ro/2013/02/03/xcode-4-exception-breakpoints/
Aside from that you may try working with NSSetUncaughtExceptionHandler
http://www.cocoawithlove.com/2010/05/handling-unhandled-exceptions-and.html
This will allow you to trap the error and output the results but bear in mind that this is something you should only do during debug.
Wrapping it in an "#if DEBUG" is a good idea.
I hope this helps you out. These kind of bugs are a pain to fix.
NOTE
You may check if the key value set you are using didn't change between SDK's
Are you by chance sending the message valueForUndefinedKey: to the class MKUserLocation?
Here's what the class reference says about getting user location:
"The MKUserLocation class defines a specific type of annotation that identifies the user’s current location. You do not create instances of this class directly. Instead, you retrieve an existing MKUserLocation object from the userLocation property of the map view displayed in your application."
https://developer.apple.com/library/ios/documentation/MapKit/Reference/MKUserLocation_Class/Reference/Reference.html

IBTOOL error 255 in XCODE 5 / work fine in XCODE 4

I want to open and compil my project in XCODE 5 and i have an issue. IBTOOLS error 255. Does anybody have a idea for fix ?
I try all the answered of StackOverFlow, but nothing was good for the case.
Alex.
CompileStoryboard Safetracer/MainStoryboard.storyboard
cd /Users/alexandrepestre/Documents/ThinkMyApp/Lixao/Safetracer
setenv IBSC_MINIMUM_COMPATIBILITY_VERSION 6.1
setenv PATH "/Applications/Xcode 2.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode 2.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
setenv XCODE_DEVELOPER_USR_PATH "/Applications/Xcode 2.app/Contents/Developer/usr/bin/.."
/Applications/Xcode\ 2.app/Contents/Developer/usr/bin/ibtool --errors --warnings --notices --minimum-deployment-target 6.1 --output-format human-readable-text --compile /Users/alexandrepestre/Library/Developer/Xcode/DerivedData/Safetracer-bdnzaaahcuqikggnpqlvwvrsbddt/Build/Products/Debug-iphoneos/safetracer.app/MainStoryboard.storyboardc /Users/alexandrepestre/Documents/ThinkMyApp/Lixao/Safetracer/Safetracer/MainStoryboard.storyboard
2013-09-13 16:07:15.433 ibtoold[4775:707] [MT] DVTAssertions: Warning in /SourceCache/IDEInterfaceBuilderCocoaTouch/IDEInterfaceBuilderCocoaTouch-3742/IBPlugin/Documents/IBStoryboardMetricsInferrer.m:324
Details: Failed to push inherited simulated metrics to all scenes.
Object: <IBStoryboardMetricsInferrer: 0x7f969aab4ad0>
Method: -rebuildInferredMetrics
Thread: <NSThread: 0x7f9699c191b0>{name = (null), num = 1}
Please file a bug at http://bugreport.apple.com with this warning message and any useful information you can provide.
2013-09-13 16:07:19.057 ibtoold[4775:707] [MT] DVTAssertions: Warning in /SourceCache/IDEInterfaceBuilderCocoaTouch/IDEInterfaceBuilderCocoaTouch-3742/IBPlugin/Documents/IBStoryboardMetricsInferrer.m:324
Details: Failed to push inherited simulated metrics to all scenes.
Object: <IBStoryboardMetricsInferrer: 0x7f969dacc750>
Method: -rebuildInferredMetrics
Thread: <NSThread: 0x7f9699c191b0>{name = (null), num = 1}
Please file a bug at http://bugreport.apple.com with this warning message and any useful information you can provide.
2013-09-13 16:07:30.797 ibtoold[4775:707] [MT] DVTAssertions: ASSERTION FAILURE in /SourceCache/IDEInterfaceBuilderCocoaTouch/IDEInterfaceBuilderCocoaTouch-3742/IBPlugin/Utilities/IBObjectMarshalling.m:670
Details: Failed to compile nib consisting of IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBUIButton, IBUIButton, IBUIButton, IBUIButton, IBUIButton, IBUIImageView, IBUIImageView, IBUIImageView, IBUIImageView, IBUIImageView, IBUILabel, IBUILabel, IBUILabel, IBUILabel, IBUILabel, IBUILabel, IBUILabel, IBUILabel, IBUILabel, IBUILabel, IBUILabel, and IBUIView.
Interface Builder encountered an error communicating with the iOS Simulator. If you choose to file a crash report or radar for this issue, please check Console.app for crash reports for "Interface Builder Cocoa Touch Tool" and include their content in your crash report.
Exception name: NSInvalidArgumentException
Exception reason: NSConcreteAttributedString initWithString:: nil value
Exception backtrace:
0. CoreFoundation 0x0226e5c8 __exceptionPreprocess
1. libobjc.A.dylib 0x01fed8b6 objc_exception_throw
2. CoreFoundation 0x0226e3bb +
3. Foundation 0x01be48c0 -
4. Foundation 0x01be4761 -
5. UIKit 0x00ee50f6 -
6. UIKit 0x00ee54c7 -
7. UIKit 0x0112fa96 -
8. UIKit 0x011303e3 -
9. UIKit 0x0112f6b4 -
10. UIKit 0x0112fa96 -
11. UIKit 0x011303e3 -
12. UIKit 0x00d8995b -
13. UIKit 0x0112fa96 -
14. UIKit 0x011303e3 -
15. UIKit 0x0112f6b4 -
16. UIKit 0x0112fa96 -
17. UIKit 0x011303e3 -
18. ??? 0x00014c80
19. ??? 0x00014e4e
20. ??? 0x00015363
21. ??? 0x00007565
22. IBFoundation 0x00360701 __72-[IBMessageReceiveChannel deliverMessage:toTarget:withArguments:result:]_block_invoke
23. IBFoundation 0x00360446 -
24. IBFoundation 0x00360123 __80-[IBMessageReceiveChannel runBlockingReceiveLoopNotifyingQueue:notifyingTarget:]_block_invoke
25. libdispatch.dylib 0x029c3444 _dispatch_barrier_sync_f_slow_invoke
26. libdispatch.dylib 0x029d44b0 _dispatch_client_callout
27. libdispatch.dylib 0x029c2766 _dispatch_main_queue_callback_4CF
28. CoreFoundation 0x022d3a5e __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__
29. CoreFoundation 0x0221472b __CFRunLoopRun
30. CoreFoundation 0x02213b33 CFRunLoopRunSpecific
31. CoreFoundation 0x0221394b CFRunLoopRunInMode
32. Foundation 0x01c23c05 -
33. ??? 0x00036b67
34. ??? 0x00036c62
35. ??? 0x00036dc7
36. ??? 0x0000c20e
37. libdyld.dylib 0x95727725 start
Exception info:{
}
Function: void IBAssertMarshallingFailure(NSString *__strong, NSString *__strong)
Thread: <NSThread: 0x7f9699c191b0>{name = (null), num = 1}
Hints: None
Backtrace:
0 0x000000010d20ff2a -[DVTAssertionHandler handleFailureInFunction:fileName:lineNumber:messageFormat:arguments:] (in DVTFoundation)
1 0x000000010d20f684 _DVTAssertionHandler (in DVTFoundation)
2 0x000000010d20f984 _DVTAssertionFailureHandler (in DVTFoundation)
3 0x0000000112774df6 IBAssertMarshallingFailure (in IDEInterfaceBuilderCocoaTouchIntegration)
4 0x000000011285b59a (in IDEInterfaceBuilderCocoaTouchIntegration)
5 0x000000011285ba0d (in IDEInterfaceBuilderCocoaTouchIntegration)
6 0x000000011286b445 (in IDEInterfaceBuilderCocoaTouchIntegration)
7 0x000000011286f4b0 (in IDEInterfaceBuilderCocoaTouchIntegration)
8 0x000000011287063e (in IDEInterfaceBuilderCocoaTouchIntegration)
9 0x000000010c64c40a IBWithAutoInvalidationPool (in IDEInterfaceBuilderKit)
10 0x0000000112870363 (in IDEInterfaceBuilderCocoaTouchIntegration)
11 0x0000000112856316 (in IDEInterfaceBuilderCocoaTouchIntegration)
12 0x000000011285683c (in IDEInterfaceBuilderCocoaTouchIntegration)
13 0x000000010c39b2fe __47-[IBDocument compiledPackageWithOptions:error:]_block_invoke (in IDEInterfaceBuilderKit)
14 0x000000010c3be250 -[IBDocument assertIfArbitrationIsScheduledDuring:] (in IDEInterfaceBuilderKit)
15 0x000000010c39b272 -[IBDocument compiledPackageWithOptions:error:] (in IDEInterfaceBuilderKit)
16 0x000000010c17c757 (in ibtoold)
17 0x000000010c17fc21 (in ibtoold)
18 0x000000010c18a23d (in ibtoold)
19 0x000000010c18a781 (in ibtoold)
20 0x000000010c18a654 (in ibtoold)
21 0x000000010c188ade (in ibtoold)
22 0x000000010c189eb2 (in ibtoold)
23 0x000000010c189610 (in ibtoold)
24 0x00007fff8be7a7e1 start (in libdyld.dylib)
25 0x0000000000000001
Command /Applications/Xcode 2.app/Contents/Developer/usr/bin/ibtool failed with exit code 255
e
It appears that ibtool is not able to handle a storyboard created with an earlier xcode version where the text attribute can be omitted on a UILabel. Easiest way to fix is to open the storyboard in your editor of choice and add the missing text attributes, text="".
I fix the bugs. There is 2 label on viewController with no text in tne textlabel. I put some text (Label) and now the app build and run well.
Alex.
I fixed through re-ceate xib resource with xcode5.
I hate Xcode for this type of thing.
Most of the ibtool error get solved just by cleaning the project and then rebuilding it.

Resources