Report an error to the user if we can't access a file because it's locked by another process.
Stack trace:
11:36:23.212 [pool-3-thread-1] ERROR n.s.archivo.controller.ArchiveTask - Error removing D:\Users\Todd\Videos\Tivo Exports\Masterpiece Mystery! - S07E22 - Grantchester, Episode 3.cut.ts:
java.nio.file.FileSystemException: D:\Users\Todd\Videos\Tivo Exports\Masterpiece Mystery! - S07E22 - Grantchester, Episode 3.cut.ts: The process cannot access the file because it is being used by another process.
at sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:86) ~[na:1.8.0_71]
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:97) ~[na:1.8.0_71]
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:102) ~[na:1.8.0_71]
at sun.nio.fs.WindowsFileSystemProvider.implDelete(WindowsFileSystemProvider.java:269) ~[na:1.8.0_71]
at sun.nio.fs.AbstractFileSystemProvider.deleteIfExists(AbstractFileSystemProvider.java:108) ~[na:1.8.0_71]
at java.nio.file.Files.deleteIfExists(Files.java:1165) ~[na:1.8.0_71]
at net.straylightlabs.archivo.controller.ArchiveTask.lambda$cleanupFiles$10(ArchiveTask.java:653) ~[Archivo/:na]
at java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948) ~[na:1.8.0_71]
at java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:580) ~[na:1.8.0_71]
at net.straylightlabs.archivo.controller.ArchiveTask.cleanupFiles(ArchiveTask.java:651) ~[Archivo/:na]
at net.straylightlabs.archivo.controller.ArchiveTask.cleanupFiles(ArchiveTask.java:647) ~[Archivo/:na]
at net.straylightlabs.archivo.controller.ArchiveTask.cutCommercials(ArchiveTask.java:418) ~[Archivo/:na]
at net.straylightlabs.archivo.controller.ArchiveTask.archive(ArchiveTask.java:124) ~[Archivo/:na]
at net.straylightlabs.archivo.controller.ArchiveTask.call(ArchiveTask.java:94) ~[Archivo/:na]
at net.straylightlabs.archivo.controller.ArchiveTask.call(ArchiveTask.java:61) ~[Archivo/:na]
at javafx.concurrent.Task$TaskCallable.call(Task.java:1423) ~[jfxrt.jar:na]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[na:1.8.0_71]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[na:1.8.0_71]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[na:1.8.0_71]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) ~[na:1.8.0_71]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) ~[na:1.8.0_71]
at java.lang.Thread.run(Thread.java:745) ~[na:1.8.0_71]
Report an error to the user if we can't access a file because it's locked by another process.
Stack trace:
11:36:23.212 [pool-3-thread-1] ERROR n.s.archivo.controller.ArchiveTask - Error removing D:\Users\Todd\Videos\Tivo Exports\Masterpiece Mystery! - S07E22 - Grantchester, Episode 3.cut.ts: java.nio.file.FileSystemException: D:\Users\Todd\Videos\Tivo Exports\Masterpiece Mystery! - S07E22 - Grantchester, Episode 3.cut.ts: The process cannot access the file because it is being used by another process.