Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The legacy behavior of IO.delete is that it leaves behind any files in the tree that it is unable to delete. This is because File.delete only throws if an AccessDeniedException occurs. On windows, it is not unusual for deletions to fail because a jar or class file is in use somewhere. As a result, we leak temporary directories all over the place. These silent failures also impacts the DefaultBackgroundJobService which does not actually correctly clean up jar files when sbt exits. At any rate, much of sbt relies on the legacy behavior so I had to add logic to swallow exceptions. I didn't switch back to File.delete to make it clear that this method is broken semantically.
- Loading branch information