Description
Process: com.wdc.albums.production, PID: 15086
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: android.view.InflateException: Binary XML file line #66: Error inflating class
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.LayoutInflater.createView(LayoutInflater.java:640)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:750)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.LayoutInflater.rInflate(LayoutInflater.java:813)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.LayoutInflater.rInflate(LayoutInflater.java:821)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.LayoutInflater.rInflate(LayoutInflater.java:821)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:511)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:415)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at com.wdc.collect.screens.collections.CollectionsAdapter.onCreateViewHolder(CollectionsAdapter.java:192)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at com.wdc.collect.screens.collections.CollectionsAdapter.onCreateViewHolder(CollectionsAdapter.java:39)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.RecyclerView$Adapter.createViewHolder(RecyclerView.java:4783)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:4089)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:3999)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.LinearLayoutManager$LayoutState.next(LinearLayoutManager.java:1892)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.LinearLayoutManager.layoutChunk(LinearLayoutManager.java:1338)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.LinearLayoutManager.fill(LinearLayoutManager.java:1301)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.LinearLayoutManager.onLayoutChildren(LinearLayoutManager.java:534)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.RecyclerView.dispatchLayout(RecyclerView.java:2411)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.support.v7.widget.RecyclerView.onLayout(RecyclerView.java:2709)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.View.layout(View.java:16550)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewGroup.layout(ViewGroup.java:5303)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1077)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.View.layout(View.java:16550)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewGroup.layout(ViewGroup.java:5303)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.widget.FrameLayout.layoutChildren(FrameLayout.java:573)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.widget.FrameLayout.onLayout(FrameLayout.java:508)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.View.layout(View.java:16550)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewGroup.layout(ViewGroup.java:5303)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1077)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.View.layout(View.java:16550)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewGroup.layout(ViewGroup.java:5303)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.widget.FrameLayout.layoutChildren(FrameLayout.java:573)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.widget.FrameLayout.onLayout(FrameLayout.java:508)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.View.layout(View.java:16550)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewGroup.layout(ViewGroup.java:5303)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at com.android.internal.widget.ActionBarOverlayLayout.onLayout(ActionBarOverlayLayout.java:494)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.View.layout(View.java:16550)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewGroup.layout(ViewGroup.java:5303)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.widget.FrameLayout.layoutChildren(FrameLayout.java:573)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.widget.FrameLayout.onLayout(FrameLayout.java:508)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.View.layout(View.java:16550)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewGroup.layout(ViewGroup.java:5303)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2312)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2025)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1180)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6563)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.Choreographer$CallbackRecord.run(Choreographer.java:777)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.Choreographer.doCallbacks(Choreographer.java:590)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.Choreographer.doFrame(Choreographer.java:560)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:763)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.os.Handler.handleCallback(Handler.java:739)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:95)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.os.Looper.loop(Looper.java:145)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5835)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at java.lang.reflect.Method.invoke(Method.java:372)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
11-04 10:31:36.282 15086-15086/? E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
I'm facing the same issue? Is there a work around for this?
my xml
<com.facebook.drawee.view.SimpleDraweeView
android:id="@+id/collection_bg"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
fresco:actualImageScaleType="centerCrop"
fresco:fadeDuration="300"
fresco:failureImage="@color/dark_gray"
fresco:failureImageScaleType="centerCrop"
fresco:placeholderImage="@drawable/empty_collection"
fresco:placeholderImageScaleType="centerCrop"
fresco:retryImageScaleType="centerCrop" />
<TextView
android:id="@+id/collection_title"
style="@style/WdFont.BodyFont.TitleSize.Shadow"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:gravity="center_horizontal"
android:paddingBottom="@dimen/collection_list_item_margin" />
and I've
//Fresco initialization
Fresco.initialize(this, mPipelineConfig); in OnCreate of the Application class.
I removed
fresco:placeholderImage="@drawable/empty_collection"
fresco:placeholderImageScaleType="centerCrop"
from SimpleDraweeView its not crashing.
Activity
tyronen commentedon Nov 5, 2015
What is the empty_collection drawable?
veereshkalmath commentedon Nov 6, 2015
empty_collection is a png
tyronen commentedon Nov 6, 2015
Do you see a "Caused by" anywhere in the stack trace?
If not, can you set a breakpoint inside the GenericDraweeView.inflateHierarchy method? Try to navigate to the exact point of the crash.
0kai commentedon Nov 24, 2015
this bug will happend when OutOfMemoryError "com.facebook.drawee.view.GenericDraweeView.inflateHierarchy(GenericDraweeView.java:252)"
balazsbalazs commentedon Nov 25, 2015
How big is the empty_collection drawable? Can you attach it?
My gut feeling is that the placeholder image is just too big for the device to load. It's usually is a good practice to use small images as placeholders.
balazsbalazs commentedon Nov 25, 2015
Let's continue this discussion in #780 - the cause seems to be the same.
duplicate of: #780