Skip to content

Commit 108f78d

Browse files
committed
Remove python3 incompatible exception syntax.
Change-Id: I5f0687a83362ceebf03bae4a0a5b109aad7e5200
1 parent d50b575 commit 108f78d

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎openstackclient/compute/v2/server.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ def take_action(self, parsed_args):
236236
dst, src = f.split('=', 1)
237237
try:
238238
files[dst] = open(src)
239-
except IOError, e:
239+
except IOError as e:
240240
raise exceptions.CommandError("Can't open '%s': %s" % (src, e))
241241

242242
if parsed_args.min > parsed_args.max:
@@ -251,7 +251,7 @@ def take_action(self, parsed_args):
251251
if parsed_args.user_data:
252252
try:
253253
userdata = open(parsed_args.user_data)
254-
except IOError, e:
254+
except IOError as e:
255255
raise exceptions.CommandError("Can't open '%s': %s" %
256256
(parsed_args.user_data, e))
257257

0 commit comments

Comments
 (0)