Last active
February 11, 2017 08:22
-
-
Save a1Gupta/84b767e46879e39aa5830024673948e8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Identify blank/broken image | |
try: | |
file = cStringIO.StringIO(urllib.urlopen(user.profile_pic.url).read()) | |
img = Image.open(file) | |
except: | |
print "broken image" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment