diff options
author | Scott Moser <smoser@ubuntu.com> | 2011-01-26 09:03:46 -0500 |
---|---|---|
committer | Scott Moser <smoser@ubuntu.com> | 2011-01-26 09:03:46 -0500 |
commit | be11324740ad4624c45a6e909643ab84aecdbf16 (patch) | |
tree | a7a2a7e8a4b4a05ea5a071610b7c52bf4e6ef810 /cloudinit/boto_utils.py | |
parent | f69109bb2be91a7210a88bfb1b4467f80dc6ba64 (diff) | |
download | vyos-cloud-init-be11324740ad4624c45a6e909643ab84aecdbf16.tar.gz vyos-cloud-init-be11324740ad4624c45a6e909643ab84aecdbf16.zip |
change 'except' syntax to python 3 style.
Everywhere that there occurred:
except Exception, e:
changed to
except Exception as e:
Diffstat (limited to 'cloudinit/boto_utils.py')
-rw-r--r-- | cloudinit/boto_utils.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cloudinit/boto_utils.py b/cloudinit/boto_utils.py index 5030e5fd..b38483fa 100644 --- a/cloudinit/boto_utils.py +++ b/cloudinit/boto_utils.py @@ -43,7 +43,7 @@ def retry_url(url, retry_on_404=True): req = urllib2.Request(url) resp = urllib2.urlopen(req) return resp.read() - except urllib2.HTTPError, e: + except urllib2.HTTPError as e: # in 2.6 you use getcode(), in 2.5 and earlier you use code if hasattr(e, 'getcode'): code = e.getcode() |