##// END OF EJS Templates
hg: convert an exception to bytes in the repo creation exception handler...
Matt Harbison -
r47518:1099541b stable
parent child Browse files
Show More
@@ -41,7 +41,6 b' from . import ('
41 mergestate as mergestatemod,
41 mergestate as mergestatemod,
42 narrowspec,
42 narrowspec,
43 phases,
43 phases,
44 pycompat,
45 requirements,
44 requirements,
46 scmutil,
45 scmutil,
47 sshpeer,
46 sshpeer,
@@ -53,7 +52,11 b' from . import ('
53 verify as verifymod,
52 verify as verifymod,
54 vfs as vfsmod,
53 vfs as vfsmod,
55 )
54 )
56 from .utils import hashutil
55 from .utils import (
56 hashutil,
57 stringutil,
58 )
59
57
60
58 release = lock.release
61 release = lock.release
59
62
@@ -74,7 +77,7 b' def _local(path):'
74 # Python 2 raises TypeError, Python 3 ValueError.
77 # Python 2 raises TypeError, Python 3 ValueError.
75 except (TypeError, ValueError) as e:
78 except (TypeError, ValueError) as e:
76 raise error.Abort(
79 raise error.Abort(
77 _(b'invalid path %s: %s') % (path, pycompat.bytestr(e))
80 _(b'invalid path %s: %s') % (path, stringutil.forcebytestr(e))
78 )
81 )
79 except OSError:
82 except OSError:
80 isfile = False
83 isfile = False
General Comments 0
You need to be logged in to leave comments. Login now