Hi Team, 

I tried to do post review by rbt post command. 
installed latest version of rb tools and tried to execute following command 
but wasn't able to successfully post the review.

rbt post --summary=test --description=test 24 
--repository-url=file:///D:\Repositories\Phone --repository=ATA_PHONE 
--repositorytype=svn --debug --publish --server=http://10.112.91.109 
--username=admin --password=default --target-people=admin --disable-proxy

Debug output : 

ERROR: The current directory does not contain a checkout from a supported 
source
 code repository.

While I tried this command error was different  : 

rbt post --repository-url file:///D:\Repositories\Phone --
repository=ATA_PHONE --repository-type=svn --debug --publish 
--server=http://10.11
2.91.109 --username=admin --password=default --summary='example tesint' 
--descri
ption='ha ha ' --target-people=admin --disable-proxy  
--summary='adsadsadsada' -


Error: >>> RBTools 0.7.9 alpha 0 (dev)
>>> Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:42:59) [MSC v.1500 
32 b
it (Intel)]
>>> Running on Windows-7-6.1.7601-SP1
>>> Home = C:\Users\Administrator\AppData\Roaming
>>> Current directory = d:\Repositories\Phone
>>> Command line: rbt post --repository-url file:///D:\Repositories\Phone 
--repo
sitory=ATA_SVN --repository-type=svn --debug --publish 
--server=http://10.112.91
.109 --username=admin --password=default --summary='example tesint' 
--descriptio
n='ha ha ' --target-people=admin --disable-proxy --summary='adsadsadsada' 
--revi
sion=22
>>> Checking for a Subversion repository...
>>> Running: svn --non-interactive info file:///D:\Repositories\Phone
>>> Running: diff --version
>>> Running: svn --non-interactive --version -q
>>> repository info: Path: file:///D:%5CRepositories%5CPhone, Base path: /, 
Supp
orts changesets: False
>>> Making HTTP GET request to http://10.112.91.109/api/
>>> Making HTTP GET request to 
http://10.112.91.109/api/repositories/?tool=Subve
rsion
>>> Cached response for HTTP GET 
http://10.112.91.109/api/repositories/?tool=Sub
version expired and was modified
>>> Making HTTP GET request to http://10.112.91.109/api/repositories/1/info/
>>> Cached response for HTTP GET 
http://10.112.91.109/api/repositories/1/info/ e
xpired and was modified
>>> Making HTTP GET request to http://10.112.91.109/api/repositories/2/info/
>>> Added cache entry for HTTP GET request to 
http://10.112.91.109/api/repositor
ies/2/info/
>>> repository info: Path: https://10.112.123.143/svn/Phone, Base path: /, 
Suppo
rts changesets: False
Traceback (most recent call last):
  File "C:\Program Files 
(x86)\RBTools\bin\..\Python27\Scripts\rbt-script.py", l
ine 11, in <module>
    load_entry_point('RBTools==0.7.9a0', 'console_scripts', 'rbt')()
  File "C:\Program Files 
(x86)\RBTools\Python27\lib\site-packages\rbtools-0.7.9a
0-py2.7.egg\rbtools\commands\main.py", line 133, in main
    command.run_from_argv([RB_MAIN, command_name] + args)
  File "C:\Program Files 
(x86)\RBTools\Python27\lib\site-packages\rbtools-0.7.9a
0-py2.7.egg\rbtools\commands\__init__.py", line 664, in run_from_argv
    exit_code = self.main(*args) or 0
  File "C:\Program Files 
(x86)\RBTools\Python27\lib\site-packages\rbtools-0.7.9a
0-py2.7.egg\rbtools\commands\post.py", line 735, in main
    self.revisions = get_revisions(self.tool, self.cmd_args)
  File "C:\Program Files 
(x86)\RBTools\Python27\lib\site-packages\rbtools-0.7.9a
0-py2.7.egg\rbtools\utils\review_request.py", line 66, in get_revisions
    revisions = tool.parse_revision_spec(cmd_args)
  File "C:\Program Files 
(x86)\RBTools\Python27\lib\site-packages\rbtools-0.7.9a
0-py2.7.egg\rbtools\clients\svn.py", line 194, in parse_revision_spec
    raise TooManyRevisionsError
rbtools.clients.errors.TooManyRevisionsError: Too many revisions specified


Now I have few questions post this: 

1. How to run rbt post command from outside the working directory?
2. Can we run from   svn server where we have SVN repository and hooks 
folder, because post/pre commit hooks will provide me repo and rvn or txn 
number ?
3. how to specify revision number in above cases?
4. if answer of 2 is Yes then where I did wrong ? 

Thanks,
Manish Trivedi



sday, March 30, 2017 at 8:03:33 PM UTC+5:30, TestAutomation MitelODC wrote:

> Thanks for the reply...now i am clear that why it was not working :) .
> i will see python API and will try to write my own hooks.
>
> It will be although nice if reviewboard team provide some readymade hooks 
> like this, because this is very much required functionality...
> I will update here itself i gets success.
>
> On Tuesday, March 28, 2017 at 8:31:30 PM UTC+5:30, TestAutomation MitelODC 
> wrote:
>>
>> Hi All. 
>>
>> I was trying to integrate SVN(on Windows) with ReviewBoard 2.5.9.(on 
>> Ubuntu)
>>
>> Intgration went fine and I was able to add SVN Repo through Admin portal 
>> of ReviewBoard.
>>
>> Next step was to add precommit hook on SVN, so that any commit on SVN 
>> should either be using existing review ID or create a new review.
>> I got precommit_hook.py and postreview.py python scripts to achieve this 
>> task(when I searched on google).
>>
>> but when I am executing these scripts I found that I am unable to do 
>> login to review board while providing correct Id and pwd.
>>
>> /api/json/accounts/login/ was the url that script was trying to hit and 
>> receiving "not reachable".
>>
>> When I tried with Postman(open free ware tool to test REST API) to hit 
>> http://<MyReviewBoardIP>/api/json/accounts/login with HTTP_POST then also I 
>> got error saying Object does not exist code 100 .
>>
>> Where is the issue ? 
>> did I miss any install steps for WEB API ? 
>> are these APIs old ? 
>>
>> Can I get latest verison of precommit_hook.py and postreview.py scripts ? 
>>
>> attaching the ones that I am using.
>>
>> Thanks,
>> Manish Trivedi 
>>  
>>
>

-- 
Supercharge your Review Board with Power Pack: 
https://www.reviewboard.org/powerpack/
Want us to host Review Board for you? Check out RBCommons: 
https://rbcommons.com/
Happy user? Let us know! https://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 reviewboard+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to