[ 
https://issues.apache.org/jira/browse/SVN-4525?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16327590#comment-16327590
 ] 

Tim Black commented on SVN-4525:
--------------------------------

FWIW, I'm experiencing same issue using svn 1.8.10 in Debian 8 and svn 1.9.5 in 
Debian 9. The patch file clearly includes a file addition, but when applied to 
a clean root working copy (which like the OP includes several externals), 
encounters  {code}svn: E155005: No write-lock in{code}
...

This is one of many workflow-related roadblocks that svn brings to the table. 
My team is in the process of moving to git as a result.

> patch fails for externals on add/delete
> ---------------------------------------
>
>                 Key: SVN-4525
>                 URL: https://issues.apache.org/jira/browse/SVN-4525
>             Project: Subversion
>          Issue Type: Bug
>          Components: cmdline client
>    Affects Versions: ---
>            Reporter: Subversion Importer
>            Priority: Major
>             Fix For: ---
>
>
> {noformat:nopanel=true}
> Discussed at http://svn.haxx.se/users/archive-2014-11/0009.shtml and confirmed
> as a bug by Stefan Sperling.
> I’m primarily a Tortoise user under Windows, but have recently needed to start
> using the command line client more frequently.  Our development environment
> heavily leverages externals and developers often distribute patches as a means
> for code review.  With the command line client I’ve discovered that "svn 
> patch"
> fails with an E155005: No write-lock error when applying a patch which adds or
> deletes files which span externals.  I’ve observed this with both 1.7.7 and
> 1.8.10.  I’ve had no problems when applying such patches with the Tortoise 
> patch
> mechanism.  A trivial example for clarity:
>  
> Assume the following wc structure:
>  
> test1/
>     fileA.txt
>     externals/
>         test2/
>             fileB.txt
>  
> [gmyers@pc test1]$ svn -v status
>                  2        2 gmyers       .
>                  2        2 gmyers       externals
> X                                        externals/test2
>                  2        1 gmyers       fileA.txt
>  
> Performing status on external item at 'externals/test2':
>                  1        1 gmyers      
> /home/gmyers/svnadmin_test/demo/test1/externals/test2
>                  1        1 gmyers      
> /home/gmyers/svnadmin_test/demo/test1/externals/test2/fileB.txt
>  
>  
> Now assume I have three patch files which perform the following operations: 1)
> Add a file file2.dat to externals/test2/,  2)Delete 
> externals/test2/fileB.txt, 
> 3) Modify externals/test2/fileB.txt.  The patches were all generated by
> performing the desired task and dumping the result from svn diff.
>  
> [gmyers@pc test1]$ cat add.patch
> Index: externals/test2/file2.dat
> ===================================================================
> --- externals/test2/file2.dat   (revision 0)
> +++ externals/test2/file2.dat   (working copy)
> @@ -0,0 +1 @@
> +This is file2.
>  
> [gmyers@pc test1]$ cat delete.patch
> Index: externals/test2/fileB.txt
> ===================================================================
> --- externals/test2/fileB.txt   (revision 1)
> +++ externals/test2/fileB.txt   (working copy)
> @@ -1 +0,0 @@
> -This is fileB.txt
>  
> [gmyers@pc test1]$ cat modify.patch
> Index: externals/test2/fileB.txt
> ===================================================================
> --- externals/test2/fileB.txt   (revision 1)
> +++ externals/test2/fileB.txt   (working copy)
> @@ -1 +1,3 @@
> This is fileB.txt
> +
> +Add some text.
>  
>  
> Now I’ll attempt to apply the patches.  The "add" patch returns E155005 and
> although it creates the new file2.dat file it fails to add it to svn:
>  
> [gmyers@pc test1]$ svn patch add.patch
> svn: E155005: No write-lock in
> '/home/gmyers/svnadmin_test/demo/test1/externals/test2'
>  
> The "delete" patch returns E155005 and does nothing:
>  
> [gmyers@pc test1]$ svn patch delete.patch
> svn: E155005: No write-lock in
> '/home/gmyers/svnadmin_test/demo/test1/externals/test2'
>  
> The "modify" patch succeeds as expected:
>  
> [gmyers@pc test1]$ svn patch modify.patch
> U         externals/test2/fileB.txt
> {noformat}
> Original issue reported by *gkm4d*



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to