diff options
author | Martijn Berger <martijn.berger@gmail.com> | 2015-01-26 10:48:55 +0300 |
---|---|---|
committer | Martijn Berger <martijn.berger@gmail.com> | 2015-01-26 10:48:55 +0300 |
commit | 9415976d1785cd615f7585d3e4343a5474b8fe2e (patch) | |
tree | fc936821c2463fd1c2bd6ae3f457f78f9426fad7 /build_files/buildbot/master_unpack.py | |
parent | 5d61cbf008ab4676b4d71a155c8b85c57e54b58b (diff) |
Change exception syntax to be more modern and hopefully fix buildbot issue in the process
Diffstat (limited to 'build_files/buildbot/master_unpack.py')
-rw-r--r-- | build_files/buildbot/master_unpack.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/build_files/buildbot/master_unpack.py b/build_files/buildbot/master_unpack.py index f7ed2d07d28..56ab80dc87f 100644 --- a/build_files/buildbot/master_unpack.py +++ b/build_files/buildbot/master_unpack.py @@ -93,7 +93,7 @@ if not os.path.exists(filename): try: z = zipfile.ZipFile(filename, "r") -except Exception, ex: +except Exception as ex: sys.stderr.write('Failed to open zip file: %s\n' % str(ex)) sys.exit(1) @@ -129,7 +129,7 @@ try: zf.close() z.close() -except Exception, ex: +except Exception as ex: sys.stderr.write('Failed to unzip package: %s\n' % str(ex)) sys.exit(1) @@ -139,6 +139,6 @@ try: if get_platform(f) == platform and get_branch(f) == branch: if f != packagename: os.remove(os.path.join(directory, f)) -except Exception, ex: +except Exception as ex: sys.stderr.write('Failed to remove old packages: %s\n' % str(ex)) sys.exit(1) |