diff --git a/src/main/java/com/sheepit/client/network/DownloadManager.java b/src/main/java/com/sheepit/client/network/DownloadManager.java index 807eed6..339ee8e 100644 --- a/src/main/java/com/sheepit/client/network/DownloadManager.java +++ b/src/main/java/com/sheepit/client/network/DownloadManager.java @@ -28,6 +28,8 @@ import java.io.File; import java.io.IOException; import java.io.PrintWriter; import java.io.StringWriter; +import java.nio.file.Files; +import java.nio.file.Path; import java.util.Random; import java.util.concurrent.TimeUnit; @@ -184,6 +186,13 @@ public class DownloadManager { e.printStackTrace(new PrintWriter(sw)); this.log.error("DownloadManager::createLock Unable to create .partial temp file for binary/scene " + this.local_target); this.log.error("DownloadManager::createLock Exception " + e + " stacktrace " + sw.toString()); + + String current_path = this.local_target; + String test_path; + while ((test_path = (new File(current_path).getParent())) != null) { + this.log.error("DownloadManager::createLock checking path info " + test_path + " exists? " + (new File(test_path).exists() ? "yes" : "no") + " is writeable? " + (Files.isWritable(Path.of(test_path)) ? "yes" : "no")); + current_path = test_path; + } } }