mirror of
https://github.com/Sonarr/Sonarr.git
synced 2026-04-25 22:46:31 -04:00
Fixed: Inaccessible path leading to import process being aborted before processing all items
Fixes #3598
This commit is contained in:
@@ -75,6 +75,8 @@ namespace NzbDrone.Core.MediaFiles
|
||||
|
||||
public List<ImportResult> ProcessPath(string path, ImportMode importMode = ImportMode.Auto, Series series = null, DownloadClientItem downloadClientItem = null)
|
||||
{
|
||||
_logger.Debug("Processing path: {0}", path);
|
||||
|
||||
if (_diskProvider.FolderExists(path))
|
||||
{
|
||||
var directoryInfo = new DirectoryInfo(path);
|
||||
@@ -279,6 +281,12 @@ namespace NzbDrone.Core.MediaFiles
|
||||
var mounts = _diskProvider.GetMounts();
|
||||
var mount = mounts.FirstOrDefault(m => m.RootDirectory == Path.GetPathRoot(path));
|
||||
|
||||
if (mount == null)
|
||||
{
|
||||
_logger.Error("Import failed, path does not exist or is not accessible by Sonarr: {0}. Unable to find a volume mounted for the path. If you're using a mapped network drive see the FAQ for more info", path);
|
||||
return;
|
||||
}
|
||||
|
||||
if (mount.DriveType == DriveType.Network)
|
||||
{
|
||||
_logger.Error("Import failed, path does not exist or is not accessible by Sonarr: {0}. It's recommended to avoid mapped network drives when running as a Windows service. See the FAQ for more info", path);
|
||||
|
||||
Reference in New Issue
Block a user