From cb372f284d9daf86020caf4e728d4f07412a39ac Mon Sep 17 00:00:00 2001 From: Taloth Saldono Date: Fri, 8 Jun 2018 19:29:08 +0200 Subject: [PATCH] Log indexer response to Trace if an exception occurs. --- src/NzbDrone.Core/Indexers/HttpIndexerBase.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/NzbDrone.Core/Indexers/HttpIndexerBase.cs b/src/NzbDrone.Core/Indexers/HttpIndexerBase.cs index a822d7f08..d6545b8db 100644 --- a/src/NzbDrone.Core/Indexers/HttpIndexerBase.cs +++ b/src/NzbDrone.Core/Indexers/HttpIndexerBase.cs @@ -297,7 +297,15 @@ namespace NzbDrone.Core.Indexers { var response = FetchIndexerResponse(request); - return parser.ParseResponse(response).ToList(); + try + { + return parser.ParseResponse(response).ToList(); + } + catch (Exception) + { + _logger.Trace("Unexpected Response content ({0} bytes): {1}", response.HttpResponse.ResponseData.Length, response.HttpResponse.Content); + throw; + } } protected virtual IndexerResponse FetchIndexerResponse(IndexerRequest request)