Describe the bug
After updating coil to version 0.9.1, icons downloaded from network are not loading anymore.
Expected behavior
Icons should be loading normally, instead, just a transparent element is left (icons targets are not ImageViews but CircularImageViews instead (here the library), inside a RecyclerView
To Reproduce
Try loading URL images inside a RecyclerView using a CircularImageView
Logs/Screenshots
I'm not able to report any logs yet, but I will be following up with more details
Version
Android 10, OxygenOS 10.0.7
Thanks for the report. Sounds related to this issue: https://github.com/coil-kt/coil/issues/223. If you disable crossfading do the images display correctly?
After testing this, let me just clarify that the images do actually load if you scroll down and back up. However there are indeed issues with the crossfading.
2020-01-13 22:11:37.219 8534-8534/coil.sample W/System.err: java.lang.IllegalArgumentException: width and height must be > 0
2020-01-13 22:11:37.219 8534-8534/coil.sample W/System.err: at android.graphics.Bitmap.createBitmap(Bitmap.java:1113)
2020-01-13 22:11:37.219 8534-8534/coil.sample W/System.err: at android.graphics.Bitmap.createBitmap(Bitmap.java:1080)
2020-01-13 22:11:37.220 8534-8534/coil.sample W/System.err: at android.graphics.Bitmap.createBitmap(Bitmap.java:1030)
2020-01-13 22:11:37.220 8534-8534/coil.sample W/System.err: at android.graphics.Bitmap.createBitmap(Bitmap.java:991)
2020-01-13 22:11:37.220 8534-8534/coil.sample W/System.err: at de.hdodenhof.circleimageview.CircleImageView.getBitmapFromDrawable(CircleImageView.java:313)
2020-01-13 22:11:37.220 8534-8534/coil.sample W/System.err: at de.hdodenhof.circleimageview.CircleImageView.initializeBitmap(CircleImageView.java:330)
2020-01-13 22:11:37.220 8534-8534/coil.sample W/System.err: at de.hdodenhof.circleimageview.CircleImageView.setImageDrawable(CircleImageView.java:263)
2020-01-13 22:11:37.220 8534-8534/coil.sample W/System.err: at coil.target.ImageViewTarget.setDrawable(ImageViewTarget.kt:44)
Hope this helps @colinrtwhite
As of Coil 1.1 you'll be able to set transition(CrossfadeTransition(preferExactIntrinsicSize = true)) when loading an image into a PhotoView/CircleImageView/any other view that requires a drawable with a non-'-1' intrinsic size. This should fix the image not being displayed.
Most helpful comment
After testing this, let me just clarify that the images do actually load if you scroll down and back up. However there are indeed issues with the crossfading.
Hope this helps @colinrtwhite