<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Sword Systems &#187; syncinfo</title>
	<atom:link href="http://swordsystems.com/category/syncinfo/feed/" rel="self" type="application/rss+xml" />
	<link>http://swordsystems.com</link>
	<description>Cutting Commentary</description>
	<lastBuildDate>Tue, 10 Jan 2012 02:02:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Subversion (subclipse) corruption in Eclipse</title>
		<link>http://swordsystems.com/2009/06/03/subversion-subclipse-corruption-in-eclipse/</link>
		<comments>http://swordsystems.com/2009/06/03/subversion-subclipse-corruption-in-eclipse/#comments</comments>
		<pubDate>Wed, 03 Jun 2009 11:00:00 +0000</pubDate>
		<dc:creator>eric</dc:creator>
				<category><![CDATA[eclipse]]></category>
		<category><![CDATA[subclipse]]></category>
		<category><![CDATA[subversion]]></category>
		<category><![CDATA[SVN]]></category>
		<category><![CDATA[syncinfo]]></category>

		<guid isPermaLink="false">http://swordsystems.com/?p=9</guid>
		<description><![CDATA[I use subclipse to manage my subversion interactions in eclipse. I also use TortoiseSVN for pulling clean source code trees that are separate from my development workspace to produce releases. Normally, &#8220;never the two shall meet&#8221; is my policy. Eclipse/subclipse manage projects in my workspace directory and Tortoise handles everything else. I just found out [...]]]></description>
			<content:encoded><![CDATA[<p>I use <span class="blsp-spelling-error" id="SPELLING_ERROR_0">subclipse</span> to manage my subversion interactions in eclipse.  I also use <span class="blsp-spelling-error" id="SPELLING_ERROR_1">TortoiseSVN</span> for pulling clean source code trees that are separate from my development workspace to produce releases.  Normally, &#8220;never the two shall meet&#8221; is my policy. Eclipse/<span class="blsp-spelling-error" id="SPELLING_ERROR_2">subclipse</span> manage projects in my workspace directory and Tortoise handles everything else.  I just found out what happens if you let them cross paths.</p>
<p>I had a project in eclipse that seemed to have corrupted it&#8217;s <span class="blsp-spelling-error" id="SPELLING_ERROR_3">svn</span> meta-data.  The Synchronize view insisted that I had added some files when I hadn&#8217;t.  After restarting eclipse, the Synchronize view insisted that the whole source tree had changed.  Trying to narrow the problem, I quit eclipse, opened Windows Explorer, and told Tortoise to check for updates and local mods in the project.  Tortoise turned up a big nothing; it didn&#8217;t think there were any changes (which was correct).  So I went back into Eclipse to see if I could find a pattern to it&#8217;s madness.  (I know, I know &#8211; &#8220;This is eclipse, &#8221; you say, &#8220;to which madness are you referring?&#8221;).  Trying to synchronize the project again resulted in this helpful messages in the <span class="blsp-spelling-error" id="SPELLING_ERROR_4">SVN</span> console:</p>
<p><span style="font-size:85%;"><span style="font-family: courier new;">update C:/Dev/workspace/<span class="blsp-spelling-error" id="SPELLING_ERROR_5">myproject</span> -r HEAD &#8211;force <span class="blsp-spelling-error" id="SPELLING_ERROR_6">svn</span>: </span><br /><span style="font-family: courier new;">&#8216;C:\Dev\workspace\<span class="blsp-spelling-error" id="SPELLING_ERROR_7">myproject</span>&#8216; is not a working copy</span><br /><span style="font-family: courier new;"><span class="blsp-spelling-error" id="SPELLING_ERROR_8">svn</span>: Cannot read from &#8216;C:\Dev\workspace\<span class="blsp-spelling-error" id="SPELLING_ERROR_9">myproject</span>\.<span class="blsp-spelling-error" id="SPELLING_ERROR_10">svn</span>\format&#8217;: C:\Dev\workspace\<span class="blsp-spelling-error" id="SPELLING_ERROR_11">myproject</span>\.<span class="blsp-spelling-error" id="SPELLING_ERROR_12">svn</span>\format (The system cannot find the file specified)</span><br /></span> <br />For any who don&#8217;t know the inner workings of subversion (like me), under subversion 1.4 and below, the format file contains the version of the meta-data.  9 for version 1.4, 8 for 1.2 (I think), etc.  With subversion 1.6, that file is removed and the meta-data version is written in the top line of the entries file. </p>
<p><span style="font-weight: bold;">Lesson #1:</span> The subversion version used by eclipse may be different from the version used by your standalone subversion client.</p>
<p>I use Tortoise 1.6.2.  This uses subversion client 1.6 libraries.  My <span class="blsp-spelling-error" id="SPELLING_ERROR_13">subclipse</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_14">plugin</span> is from the 1.4.x branch.  As the <a href="http://tortoisesvn.tigris.org/faq.html">Tortoise FAQ</a> will tell you, subversion versions 1.4 and above will automatically upgrade the working copy format of your meta-data.  So the message was correct &#8211; the format file wasn&#8217;t there.  I just didn&#8217;t yet understand what had happened to cause that.  I thought I was still dealing with the same unknown error that I started with when, in fact, I had managed to create a whole other problem to deal with.</p>
<p>Somehow (and the steps get blurry here) I got Eclipse to give me a better error:</p>
<p><span style="font-size:85%;"><span style="font-family: courier new;">Problems reported while synchronizing <span class="blsp-spelling-error" id="SPELLING_ERROR_15">SVNStatusSubscriber</span>. 0 of 1 resources were synchronized.</span><span style="font-family: courier new;"> An error occurred synchronizing /<span class="blsp-spelling-error" id="SPELLING_ERROR_16">myproject</span>: Error getting status for resource P/<span class="blsp-spelling-error" id="SPELLING_ERROR_17">myproject</span> org.tigris.subversion.javahl.ClientException: Unsupported working copy format</span></p>
<p><span style="font-family: courier new;"><span class="blsp-spelling-error" id="SPELLING_ERROR_18">svn</span>: This client is too old to work with working copy &#8216;C:\Dev\workspace\<span class="blsp-spelling-error" id="SPELLING_ERROR_19">myproject</span>&#8216;.  You need</span><span style="font-family: courier new;"> to get a newer Subversion client, or to downgrade this working copy.</span><br /><span style="font-family: courier new;">See http://subversion.tigris.org/faq.html#working-copy-format-change</span><br /><span style="font-family: courier new;">for details.</span><br /></span><br />Ah-<span class="blsp-spelling-error" id="SPELLING_ERROR_20">hah</span>!  So I at least knew what had caused the latest behavior.  Upgrading my <span class="blsp-spelling-error" id="SPELLING_ERROR_21">subclipse</span> <span class="blsp-spelling-error" id="SPELLING_ERROR_22">plugin</span> to the 1.6.x branch got me back to my original problem.  Nice to be back in known territory.</p>
<p>I knew that the subversion meta-data that I could see (stuff in the .<span class="blsp-spelling-error" id="SPELLING_ERROR_23">svn</span> directories) was okay since Tortoise functioned.  So eclipse must keep some other meta-data about the synchronization state of a project.  Time to delve into the dark world of the workspace .<span class="blsp-spelling-error" id="SPELLING_ERROR_24">metadata</span> directory.  I searched through that directory for anything with the name of my project.  After eliminating a few hundred hits in .markers and .history files and whatnot, I found a likely sounding <span class="blsp-spelling-corrected" id="SPELLING_ERROR_25">culprit</span> &#8211; .<span class="blsp-spelling-error" id="SPELLING_ERROR_26">syncinfo</span>.  Sure enough, armed with that file name, I searched the web for references to my problem and turned up an archive of the <a href="http://www.nabble.com/svn-synchronisation-info-is-corrupted-for-subclipse---yet-not-really-tt17404088.html#a17404088"><span class="blsp-spelling-error" id="SPELLING_ERROR_27">subclipse</span>-users</a> mail list with exactly what I needed.</p>
<p><span style="font-weight: bold;">Lesson #2:</span> If the subversion integration in Eclipse ever goes haywire for a project, delete this file:<br /><span style="font-size:85%;"><span style="font-family: courier new;">[workspace dir]\.metadata\.plugins\org.eclipse.core.resources\.projects\[project name]\.<span class="blsp-spelling-error" id="SPELLING_ERROR_28">syncinfo</span></span><br /></span><br /> Problem solved.  Now I just have to get maven, eclipse, and groovy playing nicely with each other&#8230;<br /><span style="font-weight: bold;"></span></p>
]]></content:encoded>
			<wfw:commentRss>http://swordsystems.com/2009/06/03/subversion-subclipse-corruption-in-eclipse/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

