Skip to content

Application fails with Segmentation fault on iOS when using ScrollView #1447

@rosen-vladimirov

Description

@rosen-vladimirov

In some cases, the NativeScript application will fail on iOS device with Segmentation Fault: 11 when it is using ScrollView. The problem is tricky to be reproduced, but here are the prerequisites:

  1. Use XCode 7.0 for building the app (currently this is the XCode on our NativeScript build machine).

  2. Use tns-core-modules 1.5.0 or 1.5.1

  3. Use ScrollView in any of your XML's.

For example the issue was reproduced with sample Tasks and in the device log we saw:

JavaScript error:
file:///app/tns_modules/ui/builder/builder.js:147:56: JS ERROR Error: Building UI from XML. @file:///app/components/login/login.xml:5:5
 Module 'ui/scroll-view' not found for element 'ScrollView'.
 More than one initializer found that matches constructor invocation: initWithCoder: initWithFrame: init

And Segmentation Fault: 11 before that.

The problem occurred due to calling new UIScrollView() in ScrollView's constructor.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions