1339: post-review errors with [Errno 2] No such file or directory

hoffb******@gmai***** (Google Code) (Is this you? Claim this profile.)
chipx86
chipx86
Oct. 5, 2009
What version are you running?
1.1 alpha 1


What's the URL of the page containing the problem?
http://<server>/reviews/api/json/reviewrequests/1/diff/new/

What steps will reproduce the problem?
1. post-review

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

$ post-review --server=http://<server>/reviews/ --debug 967784
>>> svn info
>>> git rev-parse --git-dir
>>> p4 info
>>> repository info: Path: <repos>:1666, Base path: None, Supports
changesets: True
>>> Generating diff for changenum 967784
>>> p4 describe -s 967784

[...diff snipped, --output-diff works fine...]

>>> Looking for '<server> /reviews/' cookie in
/u/hordijk/.post-review-cookies.txt
>>> Loaded valid cookie -- no login required
>>> Attempting to create review request for 967784
>>> HTTP POSTing to http://<server>/reviews/api/json/reviewrequests/new/:
{'repository_path': '<repos>:1666', 'changenum': '967784'}
>>> Review request already exists. Updating it...
>>> HTTP POSTing to
http://<server>/reviews/api/json/reviewrequests/1/update_from_changenum/: {}
>>> Review request created
>>> Uploading diff, size: 1101
>>> HTTP POSTing to
http://<server>/reviews/api/json/reviewrequests/1/diff/new/: {}
Error uploading diff: One or more fields had errors (105)
>>> {u'fields': {u'path': [u'[Errno 2] No such file or directory']},
u'stat': u'fail', u'err': {u'msg': u'One or more fields had errors',
u'code': 105}}
Your review request still exists, but the diff is not attached.


What operating system are you using? What browser?
Linux

Please provide any additional information below.
This is (obviously) a clean installation of reviewboard.  Tried 1.0.3
first, had this issue.  Upgraded to 1.1 alpha 1, some issue.  Configured
reviewboard in the past with no issues, but I'm not sure how to get more
information out of post-review to debug this.
chipx86
#1 chipx86
Is p4 in the web server's path?

This error definitely seems unclear, but I'm working on a change that will make it
very clear what's going on when a dependency like p4 is missing.
  • +NeedInfo
  • -Type-Defect
    +Type-Support
  • +chipx86
#2 hoffb******@gmai***** (Google Code) (Is this you? Claim this profile.)
Well, that was it.  Making the error message a bit less generic would be a good idea. :)

Also, there doesn't appear to be a way to provide a location for the p4 binary, it
has to be in the path.  I would've expected to be able to set the location under the
Tool configuration.

Thanks.
chipx86
#3 chipx86
Fixed on master in rfccd8bd.

Newly created repositories will verify dependencies, p4 included, and won't allow the
repository to be created until they're installed.
  • -NeedInfo
    +Fixed
  • -Type-Support
    +Type-Defect
    +Component-SCMTools
    +Milestone-Release1.1