RedditImageGrab icon indicating copy to clipboard operation
RedditImageGrab copied to clipboard

Fix the update flag (now including test)

Open mfabinski opened this issue 8 years ago • 0 comments

fix #52 by adding the specific exception handler in the inner exception handling block.

Now the update flag works as supposed:

matthias@seth:~/git/RedditImageGrab$ python redditdl.py cats ~/Bilder/cats --num 5 --update
Downloading images from "cats" subreddit
    Attempting to download URL[http://www.explodingkittens.com/kittyconvict?2] as [3v84lg].
    WRONG FILE TYPE: http://www.explodingkittens.com/kittyconvict?2 has type: text/html!
    Attempting to download URL[http://imgur.com/98fqWq0.jpg] as [51usgy.jpg].
    URL [http://imgur.com/98fqWq0.jpg] already downloaded.
    Update complete, exiting.
Downloaded 0 files

Thanks to @rachmadaniHaryono for adding tests for the fix continue flag

mfabinski avatar Sep 12 '16 21:09 mfabinski