title: Jenkins SVN plugin failed when removing files (Checksum mismatch)
body: <p>We encounter a strange error with Jenkin today. After investigating, we find that it's due to the fact that we delete some files in SVN, which cause a problem in Jenkin SVN plugin.</p>
  
  <p>As I investigate, it seems this bug was known but it hasn't been fixed yet. So that upgrading to a newer SVN plugin version is not a solution(we are using Jenkin 1.474).</p>
  
  <p>Our temporary fix is that "always checkout before building". But this is clearly very slow and takes much time for big projects. So that I'm looking for a way to (at least) detect the SVN problem in post-build scripts when it happens, and probably send an email to notify the developers.</p>
  
  <p>Does anyone have any experience with this? I'm not too familiar with Jenkin, hence any help or pointer would be greatly appreciated.</p>
  
  <p>Here's the error log:</p>
  
  <pre><code>Building in workspace /workspace-directory/workspace
  Cleaning up /var/lib/jenkins/jobs/aaa/workspace/.
  Deleting /var/lib/jenkins/jobs/aaa/workspace/logs
  Deleting /var/lib/jenkins/jobs/aaa/workspace/target
  Updating svn://address/trunk@HEAD
  U         src/main/some_file.java
  D         src/main/another_file.java
  U         src/main/other_files.java
  ERROR: Failed to update svn://address/trunk@HEAD
  org.tmatesoft.svn.core.SVNException: svn: E155017: Checksum mismatch while updating '/var/lib/jenkins/jobs/aaa/workspace/src/main/address/.svn/text-base/StudioSignUpController.java.svn-base'; expected: '39fc987bbeb8cd332e6b94abfb934720', actual: 'e9fa300ee28a2b1e15b2273f4b14ae18'
      at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:85)
      at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:69)
      at org.tmatesoft.svn.core.internal.io.svn.SVNEditModeReader.driveEditor(SVNEditModeReader.java:250)
      at org.tmatesoft.svn.core.internal.io.svn.SVNRepositoryImpl.update(SVNRepositoryImpl.java:1503)
      at org.tmatesoft.svn.core.internal.wc16.SVNUpdateClient16.update(SVNUpdateClient16.java:557)
      at org.tmatesoft.svn.core.internal.wc16.SVNUpdateClient16.doUpdate(SVNUpdateClient16.java:414)
      at org.tmatesoft.svn.core.internal.wc16.SVNUpdateClient16.doUpdate(SVNUpdateClient16.java:324)
      at org.tmatesoft.svn.core.internal.wc2.old.SvnOldUpdate.run(SvnOldUpdate.java:27)
      at org.tmatesoft.svn.core.internal.wc2.old.SvnOldUpdate.run(SvnOldUpdate.java:11)
      at org.tmatesoft.svn.core.internal.wc2.SvnOperationRunner.run(SvnOperationRunner.java:20)
      at org.tmatesoft.svn.core.wc2.SvnOperationFactory.run(SvnOperationFactory.java:1221)
      at org.tmatesoft.svn.core.wc2.SvnOperation.run(SvnOperation.java:292)
      at org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:315)
      at org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:295)
      at org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:391)
      at hudson.scm.subversion.UpdateUpdater$TaskImpl.perform(UpdateUpdater.java:136)
      at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:144)
      at hudson.scm.SubversionSCM$CheckOutTask.perform(SubversionSCM.java:789)
      at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:770)
      at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:753)
      at hudson.FilePath.act(FilePath.java:842)
      at hudson.FilePath.act(FilePath.java:824)
      at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:743)
      at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:685)
      at hudson.model.AbstractProject.checkout(AbstractProject.java:1245)
      at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:589)
      at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88)
      at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:494)
      at hudson.model.Run.execute(Run.java:1488)
      at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:477)
      at hudson.model.ResourceController.execute(ResourceController.java:88)
      at hudson.model.Executor.run(Executor.java:236)
  Caused by: org.tmatesoft.svn.core.SVNException: svn: E155017: Checksum mismatch while updating '/xxxxx/.svn/text-base/SignUpController.java.svn-base'; expected: '39fc987bbeb8cd332e6b94abfb934720', actual: 'e9fa300ee28a2b1e15b2273f4b14ae18'
      at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:64)
      at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:51)
      at org.tmatesoft.svn.core.internal.wc.SVNUpdateEditor15.textDeltaEnd(SVNUpdateEditor15.java:637)
      at org.tmatesoft.svn.core.internal.wc.SVNAmbientDepthFilterEditor.textDeltaEnd(SVNAmbientDepthFilterEditor.java:221)
      at org.tmatesoft.svn.core.internal.wc.SVNCancellableEditor.textDeltaEnd(SVNCancellableEditor.java:130)
      at org.tmatesoft.svn.core.internal.io.svn.SVNEditModeReader.processCommand(SVNEditModeReader.java:176)
      at org.tmatesoft.svn.core.internal.io.svn.SVNEditModeReader.driveEditor(SVNEditModeReader.java:232)
      ... 29 more
  Caused by: svn: E155017: Checksum mismatch while updating '/xxxx/.svn/text-base/SignUpController.java.svn-base'; expected: '39fc987bbeb8cd332e6b94abfb934720', actual: 'e9fa300ee28a2b1e15b2273f4b14ae18'
      at org.tmatesoft.svn.core.SVNErrorMessage.create(SVNErrorMessage.java:208)
      at org.tmatesoft.svn.core.SVNErrorMessage.create(SVNErrorMessage.java:189)
      at org.tmatesoft.svn.core.SVNErrorMessage.create(SVNErrorMessage.java:141)
      at org.tmatesoft.svn.core.internal.wc.SVNUpdateEditor15.textDeltaEnd(SVNUpdateEditor15.java:634)
      ... 33 more
  no change for svn://some_address/trunk since the previous build
  No emails were triggered.
  </code></pre>