summaryrefslogtreecommitdiff
path: root/cloud-init.py
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2011-01-26 09:03:46 -0500
committerScott Moser <smoser@ubuntu.com>2011-01-26 09:03:46 -0500
commitbe11324740ad4624c45a6e909643ab84aecdbf16 (patch)
treea7a2a7e8a4b4a05ea5a071610b7c52bf4e6ef810 /cloud-init.py
parentf69109bb2be91a7210a88bfb1b4467f80dc6ba64 (diff)
downloadvyos-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 'cloud-init.py')
-rwxr-xr-xcloud-init.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/cloud-init.py b/cloud-init.py
index adac1874..92d8a091 100755
--- a/cloud-init.py
+++ b/cloud-init.py
@@ -57,7 +57,7 @@ def main():
cfg = cloudinit.get_base_cfg()
(outfmt, errfmt) = CC.get_output_cfg(cfg,"init")
CC.redirect_output(outfmt, errfmt)
- except Exception, e:
+ except Exception as e:
warn("Failed to get and set output config: %s\n" % e)
msg = "cloud-init %s running: %s. up %s seconds" % (cmd, now, uptime)
@@ -70,7 +70,7 @@ def main():
try:
cloudinit.initfs()
- except Exception, e:
+ except Exception as e:
warn("failed to initfs, likely bad things to come: %s\n" % str(e))
@@ -120,7 +120,7 @@ def main():
if outfmt_orig != outfmt or errfmt_orig != errfmt:
warn("stdout, stderr changing to (%s,%s)" % (outfmt,errfmt))
CC.redirect_output(outfmt, errfmt)
- except Exception, e:
+ except Exception as e:
warn("Failed to get and set output config: %s\n" % e)
module_list = CC.read_cc_modules(cc.cfg,"cloud_init_modules")