31: ValueError at /r/13/diff/upload/ when uploading diff

fox***@gmai***** (Google Code) (Is this you? Claim this profile.)
May 23, 2007
What's the URL of the page containing the problem?

http://reviewboard/r/13/diff/upload/

What steps will reproduce the problem?
1. Create a review
2. Upload a diff (ask Ben G. for the path)

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

I got the following traceback:

Traceback (most recent call last):
File "/usr/lib/python2.5/site-packages/django/core/handlers/base.py" in get_response
  77. response = callback(request, *callback_args, **callback_kwargs)
File "/root/reviewboard/../reviewboard/diffviewer/views.py" in upload
  248. diffset = form.create(request.FILES['path'], diffset_history)
File "/root/reviewboard/../reviewboard/diffviewer/forms.py" in create
  17. files = diffparser.parse(file["content"])
File "/root/reviewboard/../reviewboard/diffviewer/parser.py" in parse
  61. files.append(parseFile(lines, int(begin) - 1, int(end) - 1, file))
File "/root/reviewboard/../reviewboard/diffviewer/parser.py" in parseFile
  21. file.origFile, file.origInfo = lines[linenum].split(None, 2)[1:]

  ValueError at /r/13/diff/upload/
  need more than 1 value to unpack

What operating system are you using? What browser?

Mac OS X, Safari

Please provide any additional information below.
chipx86
#1 chipx86
Turns out your diff file didn't have any revision info associated with the file you
were patching. The diff has to be generated with post-review or p5 diff. We should,
however, have a better error message.
david
#2 david
Now catches the exception and plugs it into the error reporting we already had in
this view.
  • +Fixed