Android sometimes crashing


#1

Hi, I am facing the problem with android. Sometimes my app crashes. Log is bellow. Really don’t know what is causing this problem. I am using WebImage plugin, so problem with memory there couldn’t be. On iOS is everything great and smooth.

“tns-android”: {
“version”: “3.4.2”
}
}

Here is full error log. I can give full project repository if there will be someone who could help me.

I/dalvikvm(25886):   at com.tns.Runtime.callJSMethodNative(Native Method)
I/dalvikvm(25886):   at com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
I/dalvikvm(25886):   at com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
I/dalvikvm(25886):   at com.tns.Runtime.callJSMethod(Runtime.java:957)
I/dalvikvm(25886):   at com.tns.Runtime.callJSMethod(Runtime.java:941)
I/dalvikvm(25886):   at com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err: com.tns.NativeScriptException: 
System.err: Calling js method getView failed
System.err: Error: java.lang.OutOfMemoryError
System.err:     android.graphics.BitmapFactory.nativeDecodeStream(Native Method)
System.err:     android.graphics.BitmapFactory.decodeStreamInternal(BitmapFactory.java:709)
System.err:     android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:685)
System.err:     android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:447)
System.err:     android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:486)
System.err:     android.graphics.drawable.Drawable.createFromPath(Drawable.java:1005)
System.err:     com.tns.Runtime.callJSMethodNative(Native Method)
System.err:     com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
System.err:     com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
System.err:     com.tns.Runtime.callJSMethod(Runtime.java:957)
System.err:     com.tns.Runtime.callJSMethod(Runtime.java:941)
System.err:     com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err:     com.tns.gen.android.widget.BaseAdapter_frnal_ts_helpers_l58_c38__ListViewAdapter.getView(BaseAdapter_frnal_ts_helpers_l58_c38__ListViewAdapter.java:47)
System.err:     android.widget.AbsListView.obtainView(AbsListView.java:2738)
System.err:     android.widget.ListView.makeAndAddView(ListView.java:1811)
System.err:     android.widget.ListView.fillDown(ListView.java:697)
System.err:     android.widget.ListView.fillFromTop(ListView.java:763)
System.err:     android.widget.ListView.layoutChildren(ListView.java:1627)
System.err:     android.widget.AbsListView.onLayout(AbsListView.java:2563)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.support.v4.widget.SwipeRefreshLayout.onLayout(SwipeRefreshLayout.java:610)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.StackLayout.layoutVertical(StackLayout.java:169)
System.err:     org.nativescript.widgets.StackLayout.onLayout(StackLayout.java:123)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.StackLayout.layoutVertical(StackLayout.java:169)
System.err:     org.nativescript.widgets.StackLayout.onLayout(StackLayout.java:123)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.GridLayout.onLayout(GridLayout.java:353)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err:     android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err:     android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.GridLayout.onLayout(GridLayout.java:353)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.ContentLayout.onLayout(ContentLayout.java:73)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err:     android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.LinearLayout.setChildFrame(LinearLayout.java:1677)
System.err:     android.widget.LinearLayout.layoutVertical(LinearLayout.java:1531)
System.err:     android.widget.LinearLayout.onLayout(LinearLayout.java:1440)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err:     android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2356)
System.err:     android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2069)
System.err:     android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1254)
System.err:     android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6637)
System.err:     android.view.Choreographer$CallbackRecord.run(Choreographer.java:814)
System.err:     android.view.Choreographer.doCallbacks(Choreographer.java:614)
System.err:     android.view.Choreographer.doFrame(Choreographer.java:584)
System.err:     android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:800)
System.err:     android.os.Handler.handleCallback(Handler.java:733)
System.err:     android.os.Handler.dispatchMessage(Handler.java:95)
System.err:     android.os.Looper.loop(Looper.java:146)
System.err:     android.app.ActivityThread.main(ActivityThread.java:5602)
System.err:     java.lang.reflect.Method.invokeNative(Native Method)
System.err:     java.lang.reflect.Method.invoke(Method.java:515)
System.err:     com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
System.err:     com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
System.err:     dalvik.system.NativeStart.main(Native Method)
System.err: File: "file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/nativescript-web-image-cache/WebImageCache.js, line: 314, column: 54
System.err: StackTrace: 
System.err: 	Frame: function:'getPlaceholderImageDrawable', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/nativescript-web-image-cache/WebImageCache.js', line: 314, column: 55
System.err: 	Frame: function:'setPlaceholder', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/nativescript-web-image-cache/WebImageCache.js', line: 118, column: 18
System.err: 	Frame: function:'WebImage.createNativeView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/nativescript-web-image-cache/WebImageCache.js', line: 232, column: 7
System.err: 	Frame: function:'ViewBase._setupUI', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 412, column: 35
System.err: 	Frame: function:'', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 456, column: 19
System.err: 	Frame: function:'LayoutBaseCommon.eachChildView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js', line: 125, column: 26
System.err: 	Frame: function:'ViewCommon.eachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view-common.js', line: 699, column: 14
System.err: 	Frame: function:'ViewBase._setupUI', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 455, column: 14
System.err: 	Frame: function:'', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 456, column: 19
System.err: 	Frame: function:'LayoutBaseCommon.eachChildView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js', line: 125, column: 26
System.err: 	Frame: function:'ViewCommon.eachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view-common.js', line: 699, column: 14
System.err: 	Frame: function:'ViewBase._setupUI', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 455, column: 14
System.err: 	Frame: function:'', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 456, column: 19
System.err: 	Frame: function:'LayoutBaseCommon.eachChildView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js', line: 125, column: 26
System.err: 	Frame: function:'ViewCommon.eachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view-common.js', line: 699, column: 14
System.err: 	Frame: function:'ViewBase._setupUI', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 455, column: 14
System.err: 	Frame: function:'', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 456, column: 19
System.err: 	Frame: function:'LayoutBaseCommon.eachChildView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js', line: 125, column: 26
System.err: 	Frame: function:'ViewCommon.eachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view-common.js', line: 699, column: 14
System.err: 	Frame: function:'ViewBase._setupUI', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 455, column: 14
System.err: 	Frame: function:'ViewBase._addViewCore', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 357, column: 18
System.err: 	Frame: function:'ViewBase._addView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 346, column: 14
System.err: 	Frame: function:'ListViewAdapter.getView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/list-view/list-view.js', line: 257, column: 36
System.err: 	at com.tns.Runtime.callJSMethodNative(Native Method)
System.err: 	at com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
System.err: 	at com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
System.err: 	at com.tns.Runtime.callJSMethod(Runtime.java:957)
System.err: 	at com.tns.Runtime.callJSMethod(Runtime.java:941)
System.err: 	at com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err: 	at com.tns.gen.android.widget.BaseAdapter_frnal_ts_helpers_l58_c38__ListViewAdapter.getView(BaseAdapter_frnal_ts_helpers_l58_c38__ListViewAdapter.java:47)
System.err: 	at android.widget.AbsListView.obtainView(AbsListView.java:2738)
System.err: 	at android.widget.ListView.makeAndAddView(ListView.java:1811)
System.err: 	at android.widget.ListView.fillDown(ListView.java:697)
System.err: 	at android.widget.ListView.fillFromTop(ListView.java:763)
System.err: 	at android.widget.ListView.layoutChildren(ListView.java:1627)
System.err: 	at android.widget.AbsListView.onLayout(AbsListView.java:2563)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.support.v4.widget.SwipeRefreshLayout.onLayout(SwipeRefreshLayout.java:610)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.StackLayout.layoutVertical(StackLayout.java:169)
System.err: 	at org.nativescript.widgets.StackLayout.onLayout(StackLayout.java:123)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.StackLayout.layoutVertical(StackLayout.java:169)
System.err: 	at org.nativescript.widgets.StackLayout.onLayout(StackLayout.java:123)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.GridLayout.onLayout(GridLayout.java:353)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err: 	at android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err: 	at android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.GridLayout.onLayout(GridLayout.java:353)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.ContentLayout.onLayout(ContentLayout.java:73)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err: 	at android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1677)
System.err: 	at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1531)
System.err: 	at android.widget.LinearLayout.onLayout(LinearLayout.java:1440)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err: 	at android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2356)
System.err: 	at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2069)
System.err: 	at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1254)
System.err: 	at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6637)
System.err: 	at android.view.Choreographer$CallbackRecord.run(Choreographer.java:814)
System.err: 	at android.view.Choreographer.doCallbacks(Choreographer.java:614)
System.err: 	at android.view.Choreographer.doFrame(Choreographer.java:584)
System.err: 	at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:800)
System.err: 	at android.os.Handler.handleCallback(Handler.java:733)
System.err: 	at android.os.Handler.dispatchMessage(Handler.java:95)
System.err: 	at android.os.Looper.loop(Looper.java:146)
System.err: 	at android.app.ActivityThread.main(ActivityThread.java:5602)
System.err: 	at java.lang.reflect.Method.invokeNative(Native Method)
System.err: 	at java.lang.reflect.Method.invoke(Method.java:515)
System.err: 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
System.err: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
System.err: 	at dalvik.system.NativeStart.main(Native Method)
System.err: Caused by: java.lang.OutOfMemoryError
System.err: 	at android.graphics.BitmapFactory.nativeDecodeStream(Native Method)
System.err: 	at android.graphics.BitmapFactory.decodeStreamInternal(BitmapFactory.java:709)
System.err: 	at android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:685)
System.err: 	at android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:447)
System.err: 	at android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:486)
System.err: 	at android.graphics.drawable.Drawable.createFromPath(Drawable.java:1005)
System.err: 	... 78 more
ActivityManager: Process cz.esports.skslovanbratislava (pid 25886) (adj 0) has died.

Thank you so much guys!


#2

Which NativeScript plugin are you referring to? I couldn’t find any which is named WebImage.


#3

Oh sorry. This plugin https://www.npmjs.com/package/nativescript-web-image-cache


#4

Try nativescript-image-cache plugin
that uses a newer version of that Pod

Also, use nativescript-fresco for Android.

It has the best implementation for fresco for nativescript.

(to make both of these plugins work together, you will have to change the version of fresco used in nativescript-image-cache’s platform/android/include.gradle file to compile "com.facebook.fresco:fresco:0.9.0+" )


#5

Thank you. I replace image plugin to this. But when I am navigating through the app sometime I still got crash.

I/dalvikvm(30489):   at com.tns.Runtime.callJSMethodNative(Native Method)
I/dalvikvm(30489):   at com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
I/dalvikvm(30489):   at com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
I/dalvikvm(30489):   at com.tns.Runtime.callJSMethod(Runtime.java:957)
I/dalvikvm(30489):   at com.tns.Runtime.callJSMethod(Runtime.java:941)
I/dalvikvm(30489):   at com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err: com.tns.NativeScriptException: 
System.err: Calling js method getView failed
System.err: Error: java.lang.OutOfMemoryError
System.err:     android.graphics.BitmapFactory.nativeDecodeStream(Native Method)
System.err:     android.graphics.BitmapFactory.decodeStreamInternal(BitmapFactory.java:709)
System.err:     android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:685)
System.err:     android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:447)
System.err:     android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:486)
System.err:     android.graphics.drawable.Drawable.createFromPath(Drawable.java:1005)
System.err:     com.tns.Runtime.callJSMethodNative(Native Method)
System.err:     com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
System.err:     com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
System.err:     com.tns.Runtime.callJSMethod(Runtime.java:957)
System.err:     com.tns.Runtime.callJSMethod(Runtime.java:941)
System.err:     com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err:     com.tns.gen.android.widget.BaseAdapter_frnal_ts_helpers_l58_c38__ListViewAdapter.getView(BaseAdapter_frnal_ts_helpers_l58_c38__ListViewAdapter.java:47)
System.err:     android.widget.AbsListView.obtainView(AbsListView.java:2738)
System.err:     android.widget.ListView.makeAndAddView(ListView.java:1811)
System.err:     android.widget.ListView.fillDown(ListView.java:697)
System.err:     android.widget.ListView.fillFromTop(ListView.java:763)
System.err:     android.widget.ListView.layoutChildren(ListView.java:1627)
System.err:     android.widget.AbsListView.onLayout(AbsListView.java:2563)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.support.v4.widget.SwipeRefreshLayout.onLayout(SwipeRefreshLayout.java:610)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.StackLayout.layoutVertical(StackLayout.java:169)
System.err:     org.nativescript.widgets.StackLayout.onLayout(StackLayout.java:123)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.StackLayout.layoutVertical(StackLayout.java:169)
System.err:     org.nativescript.widgets.StackLayout.onLayout(StackLayout.java:123)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.GridLayout.onLayout(GridLayout.java:353)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err:     android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err:     android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.GridLayout.onLayout(GridLayout.java:353)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err:     org.nativescript.widgets.ContentLayout.onLayout(ContentLayout.java:73)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err:     android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.LinearLayout.setChildFrame(LinearLayout.java:1677)
System.err:     android.widget.LinearLayout.layoutVertical(LinearLayout.java:1531)
System.err:     android.widget.LinearLayout.onLayout(LinearLayout.java:1440)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err:     android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err:     android.view.View.layout(View.java:15762)
System.err:     android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err:     android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2356)
System.err:     android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2069)
System.err:     android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1254)
System.err:     android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6637)
System.err:     android.view.Choreographer$CallbackRecord.run(Choreographer.java:814)
System.err:     android.view.Choreographer.doCallbacks(Choreographer.java:614)
System.err:     android.view.Choreographer.doFrame(Choreographer.java:584)
System.err:     android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:800)
System.err:     android.os.Handler.handleCallback(Handler.java:733)
System.err:     android.os.Handler.dispatchMessage(Handler.java:95)
System.err:     android.os.Looper.loop(Looper.java:146)
System.err:     android.app.ActivityThread.main(ActivityThread.java:5602)
System.err:     java.lang.reflect.Method.invokeNative(Native Method)
System.err:     java.lang.reflect.Method.invoke(Method.java:515)
System.err:     com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
System.err:     com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
System.err:     dalvik.system.NativeStart.main(Native Method)
System.err: File: "file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/nativescript-image-cache/ns-image-cache.js, line: 251, column: 62
System.err: StackTrace: 
System.err: 	Frame: function:'getPlaceholderImageDrawable', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/nativescript-image-cache/ns-image-cache.js', line: 251, column: 63
System.err: 	Frame: function:'NSImage.setPlaceholder', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/nativescript-image-cache/ns-image-cache.js', line: 144, column: 24
System.err: 	Frame: function:'NSImage.(anonymous function)', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/nativescript-image-cache/ns-image-cache.js', line: 118, column: 18
System.err: 	Frame: function:'applyAllNativeSetters', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/properties/properties.js', line: 961, column: 28
System.err: 	Frame: function:'initNativeView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/properties/properties.js', line: 905, column: 9
System.err: 	Frame: function:'ViewBase.onResumeNativeUpdates', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 555, column: 22
System.err: 	Frame: function:'ViewBase._resumeNativeUpdates', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 223, column: 18
System.err: 	Frame: function:'ViewBase.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 200, column: 14
System.err: 	Frame: function:'View.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view.js', line: 62, column: 35
System.err: 	Frame: function:'', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 206, column: 19
System.err: 	Frame: function:'LayoutBaseCommon.eachChildView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js', line: 125, column: 26
System.err: 	Frame: function:'ViewCommon.eachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view-common.js', line: 699, column: 14
System.err: 	Frame: function:'ViewBase._loadEachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 205, column: 14
System.err: 	Frame: function:'ViewBase.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 201, column: 14
System.err: 	Frame: function:'View.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view.js', line: 62, column: 35
System.err: 	Frame: function:'', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 206, column: 19
System.err: 	Frame: function:'LayoutBaseCommon.eachChildView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js', line: 125, column: 26
System.err: 	Frame: function:'ViewCommon.eachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view-common.js', line: 699, column: 14
System.err: 	Frame: function:'ViewBase._loadEachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 205, column: 14
System.err: 	Frame: function:'ViewBase.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 201, column: 14
System.err: 	Frame: function:'View.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view.js', line: 62, column: 35
System.err: 	Frame: function:'', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 206, column: 19
System.err: 	Frame: function:'LayoutBaseCommon.eachChildView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js', line: 125, column: 26
System.err: 	Frame: function:'ViewCommon.eachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view-common.js', line: 699, column: 14
System.err: 	Frame: function:'ViewBase._loadEachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 205, column: 14
System.err: 	Frame: function:'ViewBase.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 201, column: 14
System.err: 	Frame: function:'View.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view.js', line: 62, column: 35
System.err: 	Frame: function:'', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 206, column: 19
System.err: 	Frame: function:'LayoutBaseCommon.eachChildView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/layouts/layout-base-common.js', line: 125, column: 26
System.err: 	Frame: function:'ViewCommon.eachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view-common.js', line: 699, column: 14
System.err: 	Frame: function:'ViewBase._loadEachChild', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 205, column: 14
System.err: 	Frame: function:'ViewBase.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 201, column: 14
System.err: 	Frame: function:'View.onLoaded', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view/view.js', line: 62, column: 35
System.err: 	Frame: function:'ViewBase._addViewCore', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 360, column: 18
System.err: 	Frame: function:'ViewBase._addView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 346, column: 14
System.err: 	Frame: function:'ListViewAdapter.getView', file:'file:///data/data/cz.esports.skslovanbratislava/files/app/tns_modules/tns-core-modules/ui/list-view/list-view.js', line: 257, column: 36
System.err: 	at com.tns.Runtime.callJSMethodNative(Native Method)
System.err: 	at com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
System.err: 	at com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
System.err: 	at com.tns.Runtime.callJSMethod(Runtime.java:957)
System.err: 	at com.tns.Runtime.callJSMethod(Runtime.java:941)
System.err: 	at com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err: 	at com.tns.gen.android.widget.BaseAdapter_frnal_ts_helpers_l58_c38__ListViewAdapter.getView(BaseAdapter_frnal_ts_helpers_l58_c38__ListViewAdapter.java:47)
System.err: 	at android.widget.AbsListView.obtainView(AbsListView.java:2738)
System.err: 	at android.widget.ListView.makeAndAddView(ListView.java:1811)
System.err: 	at android.widget.ListView.fillDown(ListView.java:697)
System.err: 	at android.widget.ListView.fillFromTop(ListView.java:763)
System.err: 	at android.widget.ListView.layoutChildren(ListView.java:1627)
System.err: 	at android.widget.AbsListView.onLayout(AbsListView.java:2563)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.support.v4.widget.SwipeRefreshLayout.onLayout(SwipeRefreshLayout.java:610)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.StackLayout.layoutVertical(StackLayout.java:169)
System.err: 	at org.nativescript.widgets.StackLayout.onLayout(StackLayout.java:123)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.StackLayout.layoutVertical(StackLayout.java:169)
System.err: 	at org.nativescript.widgets.StackLayout.onLayout(StackLayout.java:123)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.GridLayout.onLayout(GridLayout.java:353)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err: 	at android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err: 	at android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.GridLayout.onLayout(GridLayout.java:353)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at org.nativescript.widgets.CommonLayoutParams.layoutChild(CommonLayoutParams.java:222)
System.err: 	at org.nativescript.widgets.ContentLayout.onLayout(ContentLayout.java:73)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err: 	at android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1677)
System.err: 	at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1531)
System.err: 	at android.widget.LinearLayout.onLayout(LinearLayout.java:1440)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:453)
System.err: 	at android.widget.FrameLayout.onLayout(FrameLayout.java:388)
System.err: 	at android.view.View.layout(View.java:15762)
System.err: 	at android.view.ViewGroup.layout(ViewGroup.java:4867)
System.err: 	at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2356)
System.err: 	at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2069)
System.err: 	at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1254)
System.err: 	at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6637)
System.err: 	at android.view.Choreographer$CallbackRecord.run(Choreographer.java:814)
System.err: 	at android.view.Choreographer.doCallbacks(Choreographer.java:614)
System.err: 	at android.view.Choreographer.doFrame(Choreographer.java:584)
System.err: 	at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:800)
System.err: 	at android.os.Handler.handleCallback(Handler.java:733)
System.err: 	at android.os.Handler.dispatchMessage(Handler.java:95)
System.err: 	at android.os.Looper.loop(Looper.java:146)
System.err: 	at android.app.ActivityThread.main(ActivityThread.java:5602)
System.err: 	at java.lang.reflect.Method.invokeNative(Native Method)
System.err: 	at java.lang.reflect.Method.invoke(Method.java:515)
System.err: 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
System.err: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
System.err: 	at dalvik.system.NativeStart.main(Native Method)
System.err: Caused by: java.lang.OutOfMemoryError
System.err: 	at android.graphics.BitmapFactory.nativeDecodeStream(Native Method)
System.err: 	at android.graphics.BitmapFactory.decodeStreamInternal(BitmapFactory.java:709)
System.err: 	at android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:685)
System.err: 	at android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:447)
System.err: 	at android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:486)
System.err: 	at android.graphics.drawable.Drawable.createFromPath(Drawable.java:1005)
System.err: 	... 78 more
ActivityManager: Process cz.esports.skslovanbratislava (pid 30489) (adj 0) has died.


#6

And there is my logcat

https://pastebin.com/z3PdrpZ4


#7

How big are the images which you are trying to load?

If the size are in MB, then you might want to compress them.


#8

This kind of images. https://slovan.azureedge.net/_obrazky/top.2017/21/26741.jpg I think that size is normal.


#9

Yes, this seems pretty normal.

Try setting android:largeHeap="true" on the application tag, in your android manifest file.


#10

I think that’s ok now.

thank you so much :slight_smile: