Status: New
Owner: ----
Labels: Type-Defect Priority-Medium
New issue 3410 by [email protected]: perforce post-submit review fails
using rbt post when the submitted change set contains "branch" actions
http://code.google.com/p/reviewboard/issues/detail?id=3410
*** READ THIS BEFORE POSTING!
***
*** You must complete this form in its entirety, or your bug report will be
*** rejected.
***
*** If you have a security issue to report, please send it confidentially
to
*** [email protected]. Posting security-related issues to this bug
*** tracker causes us to have to do an emergency release.
***
*** For customer support, please post to [email protected]
***
*** If you have a patch, please submit it to
http://reviews.reviewboard.org/
***
*** This bug tracker is public. Please check that any logs or other
information
*** that you include has been stripped of confidential information.
What version are you running?
RBTools-0.6-py2.6.egg
What's the URL of the page containing the problem?
n/a
What steps will reproduce the problem?
1. using perforce, add a new file (p4 add myfile; p4 submit) (change #1)
2. branch the file, p4 integ myfile myfile2 (or whatever); p4 submit
(change #2)
3. rbt post 2
What is the expected output? What do you see instead?
Expected: A review is created and the diff submitted.
Observed: CRITICAL: Unsupported action type "branch" for myfile2
What operating system are you using? What browser?
submitting from RHEL Linux 5.5; browser - any.
Please provide any additional information below.
This appears to be due to the following in clients/perforce.py (around line
644, in method _compute_range_changes:
if action not in ('edit', 'integrate', 'add', 'delete',
'move/add', 'move/delete'):
raise Exception('Unsupported action type "%s" for %s' %
(action, depot_file))
if action == 'integrate':
action = 'edit'
elif action == 'branch':
action = 'add'
Locally we have resolved the issue (successfully submitting the review)
with the following naive change, replacing the above with:
if action == 'integrate':
action = 'edit'
elif action == 'branch':
action = 'add'
if action not in ('edit', 'add', 'delete',
'move/add', 'move/delete'):
raise Exception('Unsupported action type "%s" for %s' %
(action, depot_file))
complete output of example:
$ tools/temp>echo data > a_file_please_ignore
$ tools/temp>p4 add a_file_please_ignore
//depot/<snip>/a_file_please_ignore#1 - opened for add
$ tools/temp>p4 submit a_file_please_ignore
Change 1205953 created with 1 open file(s).
Submitting change 1205953.
Locking 1 files ...
Change 1205953 submitted.
$ tools/temp>p4 integ a_file_please_ignore a_file_please_ignore.2
//depot/<snip>/a_file_please_ignore.2#1 - branch/sync from
//depot/<snip>/a_file_please_ignore#1
$ tools/temp>p4 submit a_file_please_ignore.2
Change 1205956 created with 1 open file(s).
Submitting change 1205956.
Locking 1 files ...
branch //depot/<snip>/a_file_please_ignore.2#1
Change 1205956 submitted.
$ tools/temp>rbt post 1205956
ERROR: Could not load SCM Client "svn": No module named etree
ERROR: Could not load SCM Client "git": No module named etree
ERROR: Could not load SCM Client "mercurial": No module named uuid
Generating diff for range of submitted changes: 1205955 to 1205956
CRITICAL: Unsupported action type "branch" for
//depot/<snip>/a_file_please_ignore.2
with the naive fix:
$ tools/temp>rbt post 1205956
ERROR: Could not load SCM Client "svn": No module named etree
ERROR: Could not load SCM Client "git": No module named etree
ERROR: Could not load SCM Client "mercurial": No module named uuid
Generating diff for range of submitted changes: 1205955 to 1205956
Review request #1421 posted.
...
Draft diff
This diff is part of your current draft. Other users will not see this diff
until you publish your draft.
Files Changed:
//depot/<snip>/a_file_please_ignore.2: 1 change [ new content ]
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
--
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/reviewboard-issues.
For more options, visit https://groups.google.com/d/optout.