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
Crash when calling cancelCurrentImageLoad on UIIMageView #785
Comments
I'm having the exact same problem here. |
@Kry256 however i do not get the crash you suggested. |
In order to resolve this crash, you need to import the newly added files: UIView+WebCacheOperation.h |
I can't reproduce the crash using the demo project. I don't see why a crash because of missing imports. Could you provide more details? Does your copy of SDWebImage contain the |
BTW, fixed the deprecated misspell with 30e034d |
I can confirm that this only occurs when the |
I have tried it inside a clean project. I have all the new classes correctly imported. Basically it happens that when I try to load an image using: Then it will jump inside
And as the first instruction of the method it calls
The call make SDWebImage jumps into
And here the crash happens with this message -[UIImageView sd_cancelImageLoadOperationWithKey:]: unrecognized selector sent |
@Kry256 the demo project has a scenario like that. when you go into the details view it loads the image by calling the sd_setImageWithURL which in turns calls sd_cancelCurrentImageLoad which successfully cals the sd_cancelImageLoadOperationWithKey inside the UIView+WebCacheOperation.m file. |
There must be an issue with your project (either doesn't properly include the |
I just created a test single-view project where I installed SDWebImage via cocoapods
Ran |
Sorry for the late in answer. In the sample project I wasn't able to reproduce this issue, however with the last commit cd4b925 everything came back to work well |
Ok @Kry256, thanks for checking. Will close this one. Please reopen if you still encounter this issue. |
Sorry for the extra late reply. I can confirm, my problem was the fact that after pulling the new version I didn't imported the right categories. Thanks for this cool class. (As a side question, why did you prefixed your methods with |
@valentinradu we prefixed with |
@bpoplauschi Sorry, but i still have this problem. |
I am having this issue again as well. I installed using cocoapods and the methods show up as valid but when running I get unrecognized selector . These items are included in the pod file so everything should be there.
The only thing that may be causing this is that I had Also, that is weird is that |
Just as @brynbodaylee and @coryhymel said check your SDWebImage include it or not ?? UIView+WebCacheOperation.h |
From the last update, when I call cancelCurrentImageLoad from my UIIMageView the app crashes with this message
-[UIImageView sd_cancelImageLoadOperationWithKey:]: unrecognized selector sent to instance 0x172490b0
Also this metho seems to be deprecated, but SDWebImage suggest me to replace as follows
cancelCurrentImageLoad' is deprecated: Use
cancelCurrentImageLoad
.Think this one is only a typing error.
The text was updated successfully, but these errors were encountered: