diff --git a/src/NzbDrone.Core/Download/CompletedDownloadService.cs b/src/NzbDrone.Core/Download/CompletedDownloadService.cs index aa9d67278..f78bb95cb 100644 --- a/src/NzbDrone.Core/Download/CompletedDownloadService.cs +++ b/src/NzbDrone.Core/Download/CompletedDownloadService.cs @@ -171,23 +171,29 @@ namespace NzbDrone.Core.Download if (allEpisodesImportedInHistory) { + // Log different error messages depending on the circumstances, but treat both as fully imported, because that's the reality. + // The second message shouldn't be logged in most cases, but continued reporting would indicate an ongoing issue. + if (atLeastOneEpisodeImported) { _logger.Debug("All episodes were imported in history for {0}", trackedDownload.DownloadItem.Title); - trackedDownload.State = TrackedDownloadState.Imported; - _eventAggregator.PublishEvent(new DownloadCompletedEvent(trackedDownload, trackedDownload.RemoteEpisode.Series.Id)); - - return true; + } + else + { + _logger.Debug() + .Message("No Episodes were just imported, but all episodes were previously imported, possible issue with download history.") + .Property("SeriesId", trackedDownload.RemoteEpisode.Series.Id) + .Property("DownloadId", trackedDownload.DownloadItem.DownloadId) + .Property("Title", trackedDownload.DownloadItem.Title) + .Property("Path", trackedDownload.DownloadItem.OutputPath.ToString()) + .WriteSentryWarn("DownloadHistoryIncomplete") + .Write(); } - _logger.Debug() - .Message("No Episodes were just imported, but all episodes were previously imported, possible issue with download history.") - .Property("SeriesId", trackedDownload.RemoteEpisode.Series.Id) - .Property("DownloadId", trackedDownload.DownloadItem.DownloadId) - .Property("Title", trackedDownload.DownloadItem.Title) - .Property("Path", trackedDownload.DownloadItem.OutputPath.ToString()) - .WriteSentryWarn("DownloadHistoryIncomplete") - .Write(); + trackedDownload.State = TrackedDownloadState.Imported; + _eventAggregator.PublishEvent(new DownloadCompletedEvent(trackedDownload, trackedDownload.RemoteEpisode.Series.Id)); + + return true; } _logger.Debug("Not all episodes have been imported for {0}", trackedDownload.DownloadItem.Title);