4372: Missing "View Diff" on the review request action bar due to unicode handling bug

xepard
chipx86
chipx86

What version are you running?

Reviwboard 2.5.2
GitLab Community Edition 8.2.3

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

What steps will reproduce the problem?

What is the expected output? What do you see instead?

What operating system are you using? What browser?

Ubuntu 14.04 - Bitnami virtual image

Please provide any additional information below.

I select the commit in the repo, but no diff tab displayed.
If I upload manually instead, appears perfectly.

This is what the log is telling me:

2016-03-17 08:17:57,516 - ERROR - - Unable to update new review request from commit ID 4f14daa9cd22fc9af6853c710bb9552795132e92: 'ascii' codec can't decode byte 0xe1 in position 4872: ordinal not in range(128)
Traceback (most recent call last):
File "/opt/bitnami/apps/reviewboard/htdocs/reviewboard/reviews/managers.py", line 150, in create
review_request.update_from_commit_id(commit_id)
File "/opt/bitnami/apps/reviewboard/htdocs/reviewboard/reviews/models/base_review_request_details.py", line 220, in update_from_commit_id
self.update_from_committed_change(commit_id)
File "/opt/bitnami/apps/reviewboard/htdocs/reviewboard/reviews/models/base_review_request_details.py", line 264, in update_from_committed_change
commit = self.repository.get_change(commit_id)
File "/opt/bitnami/apps/reviewboard/htdocs/reviewboard/scmtools/models.py", line 450, in get_change
return hosting_service.get_change(self, revision)
File "/opt/bitnami/apps/reviewboard/htdocs/reviewboard/hostingsvcs/gitlab.py", line 326, in get_change
diff = diff.rsplit('--\nlibgit', 2)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe1 in position 4872: ordinal not in range(128)

What can I do? I don't see the problem.
And it is a curious behavior, because in the beginning was working.
The installation of ReviewBoard has around 2 months and in the beginning was working fine.

Thanks

brennie
#1 brennie

Thanks for reporting this!

It looks like the diff has some non-ASCII characters but the GitLab code doesn't appear to be set up for it.

chipx86
#2 chipx86
  • -New
    +Confirmed
  • +Release-2.0.x
    +Release-2.5.x
  • +Component:HostingServices
  • +chipx86
chipx86
#3 chipx86

Change up for review at https://reviews.reviewboard.org/r/8194/

  • +PendingReview
chipx86
#4 chipx86

Fixed in e38497672cb0e3c9c4ced97588d51ef3aaff1694, and scheduled for Review Board 2.0.x+.

  • -Confirmed
    +Fixed