X Tutup
Skip to content

Commit f2f5620

Browse files
committed
Python 3 compatibility. Fixed wppm script raise syntax errors.
1 parent 9b0eb64 commit f2f5620

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

scripts/wppm

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@ parser.add_argument('-u', '--uninstall', dest='uninstall',
2121
args = parser.parse_args()
2222

2323
if args.install and args.uninstall:
24-
raise RuntimeError, "Incompatible arguments: --install and --uninstall"
24+
raise RuntimeError("Incompatible arguments: --install and --uninstall")
2525

2626
if not args.install and not args.uninstall:
2727
args.install = True
2828

2929
if not osp.isfile(args.fname):
30-
raise IOError, "File not found: %s" % args.fname
30+
raise IOError("File not found: %s" % args.fname)
3131

3232
if utils.is_python_distribution(args.target):
3333
dist = wppm.Distribution(args.target)
@@ -39,9 +39,9 @@ if utils.is_python_distribution(args.target):
3939
else:
4040
dist.uninstall(package)
4141
else:
42-
raise RuntimeError, "Package is not compatible with Python "\
43-
"%s %dbit" % (dist.version, dist.architecture)
42+
raise RuntimeError("Package is not compatible with Python "\
43+
"%s %dbit" % (dist.version, dist.architecture))
4444
except NotImplementedError:
45-
raise RuntimeError, "Package is not (yet) supported by WPPM"
45+
raise RuntimeError("Package is not (yet) supported by WPPM")
4646
else:
47-
raise WindowsError, "Invalid Python distribution %s" % args.target
47+
raise WindowsError("Invalid Python distribution %s" % args.target)

0 commit comments

Comments
 (0)
X Tutup