37

SVN directories are conveniently easy to move between computers, but this can occasion version mismatches between the working copy and installed svn client resulting in the error

svn: This client is too old to work with working copy '.';  
  please get a newer Subversion client

In a perfect world one could install a newer version of the SVN client, but when this is not possible or convenient it would be nice to be able to downgrade the working copy to the version of the client installed--especially when you know that none of the features of the later version are being used.

Checking out a new working copy with the old client only works if the problematic working copy doesn't have any changes, and isn't too big to make that inconvenient.

The scenario to imagine would be something like: Joe sends you a large working copy with lots of nested directories (and associated versioned .svn folders). You work on it. When you try to commit it, svn tells you that your client is too old. Sending it back to Joe shouldn't be necessary. Checking out a new working copy shouldn't be necessary and merging the changes in would be inconvenient in any case.

Is there some way to do this?

blahdiblah
  • 30,909
  • 18
  • 92
  • 149

2 Answers2

36

Short answer: it's not trivial.

Fortunately, the developers anticipated this problem and deal with it in an FAQ: http://subversion.apache.org/faq.html#working-copy-format-change
The upshot being to download and use their script for the purpose: http://svn.apache.org/repos/asf/subversion/trunk/tools/client-side/change-svn-wc-format.py

Note that that script only wants the major version number of the client, so if you have client version 1.4.4 the command would be:

python change-svn-wc-format.py <WC_PATH> 1.4 [...other options...]


Update:

The above script only works for downgrading version 1.6 and below. Downgrading from 1.7+ is apparently not possible. The note from the source:

# Downgrading from format 11 (1.7) to format 10 (1.6) is not possible,
# because 11 does not use has-props and cachable-props (but 10 does).
# Naively downgrading in that situation causes properties to disappear
# from the wc.
#
# Downgrading from the 1.7 SQLite-based format to format 10 is not
# implemented.
blahdiblah
  • 30,909
  • 18
  • 92
  • 149
6

I just deleted the .svn folder in the project file that 1.7 created and re-added the solution using 1.6. This worked for me hope it helps somebody else.

justin
  • 61
  • 1
  • 1