Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre Companion

Notices

Reply
 
Thread Tools Search this Thread
Old 07-19-2018, 06:57 PM   #1
rmzg
Member
rmzg began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Sep 2016
Device: Note5
Calibre Web opds access failing as content server

Hey,

I recently found a program that acts as very nice and fully featured web browser for a calbre library called 'Calibre Web': https://github.com/janeczku/calibre-web

It installed and started working pretty easily but when I attempt to configure its url as a content server inside calibre companion, it refuses to past the "index" page.

CC will connect to the url fine and show me the first page with a list of categories, but when I click on the categories themselves, nothing happens. The search action will actually find books that match but again I can't actually open the links it returns.

I've verified that the links do work in a web browser both on my phone client and a laptop, so I assume there's something slightly off in the format it's returning the opds data in?

Here's an example of the index page it returns:

Code:
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <id>urn:uuid:2853dacf-ed79-42f5-8e8a-a7bb3d1ae6a2</id>
  <link rel="self" href="/opds" type="application/atom+xml;profile=opds-catalog;kind=navigation"/>
  <link rel="start" title="Start" href="/opds"
        type="application/atom+xml;profile=opds-catalog;kind=navigation"/>
  <link title="Search" type="application/atom+xml" href="/opds/search?query={searchTerms}" rel="search"/>
  <title>Calibre-web</title>
  <author>
    <name>Calibre-web</name>
    <uri>https://github.com/janeczku/calibre-web</uri>
  </author>
  <entry>
    <title>Hot Books</title>
    <link rel="http://opds-spec.org/sort/popular" href="/opds/hot" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/hot</id>
    <content type="text">Popular publications from this catalog based on Downloads.</content>
  </entry>
  <entry>
    <title>Best rated Books</title>
    <link rel="http://opds-spec.org/recommended" href="/opds/rated" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/rated</id>
    <content type="text">Popular publications from this catalog based on Rating.</content>
  </entry>
  <entry>
    <title>New Books</title>
    <link rel="http://opds-spec.org/sort/new" href="/opds/new" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/new</id>
    <content type="text">The latest Books</content>
  </entry>
  <entry>
    <title>Random Books</title>
    <link rel="http://opds-spec.org/featured" href="/opds/discover" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/discover</id>
    <content type="text">Show Random Books</content>
  </entry>

  <entry>
    <title>Read Books</title>
    <link rel="subsection" href="/opds/readbooks/" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/readbooks/</id>
    <content type="text">Read Books</content>
  </entry>

  <entry>
    <title>Unread Books</title>
    <link rel="subsection" href="/opds/unreadbooks/" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/unreadbooks/</id>
    <content type="text">Unread Books</content>
  </entry>
  <entry>
    <title>Authors</title>
    <link rel="subsection" href="/opds/author" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/author</id>
    <content type="text">Books ordered by Author</content>
   </entry>
   <entry>
    <title>Category list</title>
    <link rel="subsection" href="/opds/category" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/category</id>
    <content type="text">Books ordered by category</content>
   </entry>
   <entry>
    <title>Series list</title>
    <link rel="subsection" href="/opds/series" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/series</id>
    <content type="text">Books ordered by series</content>
   </entry>
   <entry>
    <title>Public Shelves</title>
    <link rel="subsection" href="/opds/shelfindex/public" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/shelfindex/public</id>
    <content type="text">Books organized in public shelfs, visible to everyone</content>
   </entry>
   
   <entry>
    <title>Your Shelves</title>
    <link rel="subsection" href="/opds/shelfindex/" type="application/atom+xml;profile=opds-catalog"/>
    <id>/opds/shelfindex/</id>
    <content type="text">User's own shelfs, only visible to the current user himself</content>
   </entry>
   
</feed>
rmzg is offline   Reply With Quote
Old 07-20-2018, 10:54 AM   #2
DoctorOhh
US Navy, Retired
DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.
 
DoctorOhh's Avatar
 
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
The CC FAQ states the following.

Does CC's content server connection work with other OPDS web servers?

No. The CC content server connection requires calibre's content server. It does not work with other servers such as COPS or a calibre-to-opds-generated server.

Note that it might appear to work with non-calibre servers, but CC will fail to download books.
DoctorOhh is offline   Reply With Quote
Advert
Old 07-20-2018, 02:21 PM   #3
rmzg
Member
rmzg began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Sep 2016
Device: Note5
Oh.

Why? Can it be fixed?
rmzg is offline   Reply With Quote
Old 07-20-2018, 03:18 PM   #4
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,733
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
CC won't be changed. I added special support to the calibre server to handle getting full metadata and identifying books on the device. I am not interested in reducing CC functionality to support non-calibre servers.
chaley is offline   Reply With Quote
Old 07-20-2018, 04:35 PM   #5
rmzg
Member
rmzg began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Sep 2016
Device: Note5
I actually meant more changing the output of Calibre Web's opds.

What exactly is CC expecting to see when it makes the request? Is this documented someplace?
rmzg is offline   Reply With Quote
Advert
Old 07-20-2018, 08:39 PM   #6
DoctorOhh
US Navy, Retired
DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.
 
DoctorOhh's Avatar
 
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
Quote:
Originally Posted by rmzg View Post
I actually meant more changing the output of Calibre Web's opds.
You might be best accessing the Calibre Web's opds program directly from Moon+ Reader or other program designed to access an OPDS feed.
DoctorOhh is offline   Reply With Quote
Old 07-21-2018, 02:42 PM   #7
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,733
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by rmzg View Post
I actually meant more changing the output of Calibre Web's opds.

What exactly is CC expecting to see when it makes the request? Is this documented someplace?
No. That said, you can use calibre's server log to see CC's queries and the server responses. Calibre is open source and you can look at the code to see how it generates responses to CC's queries, including the content of the various json dictionaries calibre passes back to CC.

I suggest that you use a calibre V2 server unless the server you are changing supports multiple libraries.
chaley is offline   Reply With Quote
Old 07-22-2018, 05:13 PM   #8
rmzg
Member
rmzg began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Sep 2016
Device: Note5
What exactly is a calibre "v2 server"? Like, where would you get/run it and what would that difference be?

Also, will calibre-server complain if its metadata.db is changed out from underneath it? How often does it actually read the database?
rmzg is offline   Reply With Quote
Old 07-23-2018, 12:49 AM   #9
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,733
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by rmzg View Post
What exactly is a calibre "v2 server"? Like, where would you get/run it and what would that difference be?
Calibre has had four major versions, 0, 1, 2, and 3. A "V2" server is a server running calibre V2, for example this one. A "V3" server is one running a current calibre release. The reason I suggested a V2 server is that V3 supports changing libraries. CC recognizes this fact and changes the URLs somewhat to make use of the feature.

As for where you would run it: up to you. Personally I would do development using a server attached to a calibre GUI instance. I run my production server on a Linode VPS.
Quote:
Also, will calibre-server complain if its metadata.db is changed out from underneath it?
No. However, depending on the calibre version it may or may not notice.
Quote:
How often does it actually read the database?
If memory serves me correctly, a V2 server reads the DB at startup. Depending on the underlying OS, it may reread the DB if it changes. I recall that on my Linux VPS the calibre V2 server never reread the DB. I used monit to detect a DB change and restart the server.

A V3 server will reread the DB if its timestamp changes.

It would be better to ask server questions on the dedicated server subforum in calibre. Kovid (author of calibre) hangs around there and can give definitive answers. I also check that subforum so could chime in if there is a CC interaction question or if you are asking about calibre code I wrote (not much in the server itself).
chaley is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Remote access to Calibre library, WITHOUT content server? haertig Calibre 1 10-18-2017 11:24 PM
Help with downloading ebooks into Marvin using Calibre content server vs OPDS deadman36g Calibre 3 12-09-2016 03:20 PM
calibre 2.67 on OSX 10.11.5/10.11.6 content server failing lmamakos Calibre 2 09-11-2016 09:47 AM
calibre-server OPDS catalog - manual move to web server HaakonME Related Tools 5 09-21-2012 03:11 AM
Access calibre content server with Nook Color astrodad Nook Color & Nook Tablet 18 06-02-2011 11:05 AM


All times are GMT -4. The time now is 03:42 AM.


MobileRead.com is a privately owned, operated and funded community.