]> arthur.barton.de Git - bup.git/commitdiff
path_components: adjust exception raise for py3
authorRob Browning <rlb@defaultvalue.org>
Sat, 20 Jan 2018 20:17:14 +0000 (14:17 -0600)
committerRob Browning <rlb@defaultvalue.org>
Sat, 20 Jan 2018 20:29:03 +0000 (14:29 -0600)
Signed-off-by: Rob Browning <rlb@defaultvalue.org>
Tested-by: Rob Browning <rlb@defaultvalue.org>
lib/bup/helpers.py

index e7df2321415b8321bb7c6bb9b712d2d0bc69ad3e..0f3df669322fddbf24e4fddc5643be6cce9438e9 100644 (file)
@@ -1060,7 +1060,7 @@ def path_components(path):
     Example:
       '/home/foo' -> [('', '/'), ('home', '/home'), ('foo', '/home/foo')]"""
     if not path.startswith('/'):
-        raise Exception, 'path must start with "/": %s' % path
+        raise Exception('path must start with "/": %s' % path)
     # Since we assume path startswith('/'), we can skip the first element.
     result = [('', '/')]
     norm_path = os.path.abspath(path)