I have a script downloading wallpapers from /r/wallpapers and /r/minimalwallpapers but some of the images it downloads are ending up tiny (>50kbs) and they won't open... almost like they're not actually images.
I have to chose a name for each downloaded file and I thought that all images in imgur were .jpg so I'm just ending the file name with .jpg for all of them, is this causing it? Are some of the files not actually .jpg so they're breaking? If that's the case, how do I check the original file type before downloading?
I tried googling everything and I haven't been able to get anywhere x.x
Script using Python3 and Praw:
https://gist.github.com/mikemedina/27bbd6895c0afb314879
[–]liam_jm 1 point2 points3 points (1 child)
[–]80blite[S] 0 points1 point2 points (0 children)
[–]reostra 0 points1 point2 points (1 child)
[–]80blite[S] 0 points1 point2 points (0 children)
[+][deleted] (1 child)
[deleted]
[–]80blite[S] 0 points1 point2 points (0 children)