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

New issue 3431 by 'rbt post' throws BadRequestError when wrong tracking branch is specified

What version are you running?
RBTools 0.6.1, RB 2.0.1

What steps will reproduce the problem?
1. git clone
2. cd reviewboard && checkout release-2.0.x
3. rbt post --tracking-branch origin/release-1.0.x

What is the expected output? What do you see instead?
A user-friendly error should be displayed, but instead the client shows
'AttributeError: 'BadRequestError' object has no attribute 'decode''
and the server throws a LookupError.

What operating system are you using? What browser?
Windows 8.1 (client), Ubuntu 12.04 (server)

Please provide any additional information below.

Client log:
Got API Error 105 (HTTP code 400): One or more fields had errors
Error data: {u'fields': {u'path': [u'unknown encoding: ']}, u'stat': u'fail', u'err': {u'msg': u'One or more fields had errors', u'code': 105}}
Traceback (most recent call last):
  File "c:\Python27\Scripts\", line 9, in <module>
    load_entry_point('RBTools==0.6.1', 'console_scripts', 'rbt')()
File "C:\Python27\lib\site-packages\rbtools-0.6.1-py2.7.egg\rbtools\commands\", line 134, in main
    command.run_from_argv([RB_MAIN, command_name] + args)
File "C:\Python27\lib\site-packages\rbtools-0.6.1-py2.7.egg\rbtools\commands\", line 416, in run_from_argv
    exit_code = self.main(*args) or 0
File "C:\Python27\lib\site-packages\rbtools-0.6.1-py2.7.egg\rbtools\commands\", line 784, in main
File "C:\Python27\lib\site-packages\rbtools-0.6.1-py2.7.egg\rbtools\commands\", line 543, in post_request
    error_msg.append(e.decode('utf-8') + u'\n')
AttributeError: 'BadRequestError' object has no attribute 'decode'

Server log:
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/ReviewBoard-2.0.1-py2.7.egg/reviewboard/webapi/resources/", line 292, in create
File "/usr/local/lib/python2.7/dist-packages/ReviewBoard-2.0.1-py2.7.egg/reviewboard/reviews/", line 116, in create
File "/usr/local/lib/python2.7/dist-packages/ReviewBoard-2.0.1-py2.7.egg/reviewboard/diffviewer/", line 69, in create
File "/usr/local/lib/python2.7/dist-packages/ReviewBoard-2.0.1-py2.7.egg/reviewboard/diffviewer/", line 156, in create_from_upload
File "/usr/local/lib/python2.7/dist-packages/ReviewBoard-2.0.1-py2.7.egg/reviewboard/diffviewer/", line 173, in create_from_data
    diff_file_contents, repository.get_encoding_list())
File "/usr/local/lib/python2.7/dist-packages/ReviewBoard-2.0.1-py2.7.egg/reviewboard/diffviewer/", line 50, in convert_to_unicode
    return e, six.text_type(s, e)
LookupError: unknown encoding:

You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:

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

Reply via email to