[issue859] hg convert crashes with svn repo

courtois mercurial-bugs at selenic.com
Fri Dec 7 04:29:21 CST 2007

New submission from courtois <courtois at nouvo.com>:

when converting a svn repository with a directory with a "%" character inside
it's name followed by 2 hex characters.

create a subversion repos with a directory named %aa 
convert it with hg:

$ hg convert file:///home/courtois/foobar/  
assuming destination foobar-hg
initializing destination foobar-hg repository
scanning source...
0 ok
** unknown exception encountered, details follow
** report bug details to http://www.selenic.com/mercurial/bts
** or mercurial at selenic.com
** Mercurial Distributed SCM (version 0.9.5)
Traceback (most recent call last):
  File "/usr/bin/hg", line 14, in ?
  File "/var/lib/python-support/python2.4/mercurial/dispatch.py", line 20, in run
  File "/var/lib/python-support/python2.4/mercurial/dispatch.py", line 29, in
    return _runcatch(u, args)
  File "/var/lib/python-support/python2.4/mercurial/dispatch.py", line 45, in
    return _dispatch(ui, args)
  File "/var/lib/python-support/python2.4/mercurial/dispatch.py", line 348, in
    ret = _runcommand(ui, options, cmd, d)
  File "/var/lib/python-support/python2.4/mercurial/dispatch.py", line 401, in
    return checkargs()
  File "/var/lib/python-support/python2.4/mercurial/dispatch.py", line 357, in
    return cmdfunc()
  File "/var/lib/python-support/python2.4/mercurial/dispatch.py", line 342, in
    d = lambda: func(ui, *args, **cmdoptions)
  File "/var/lib/python-support/python2.4/hgext/convert/__init__.py", line 380,
in convert
  File "/var/lib/python-support/python2.4/hgext/convert/__init__.py", line 270,
in convert
  File "/var/lib/python-support/python2.4/hgext/convert/__init__.py", line 214,
in copy
    changes = self.source.getchanges(rev)
  File "/var/lib/python-support/python2.4/hgext/convert/subversion.py", line
226, in getchanges
    files, copies = self.expandpaths(rev, paths, parents)
  File "/var/lib/python-support/python2.4/hgext/convert/subversion.py", line
490, in expandpaths
    children = self._find_children(path, revnum)
  File "/var/lib/python-support/python2.4/hgext/convert/subversion.py", line
666, in _find_children
    return ['%s/%s' % (path, x) for x in svn.client.ls(rpath, optrev(revnum),
True, self.ctx, pool).keys()]
  File "/var/lib/python-support/python2.4/libsvn/client.py", line 1043, in
    return apply(_client.svn_client_ls, args)
libsvn._core.SubversionException: ("URL 'file:///home/courtois/foobar/%aa'
non-existent in that revision", 160013)

messages: 4479
nosy: courtois
priority: bug
status: unread
title: hg convert crashes with svn repo

Mercurial issue tracker <mercurial-bugs at selenic.com>

More information about the Mercurial-devel mailing list