]> arthur.barton.de Git - bup.git/blobdiff - lib/bup/helpers.py
path_components: adjust exception raise for py3
[bup.git] / 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)