# HG changeset patch # User Augie Fackler # Date 1261683008 21600 # Node ID 0e2564d4257d6c3810e257a7c13319ba7992ea4c # Parent 925ff8c5989cb5b89c9fee8a5e556f638baafd6c paths: autoescape paths from the user This means that users should no longer URI-encode their paths. This is a change from the past, and may require some small changes to .hg/hgrc. This fixes certain odd issues resulting from inconsistent handling of URI-encoding throughout hgsubversion. diff --git a/hgsubversion/svnwrap/svn_swig_wrapper.py b/hgsubversion/svnwrap/svn_swig_wrapper.py --- a/hgsubversion/svnwrap/svn_swig_wrapper.py +++ b/hgsubversion/svnwrap/svn_swig_wrapper.py @@ -194,7 +194,7 @@ class SubversionRepo(object): self.init_ra_and_client() self.uuid = ra.get_uuid(self.ra, self.pool) - repo_root = ra.get_repos_root(self.ra, self.pool) + repo_root = urllib.unquote(ra.get_repos_root(self.ra, self.pool)) # *will* have a leading '/', would not if we used get_repos_root2 self.subdir = url[len(repo_root):] if not self.subdir or self.subdir[-1] != '/': diff --git a/tests/test_util.py b/tests/test_util.py --- a/tests/test_util.py +++ b/tests/test_util.py @@ -89,7 +89,6 @@ def filtermanifest(manifest): def fileurl(path): path = os.path.abspath(path) drive, path = os.path.splitdrive(path) - path = urllib.pathname2url(path) if drive: drive = '/' + drive url = 'file://%s%s' % (drive, path)