Here is a more accurate description:
In ReviewBoardServer.get_repository_info, it calls
ReviewBoardServer.api_get to fetch the repository info from sever,
from my debug, it show the return json is something like (if the
repository is svn)
from the data structure of the json, we can see that use "url =
rsp['links']['info']['href']" of course will get a array key
should use url = rsp['repository']['links']['info']['href'].
Is this a bug?
On Jan 11, 9:24 pm, Dan <birb...@gmail.com> wrote:
> Here I have a problem with postreview.py when publish a review
> request, could anyone please have a look?
> My enviroment is Reviewboard 1.5.1 and SVN. I downloaded postreview.py
> and configed the constants necessary.
> When I run postreivew, it throws a array index exception at line 677:
> url = rsp['links']['info']['href'], The whole piece of code is
> def get_repository_info(self, rid):
> Returns detailed information about a specific repository.
> if self.deprecated_api:
> url = 'api/json/repositories/%s/info/' % rid
> rsp = self.api_get(
> '%s%s/' % (self.root_resource['links']['repositories']
> url = rsp['links']['info']['href']
> rsp = self.api_get(url)
> return rsp['info']
> I added debug info for rep, it did not contain the "links" index
> indeed, but it contained a "repository" index.
> Then I manually went to check the xml from reviewboard server, and
> found the structure of the xml is like this
> so I changed line 677 to url = rsp["repository"]['links']['info']
> ['href'], finally it worked.
> Though it worked, I still did not know the reason and whether my
> change is right or wrong. I think it is unlike to be a bug of
> reviewboard, but I am too lazy to read all the code :-) so, could
> anyone kindly tell me that what the real problem is and what should I
> Any help will be highly appreciated!
Want to help the Review Board project? Donate today at
Happy user? Let us know at http://www.reviewboard.org/users/
To unsubscribe from this group, send email to
For more options, visit this group at