diff --git a/frontend/src/Settings/MediaManagement/RootFolder/EditRootFolderModalContent.js b/frontend/src/Settings/MediaManagement/RootFolder/EditRootFolderModalContent.js index 649642bfe..46993b7a8 100644 --- a/frontend/src/Settings/MediaManagement/RootFolder/EditRootFolderModalContent.js +++ b/frontend/src/Settings/MediaManagement/RootFolder/EditRootFolderModalContent.js @@ -103,14 +103,28 @@ function EditRootFolderModalContent(props) { - Use Calibre + + Use Calibre + + } + title="Calibre content server" + body={'Using a Calibre content server allows Readarr to add books to your Calibre library and trigger conversions between formats'} + position={tooltipPositions.RIGHT} + /> + @@ -150,7 +164,7 @@ function EditRootFolderModalContent(props) { @@ -211,7 +225,7 @@ function EditRootFolderModalContent(props) { @@ -228,7 +242,7 @@ function EditRootFolderModalContent(props) { /> } title="Calibre output profile" - body={'Specify the output profile. The output profile tells the calibre conversion system how to optimize the created document for the specified device (such as by resizing images for the device screen size). In some cases, an output profile can be used to optimize the output for a particular device, but this is rarely necessary.'} + body={'Specify the output profile. The output profile tells the Calibre conversion system how to optimize the created document for the specified device (such as by resizing images for the device screen size). In some cases, an output profile can be used to optimize the output for a particular device, but this is rarely necessary.'} position={tooltipPositions.RIGHT} /> @@ -249,7 +263,7 @@ function EditRootFolderModalContent(props) { diff --git a/src/NzbDrone.Core/Books/Calibre/CalibreProxy.cs b/src/NzbDrone.Core/Books/Calibre/CalibreProxy.cs index e96464286..551639698 100644 --- a/src/NzbDrone.Core/Books/Calibre/CalibreProxy.cs +++ b/src/NzbDrone.Core/Books/Calibre/CalibreProxy.cs @@ -84,7 +84,7 @@ namespace NzbDrone.Core.Books.Calibre } catch (HttpException ex) { - throw new CalibreException("Unable to add file to calibre library: {0}", ex, ex.Message); + throw new CalibreException("Unable to add file to Calibre library: {0}", ex, ex.Message); } } @@ -220,7 +220,7 @@ namespace NzbDrone.Core.Books.Calibre } catch (HttpException ex) { - throw new CalibreException("Unable to add file to calibre library: {0}", ex, ex.Message); + throw new CalibreException("Unable to add file to Calibre library: {0}", ex, ex.Message); } } @@ -242,7 +242,7 @@ namespace NzbDrone.Core.Books.Calibre } catch (HttpException ex) { - throw new CalibreException("Unable to start calibre conversion: {0}", ex, ex.Message); + throw new CalibreException("Unable to start Calibre conversion: {0}", ex, ex.Message); } } @@ -264,7 +264,7 @@ namespace NzbDrone.Core.Books.Calibre } catch (HttpException ex) { - throw new CalibreException("Unable to connect to calibre library: {0}", ex, ex.Message); + throw new CalibreException("Unable to connect to Calibre library: {0}", ex, ex.Message); } } @@ -303,7 +303,7 @@ namespace NzbDrone.Core.Books.Calibre } catch (HttpException ex) { - throw new CalibreException("Unable to connect to calibre library: {0}", ex, ex.Message); + throw new CalibreException("Unable to connect to Calibre library: {0}", ex, ex.Message); } offset += PAGE_SIZE; @@ -349,7 +349,7 @@ namespace NzbDrone.Core.Books.Calibre } catch (HttpException ex) { - throw new CalibreException("Unable to connect to calibre library: {0}", ex, ex.Message); + throw new CalibreException("Unable to connect to Calibre library: {0}", ex, ex.Message); } } @@ -421,6 +421,7 @@ namespace NzbDrone.Core.Books.Calibre var builder = GetBuilder("", settings); builder.Accept(HttpAccept.Html); builder.SuppressHttpError = true; + builder.AllowAutoRedirect = true; var request = builder.Build(); request.LogResponseContent = false; @@ -432,7 +433,7 @@ namespace NzbDrone.Core.Books.Calibre } catch (WebException ex) { - _logger.Error(ex, "Unable to connect to calibre"); + _logger.Error(ex, "Unable to connect to Calibre"); if (ex.Status == WebExceptionStatus.ConnectFailure) { return new NzbDroneValidationFailure("Host", "Unable to connect") @@ -451,12 +452,17 @@ namespace NzbDrone.Core.Books.Calibre if (response.Content.Contains(@"guac-login")) { - return new ValidationFailure("Port", "Bad port. This is the container's remote calibre GUI, not the calibre content server. Try mapping port 8081."); + return new ValidationFailure("Port", "Bad port. This is the container's remote Calibre GUI, not the Calibre content server. Try mapping port 8081."); + } + + if (response.Content.Contains("Calibre-Web")) + { + return new ValidationFailure("Port", "This is a Calibre-Web server, not the required Calibre content server. See https://manual.calibre-ebook.com/server.html"); } if (!response.Content.Contains(@"calibre")) { - return new ValidationFailure("Port", "Not a valid calibre content server"); + return new ValidationFailure("Port", "Not a valid Calibre content server. See https://manual.calibre-ebook.com/server.html"); } CalibreLibraryInfo libraryInfo;