Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to solve "The node '...' was not found." in SVN

I've merged two branches (trunk and a development branch). A folder has dissapeared.

I'm working in command line and when trying to say svn resolve --accept working src/path/to/folder the terminal spits out The node 'src/path/to/folder' was not found

After that it also spits out:

svn: E200009: Could not add all targets because some targets don't exist

svn: E200009: Illegal target for the requested operation

How can I force SVN to accept this change?

Thanks!

like image 790
Alex Avatar asked Nov 20 '12 17:11

Alex


2 Answers

I was hitting this error trying to use TortoiseSVN to update a working copy. In my case I managed to workaround by using the SVN commandline interface instead to svn update. Even after a successful commit I was still unable to update.

Very odd but a manual delete and update seemed to clean everything up. Both of my clients were based on Subversion 1.7.6.

like image 76
jevon Avatar answered Sep 20 '22 07:09

jevon


It looks like some info is broken. Which seems to happen during merge with tree conflicts.

I had to fix the svn database which is the file .svn/wc.db.

WARNING! You are manipulating the svn database which can be harmful! Do this only if you have a backup and if this procedure does not help, restore the data from backup.

  1. Go to SQLite from SQLite Download Page, download the archive of the precompiled binary for your platform and extract it e.g. to /tools
  2. Change into the .svn directory make a backup of the wv.db (!) and run sqlite3 with wc.db as parameter. E.g.

    \tools\sqlite3.exe wc.db

  3. Search the entries causing the problem with

    select * from actual_node where conflict_data like '%missing%';

    or

    select * from actual_node where conflict_data like '%obstructed%';

    refine these queries until only the faulty actual nodes are listed. Also

    select * from actual_node where local_relpath like '%...%';

    is helpful to find the faulty nodes.

  4. Remove the faulty nodes by replacing the select with a delete

    delete from actual_node where conflict_data like '%missing%';

  5. Check again with your favorite svn tool.

  6. Rinse and repeat until all problems are gone.

WARNING! You are manipulating the svn database which can be harmful! Do this only if you have a backup and if this procedure does not help, restore the data from backup.

For me it worked several times.

like image 21
bebbo Avatar answered Sep 20 '22 07:09

bebbo