Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App crashes after calling ImageService.SetTaskForTarget #1567

Open
1 task
ashotjanibekyan opened this issue Jul 14, 2022 · 1 comment
Open
1 task

App crashes after calling ImageService.SetTaskForTarget #1567

ashotjanibekyan opened this issue Jul 14, 2022 · 1 comment

Comments

@ashotjanibekyan
Copy link

🐛 Bug Report

This is not a bug that constantly happens. I saw a few crash logs on App Center. The logs look something like this:

ConditionalWeakTable`2[TKey,TValue].Add (TKey key, TValue value)
ImageService.SetTaskForTarget (FFImageLoading.Work.IImageLoaderTask currentTask)
ImageServiceBase`1[TImageContainer].LoadImage (FFImageLoading.Work.IImageLoaderTask task)
TaskParameterPlatformExtensions.Into[TImageView] (FFImageLoading.Work.TaskParameter parameters, FFImageLoading.Work.ITarget`2[TImageContainer,TImageView] target)
TaskParameterPlatformExtensions.Into (FFImageLoading.Work.TaskParameter parameters, UIKit.UIImageView imageView)
CachedImageRenderer.UpdateImage (UIKit.UIImageView imageView, FFImageLoading.Forms.CachedImage image, FFImageLoading.Forms.CachedImage previousImage)
CachedImageRenderer.OnElementPropertyChanged (System.Object sender, System.ComponentModel.PropertyChangedEventArgs e)

This really doesn't make sense, I looked at the SetTaskForTarget method. It clearly removes targetView before adding a new item. But nevertheless, the "Key already in the list Parameter name: key" exception has occurred.

We can use something like bool TryAdd(TKey key, TValue value) but it would be better to figure out how this error is even possible.

Version: 2.4.11

Platform:

  • 📱 iOS
@mrhemalatha
Copy link

Any update on this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants