Commit f8fa8ec8 authored by Joshua Roesslein's avatar Joshua Roesslein
Browse files

Merge pull request #562 from RussellTaylor83/master

parents 24ca4ea4 e1466e02
......@@ -1271,8 +1271,8 @@ class API(object):
if os.path.getsize(filename) > (max_size * 1024):
raise TweepError('File is too big, must be less than %skb.' % max_size)
except os.error:
raise TweepError('Unable to access file')
except os.error as e:
raise TweepError('Unable to access file: %s' % e.strerror)
# build the mulitpart-formdata body
fp = open(filename, 'rb')
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment