Comment #13 on issue 547 by [email protected]: post-review doesn't link
up with authenticated Mercurial repositories properly
http://code.google.com/p/reviewboard/issues/detail?id=547
This issue is with ssh repositories. I'm seeing different issues with https
based repos.
I tried applying the patch but looks like the hg.py file is different from
the time of the patch. Here's the relevant code:
class HgClient(object):
def __init__(self, repoPath, local_site):
from mercurial import hg, ui
from mercurial.__version__ import version
version_parts = [int(x) for x in version.split(".")]
if version_parts[0] == 1 and version_parts[1] <= 2:
hg_ui = ui.ui(interactive=False)
else:
hg_ui = ui.ui()
hg_ui.setconfig('ui', 'interactive', 'off')
# Check whether ssh is configured for mercurial. Assume that any
# configured ssh is set up correctly for this repository.
hg_ssh = hg_ui.config('ui', 'ssh')
if not hg_ssh:
logging.debug('Using rbssh for mercurial')
hg_ui.setconfig('ui', 'ssh', 'rbssh --rb-local-site=%s'
% local_site)
else:
logging.debug('Found configured ssh for mercurial: %s' % hg_ssh)
self.repo = hg.repository(hg_ui, path=repoPath)
def cat_file(self, path, rev="tip"):
if rev == HEAD:
rev = "tip"
elif rev == PRE_CREATION:
rev = ""
try:
return self.repo.changectx(rev).filectx(path).data()
except Exception, e:
# LookupError moves from repo to revlog in hg v0.9.4, so we
# catch the more general Exception to avoid the dependency.
raise FileNotFoundError(path, rev, str(e))
--
You received this message because you are subscribed to the Google Groups
"reviewboard-issues" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/reviewboard-issues?hl=en.