The problem here isn't with rbtools, but rather with the configuration of the repository in review board.
-David On Tue, Feb 4, 2014 at 1:04 PM, Karl Nordstrom <[email protected]>wrote: > I am attempting to post a review from perforce to ReviewBoard. RBTools > appears to be providing a GNU compatible diff now, which is great (thanks > for your help so far). The problem is with the upload. > > This is what I get > > C:\code\knordstrom_passenger\sw\transit\passenger\test>rbt post -d > DEBUG:root:Checking for a Subversion repository... > DEBUG:root:Checking for a Git repository... > DEBUG:root:Checking for a Mercurial repository... > DEBUG:root:Checking for a CVS repository... > DEBUG:root:Checking for a Perforce repository... > DEBUG:root:Running: p4 info > DEBUG:root:Running: diff --version > DEBUG:root:repository info: Path: stork.questercorp.local:1666, Base path: > None, Supports changesets: True > DEBUG:root:Making HTTP GET request to http://reviewboard/api/ > DEBUG:root:Making HTTP GET request to http://reviewboard/api/info/ > INFO:root:Generating diff for changenum default > DEBUG:root:Running: p4 opened -c default > DEBUG:root:Processing edit of > //depot/sw/transit/passenger/test/dsptools/filterdesign.py > DEBUG:root:Writing > "//depot/sw/transit/passenger/test/dsptools/filterdesign.py#1" to > "c:\users\knords~1\appdata\local\temp\tmpbuccxx" > DEBUG:root:Running: p4 print -o > c:\users\knords~1\appdata\local\temp\tmpbuccxx -q > //depot/sw/transit/passenger/test/dsptools/filterdesign.py#1 > DEBUG:root:Running: diff -urNp > c:\users\knords~1\appdata\local\temp\tmpbuccxx > C:\code\knordstrom_passenger\sw\transit\passenger\test\dsptools\filterdesign.py > DEBUG:root:Command exited with rc 1: ['diff', '-urNp', > 'c:\\users\\knords~1\\appdata\\local\\temp\\tmpbuccxx', > 'C:\\code\\knordstrom_passenger\\sw\\transit\\passenger\\test\\dsptools\\filterdesign.py'] > --- c:\users\knords~1\appdata\local\temp\tmpbuccxx 2014-02-04 12:47: > 15.189232400 -0800 > +++ > C:\code\knordstrom_passenger\sw\transit\passenger\test\dsptools\filterdesign.py > 2014-01-28 15:53:06.177664000 -0800 > @@ -2,6 +2,8 @@ import numpy as np > from scipy import signal > import matplotlib.pyplot as pl > > +#test > + > if 0: > # FIR decimation filter from 48000Hz to 200Hz > # retain 0-12.5 > --- > ... > ...similar output for other files here... > ... > --- > DEBUG:root:Processing edit of > //depot/sw/transit/passenger/test/stipa/rwav.py > DEBUG:root:Writing "//depot/sw/transit/passenger/test/stipa/rwav.py#2" to > "c:\users\knords~1\appdata\local\temp\tmpbuccxx" > DEBUG:root:Running: p4 print -o > c:\users\knords~1\appdata\local\temp\tmpbuccxx -q > //depot/sw/transit/passenger/test/stipa/rwav.py#2 > DEBUG:root:Running: diff -urNp > c:\users\knords~1\appdata\local\temp\tmpbuccxx > C:\code\knordstrom_passenger\sw\transit\passenger\test\stipa\rwav.py > DEBUG:root:Processing edit of > //depot/sw/transit/passenger/test/stipa/sines.py > DEBUG:root:Writing "//depot/sw/transit/passenger/test/stipa/sines.py#2" to > "c:\users\knords~1\appdata\local\temp\tmpbuccxx" > DEBUG:root:Running: p4 print -o > c:\users\knords~1\appdata\local\temp\tmpbuccxx -q > //depot/sw/transit/passenger/test/stipa/sines.py#2 > DEBUG:root:Running: diff -urNp > c:\users\knords~1\appdata\local\temp\tmpbuccxx > C:\code\knordstrom_passenger\sw\transit\passenger\test\stipa\sines.py > DEBUG:root:Making HTTP GET request to > http://reviewboard/api/review-requests/ > DEBUG:root:Making HTTP POST request to > http://reviewboard/api/review-requests/ > DEBUG:root:Making HTTP GET request to > http://reviewboard/api/review-requests/15/diffs/ > DEBUG:root:Making HTTP POST request to > http://reviewboard/api/review-requests/15/diffs/ > DEBUG:root:Got API Error 105 (HTTP code 400): One or more fields had errors > DEBUG:root:Error data: {u'fields': {u'path': [u'[P4#run] Errors during > command execution( "p4 files > //depot/sw/transit/passenger/test/dsptools/filterdesign.py#1" > )\n\n\t[Error]: "Access for user \'www-data\' has not been > enabled by \'p4 protect\'."\n\n']}, 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\rbt-script.py", line 9, in <module> > load_entry_point('RBTools==0.5.7', 'console_scripts', 'rbt')() > File > "C:\Python27\lib\site-packages\rbtools-0.5.7-py2.7.egg\rbtools\commands\main.py", > line 127, in main > command.run_from_argv([RB_MAIN] + args) > File > "C:\Python27\lib\site-packages\rbtools-0.5.7-py2.7.egg\rbtools\commands\__init__.py", > line 158, in run_from_argv > exit_code = self.main(*args) or 0 > File > "C:\Python27\lib\site-packages\rbtools-0.5.7-py2.7.egg\rbtools\commands\post.py", > line 659, in main > submit_as=self.options.submit_as) > File > "C:\Python27\lib\site-packages\rbtools-0.5.7-py2.7.egg\rbtools\commands\post.py", > line 534, in post_request > raise CommandError('\n'.join(error_msg)) > rbtools.commands.CommandError: Error uploading diff > > One or more fields had errors (HTTP 400, API Error 105) > > path: [P4#run] Errors during command execution( "p4 files > //depot/sw/transit/passenger/test/dsptools/filterdesign.py#1" ) > > [Error]: "Access for user 'www-data' has not been enabled by 'p4 > protect'." > > Your review request still exists, but the diff is not attached. > > > So, it appears that RBTools is calling p4 as user 'www-data'. > > The thing is, I can do the same p4 files on the commandline and get the > following output: > > C:\code\knordstrom_passenger\sw\transit\passenger\test>p4 files > //depot/sw/transit/passenger/test/dsptools/filterdesign.py#1 > //depot/sw/transit/passenger/test/dsptools/filterdesign.py#1 - add change > 21922 (text) > > So, p4 has been configured correctly. This is my p4config: > > P4PORT=stork:1666 > P4USER=knordstrom > P4CLIENT=knordstrom_passenger > > RBTools should find my P4USER etc and use that for credentials with p4, > but it doesn't. > > This is my .reviewboardrc > > REPOSITORY = "stork:1666" > REVIEWBOARD_URL = "http://reviewboard/" > > In .reviewboardrc, I have tried to specify my username. I tried: > > USERNAME (this appears to be for logging onto the reviewboard server) > P4_CLIENT (this appears to be for what in perforce is called a > workspace) > P4USER (not in current documentation, but found in help for > post-review) > P4_USER (a guess based on the above) > > None of these changed the error message about 'www-data' not enabled by 'p4 > protect'. > > I also looked in the .py code and didn't see any user or relevant p4 flags > that I haven't tried. > > Would you please show me how to specify the user or provide a bug fix? > > Thanks, > Karl > > -- > Get the Review Board Power Pack at http://www.reviewboard.org/powerpack/ > --- > Sign up for Review Board hosting at RBCommons: https://rbcommons.com/ > --- > Happy user? Let us know at http://www.reviewboard.org/users/ > --- > You received this message because you are subscribed to the Google Groups > "reviewboard" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > -- Get the Review Board Power Pack at http://www.reviewboard.org/powerpack/ --- Sign up for Review Board hosting at RBCommons: https://rbcommons.com/ --- Happy user? Let us know at http://www.reviewboard.org/users/ --- You received this message because you are subscribed to the Google Groups "reviewboard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
