Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 2398 by post-review should determine the SCM Client based on repository type

* NOTE: Do not post confidential information in this bug report. *
*       If you need immediate support, please contact            *
*                             *

What version are you running?
RBTools 0.3.4

What's the URL of the page containing the problem?

What steps will reproduce the problem?
1. Do an "hg init" in the directory where post-review is done (or one a bove) 2. Run post-review supplying the revision-range where the code is actually in another SCM (e.g. clearcase)

What is the expected output? What do you see instead?
I'd expect the review to be posted. However it fails because of a syntax error trying to invoke "hg parents -r etc..".

The determine_client code seems to be doing things backwards... it's doing the following to pick the SCM client object to use..

    # Try to find the SCM Client we're going to be working with.
    for tool in SCMCLIENTS:
        repository_info = tool.get_repository_info()

..however when the admin defines a repository they have to specify the repository type. The user submitting a review has to specify the repostiry. So post-review should really be using the repository info to determine what client to use (seems simplest). In my case I have multiple SCM clients installed (clearcase, subversion, git and mercurial). So post-review is actually invoking all these tools to determine the repository_info, in my case it had a "false positive" for mercurial because at some point I had done an "hg init" in a directory above where my code was (code in clearcase). So "hg root" was not failing and determine_client() "picked" mercurial which was wrong.

You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To post to this group, send email to
To unsubscribe from this group, send email to
For more options, visit this group at

Reply via email to