self.response.content = resp.read()
success = True
- except urllib2.HTTPError, why:
+ except urllib2.HTTPError as why:
self.response.status_code = why.code
success = True
- except urllib2.HTTPError, why:
+ except urllib2.HTTPError as why:
self.response.status_code = why.code
success = True
- except(urllib2.HTTPError, why):
+ except urllib2.HTTPError as why:
self.response.status_code = why.code
def __repr__(self):
return '<Response [%s]>' % (self.status_code)
-
+
class AuthObject(object):