Hi,

Python version: 2.5
RBtools version: 0.4.1
reviewboard version: 1.6.6

I have the following error when I upload a diff file generated by 
reviewboard:
 
The patch to '//mypath/Annotations.xml' didn't apply cleanly. The temporary 
files have been left in '/tmp/reviewboard.fe-Ge_' for debugging purposes. 
`patch` returned: patching file /tmp/reviewboard.fe-Ge_/tmpAKbuGL Hunk #1 
FAILED at 55. 1 out of 1 hunk FAILED -- saving rejects to file 
/tmp/reviewboard.fe-Ge_/tmpAKbuGL-new.rej missing header for unified diff 
at line 29 of patch can't find file to patch at input line 29 Perhaps you 
should have used the -p or --strip option? The text leading up to this was: 
-------------------------- | </Table> | | <Table 
TableName="JobModifiedEntity"> | |- <Bidirectional UpQuery="WHERE 1=0" 
DownQuery="WHERE 1=1" /> | |+ <Bidirectional UpQuery='WHERE 
ReplicationState == "Satellite"' DownQuery='WHERE ReplicationState != 
"Satellite"' /> | | </Table> | | <Table 
TableName="ActivatedKeyGroupPermission"> | | <Down /> | 
-------------------------- File to patch: Skip this patch? [y] Skipping 
patch. patch: **** malformed patch at line 36: 

Traceback (most recent call last):
  File 
"/usr/lib/python2.5/site-packages/ReviewBoard-1.6.6-py2.5.egg/reviewboard/diffviewer/views.py",
 line 151, in view_diff
    interdiffset, highlighting, True)
  File 
"/usr/lib/python2.5/site-packages/ReviewBoard-1.6.6-py2.5.egg/reviewboard/diffviewer/diffutils.py",
 line 1072, in get_diff_files
    large_data=True)
  File 
"/usr/lib/python2.5/site-packages/Djblets-0.6.16-py2.5.egg/djblets/util/misc.py",
 line 157, in cache_memoize
    data = lookup_callable()
  File 
"/usr/lib/python2.5/site-packages/ReviewBoard-1.6.6-py2.5.egg/reviewboard/diffviewer/diffutils.py",
 line 1071, in <lambda>
    enable_syntax_highlighting)),
  File 
"/usr/lib/python2.5/site-packages/ReviewBoard-1.6.6-py2.5.egg/reviewboard/diffviewer/diffutils.py",
 line 553, in get_chunks
    new = get_patched_file(old, filediff)
  File 
"/usr/lib/python2.5/site-packages/ReviewBoard-1.6.6-py2.5.egg/reviewboard/diffviewer/diffutils.py",
 line 375, in get_patched_file
    return patch(filediff.diff, buffer, filediff.dest_file)
  File 
"/usr/lib/python2.5/site-packages/ReviewBoard-1.6.6-py2.5.egg/reviewboard/diffviewer/diffutils.py",
 line 243, in patch
    (filename, tempdir, patch_output))
Exception: The patch to '//mypath/Annotations.xml' didn't apply cleanly. The 
temporary files have been left in '/tmp/reviewboard.fe-Ge_' for debugging 
purposes.
`patch` returned: patching file /tmp/reviewboard.fe-Ge_/tmpAKbuGL
Hunk #1 FAILED at 55.
1 out of 1 hunk FAILED -- saving rejects to file 
/tmp/reviewboard.fe-Ge_/tmpAKbuGL-new.rej
missing header for unified diff at line 29 of patch
can't find file to patch at input line 29
Perhaps you should have used the -p or --strip option?
The text leading up to this was:
--------------------------
| </Table>
|
| <Table TableName="JobModifiedEntity">
|
|-  <Bidirectional UpQuery="WHERE 1=0" DownQuery="WHERE 1=1" />
|
|+  <Bidirectional UpQuery='WHERE ReplicationState == "Satellite"' 
DownQuery='WHERE ReplicationState != "Satellite"' />
|
| </Table>
|
| <Table TableName="ActivatedKeyGroupPermission">
|
|   <Down />
|
--------------------------
File to patch: 
Skip this patch? [y] 
Skipping patch.
patch: **** malformed patch at line 36: 



 

the diff files contains /r/r/n at the end of every lines.

however, if I remove the /r manually, the diff files are processed 
correctly. 

I joined a working and a not working file example. 
Is there anything I can do against such issue?

Best regards,
Jean-Noël

-- 
Want to help the Review Board project? Donate today at 
http://www.reviewboard.org/donate/
Happy user? Let us know at http://www.reviewboard.org/users/
-~----------~----~----~----~------~----~------~--~---
To unsubscribe from this group, send email to 
reviewboard+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/reviewboard?hl=en
--- //mypath/Annotations.xml	//mypath/Annotations.xml#14
+++ //mypath/Annotations.xml	2012-05-09 12:13:05
@@ -55,10 +55,10 @@

   <Down />

 </Table>

 <Table TableName="Job">

-  <Bidirectional UpQuery="WHERE 1=0" DownQuery="WHERE 1=1" />

+  <Bidirectional UpQuery='WHERE ReplicationState == "Example"' DownQuery='WHERE ReplicationState != "Example"' />

 </Table>

 <Table TableName="JobModifiedEntity">

-  <Bidirectional UpQuery="WHERE 1=0" DownQuery="WHERE 1=1" />

+  <Bidirectional UpQuery='WHERE ReplicationState == "Example"' DownQuery='WHERE ReplicationState != "Example"' />

 </Table>

 <Table TableName="ActivatedKeyGroupPermission">

   <Down />
--- //mypath/Annotations.xml	//mypath/Annotations.xml#14
+++ //mypath/Annotations.xml	2012-05-09 14:06:12
@@ -55,10 +55,10 @@
   <Down />
 </Table>
 <Table TableName="Job">
-  <Bidirectional UpQuery="WHERE 1=0" DownQuery="WHERE 1=1" />
+  <Bidirectional UpQuery='WHERE ReplicationState == "Example"' DownQuery='WHERE ReplicationState != "Example"' />
 </Table>
 <Table TableName="JobModifiedEntity">
-  <Bidirectional UpQuery="WHERE 1=0" DownQuery="WHERE 1=1" />
+  <Bidirectional UpQuery='WHERE ReplicationState == "Example"' DownQuery='WHERE ReplicationState != "Example"' />
 </Table>
 <Table TableName="ActivatedKeyGroupPermission">
   <Down />

Reply via email to