Problems with <cleanCopy/>

Nov 14, 2008 at 10:19 PM
I have configured Cruise Control to build a large solution and have run into a problem when setting the "cleanCopy" parameter to true.
Intermittently (approximately every other build) the build fails with the following exception:

System.IO.IOException: The directory is not empty. at System.IO.Directory.DeleteHelper(String fullPath, String userPath, Boolean recursive) at System.IO.Directory.Delete(String fullPath, String userPath, Boolean recursive) at ThoughtWorks.CruiseControl.Core.Sourcecontrol.Vsts.deleteDirectory(String path) at ThoughtWorks.CruiseControl.Core.Sourcecontrol.Vsts.GetSource(IIntegrationResult result) at ThoughtWorks.CruiseControl.Core.IntegrationRunner.Build(IIntegrationResult result)

When I look in the directory where the CI solution is being run, I notice that there is a small reminant of the directory structure that still exists (no files).
I changed the "cleanCopy" parameter to false and the builds run without error.

This is ok for a temporary solution, but I want to ultimately get a clean copy when performing each CI build.

Any thoughts as to what I can do to resolve this issue?

I have included my ccnet.config file below:

<

project name="xxx">

 

<

modificationDelaySeconds>60</modificationDelaySeconds>

 

<

sourcecontrol type="vsts" autoGetSource="true">

 

<

server>http://xxx:8080</server>

 

<

project>$/xxx/Main</project>

 

<

workingDirectory>c:\projects\xxx\Main</workingDirectory>

 

<

cleanCopy>true</cleanCopy>

 

<

workspace>CCNET-xxx</workspace>

 

<

deleteWorkspace>true</deleteWorkspace>

 

</

sourcecontrol>

 

<

tasks>

 

<

nant>

 

<

executable>nant.exe</executable>

 

<

baseDirectory>c:\projects\xxx\Main\buildscripts</baseDirectory>

 

<

buildFile>default.build</buildFile>

 

<

targetList>

 

<

target>CIBuild</target>

 

</

targetList>

 

<

buildTimeoutSeconds>1200</buildTimeoutSeconds>

 

</

nant>

 

</

tasks>

 

<

publishers>

 

<

merge>

 

<

files>

 

<

file>c:\projects\xxx\Main\buildresults\*.xml</file>

 

</

files>

 

</

merge>

 

<

xmllogger />

 

<

email from="xxx" mailhost="xxx" includeDetails="TRUE">

 

<

users>
...

 

</

users>

 

<

groups>

 

<

group name="developers" notification="change"/>

 

<

group name="buildmaster" notification="always"/>

 

</

groups>

 

</

email>

 

</

publishers>

 

</

project>

 

Dec 5, 2008 at 4:08 PM
I too have started to see this issue semi regularly. Any updates or ideas?
Feb 10, 2009 at 8:17 AM
I have the same problem as well, any ideas how to fix/work around it?
Feb 18, 2010 at 10:00 AM

I'm using CC.Net 1.5 RC1 which uses this plugin (I think).  and I'm also having this problem.  Has anyone worked out which files\folders are being locked which would prevent the folder from being deleted?  The problem is intermittent, so it's difficult to track down...

Any fix\workaround would be appreciated.

Sep 16, 2010 at 10:30 PM

I have the same problem, 2 of 3 builds have this error. Any ideas for a solution?

Thanks!