Solution to "svn: E235000: In file 'subversion/libsvn_wc/update_editor.c' line 1583: assertion failed"
Minimum operation to reproduce the bug
$ svn mkdir $REPO/svnbug -mprapare
Committed revision 27.
$ svn co $REPO/svnbug
Checked out revision 27.
$ cd svnbug/
$ echo 1 2 3 > file1 && touch file2
$ svn add file*
A file1
A file2
$ svn ci -m"add files"
Adding file1
Adding file2
Transmitting file data ..
Committed revision 28.
$ echo 2 3 4 > file1
$ svn ci -m"modify file1"
Sending file1
Transmitting file data .
Committed revision 29.
$ svn del file1
D file1
$ svn ci -m"delete file1"
Deleting file1
Committed revision 30.
$ ln -s file2 file1
$ svn add file1
A file1
$ svn ci -m"add a symlink"
Adding file1
Transmitting file data .
Committed revision 31.
$ svn up
$ svn sw $REPO/svnbug -r 29
svn: E235000: In file 'subversion/libsvn_wc/update_editor.c' line 1583:
assertion failed (action == svn_wc_conflict_action_edit || action == svn_wc_conflict_action_delete
|| action == svn_wc_conflict_action_replace)
Now you CANNOT swtich from -r 31 to -r 29, vice verusa.But don't worry, you have 2 solutions.
Solution 1: svn switch one by one
Odd thing is , you can avoid this error by swtiching step by step ;) !Like this:
$ svn cleanup
$ svn sw $REPO/svnbug -r 31
$ svn sw $REPO/svnbug -r 30
$ svn sw $REPO/svnbug -r 29
And also you can switch from -r29 to -r30, and from -r30 to -r31.But you can NEVER switch from -r 29 to -r 31
Solution 2: svn up -r
"svn up" command always makes success.$ svn cleanup
$ svn up -r 31
$ svn up -r 29
$ svn up -r 31
You did it!
A dirty patch
You can avoid error by this patch.(not perfect ,but usable)
$ diff -u update_editor.orig update_editor.c
--- update_editor.orig 2012-04-26 13:02:08.000000000 +0900
+++ update_editor.c 2012-05-30 02:27:24.000000000 +0900
@@ -1578,9 +1578,8 @@
/* When the node existed before (it was locally deleted, replaced or
* edited), then 'update' cannot add it "again". So it can only send
* _action_edit, _delete or _replace. */
- SVN_ERR_ASSERT(action == svn_wc_conflict_action_edit
- || action == svn_wc_conflict_action_delete
- || action == svn_wc_conflict_action_replace);
+ ;
+
else if (reason == svn_wc_conflict_reason_added)
/* When the node did not exist before (it was locally added), then 'update'
* cannot want to modify it in any way. It can only send _action_add. */
カテゴリ:
Subversion