|
![]() |
|
Thread Tools | Search this Thread |
![]() |
#1 |
Groupie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 170
Karma: 258122
Join Date: Dec 2007
Device: Ez Reader (hanlin v3)
|
A recent DRM free purchase from Amazon is not working on the Linux version
Kind of a long title, but it covers what is going wrong.
Trying to load either the azw file (from XP version of kindle) or the mobi file (from Win7 Version of kindle) both get a traceback when tyring to load them on the Linux version of calibre. I can load (at least the mobi version) into the windows version of calibre without errors. I then converted it to an epub. Still no errors. I took that epub and tried to load it in the linux version and once again a trace back. Both windows and linux are running version 3.48 of calibre. Here's the traceback Code:
calibre 3.48 embedded-python: False is64bit: True Linux-4.19.71-gentoo.zfs-x86_64-Intel-R-_Core-TM-_i7-4790_CPU_@_3.60GHz-with-gentoo-2.6 Linux ('64bit', 'ELF') ('Linux', '4.19.71-gentoo.zfs', '#1 SMP PREEMPT Sun Sep 8 05:11:07 PDT 2019') Python 2.7.15 Linux: ('Gentoo Base System', '2.6', '') Interface language: None Successfully initialized third party plugins: Find Duplicates (1, 6, 3) Traceback (most recent call last): File "/usr/lib64/calibre/calibre/gui2/viewer/main.py", line 1025, in load_ebook self.metadata.show_metadata(self.iterator.mi, self.iterator.book_format) File "/usr/lib64/calibre/calibre/gui2/viewer/ui.py", line 102, in show_metadata html = render_html(mi, css(), True, self, render_data_func=render_data) File "/usr/lib64/calibre/calibre/gui2/book_details.py", line 113, in render_html use_roman_numbers=config['use_roman_numerals_for_series_number']) File "/usr/lib64/calibre/calibre/gui2/viewer/ui.py", line 99, in render_data default_author_link=default_author_link() File "/usr/lib64/calibre/calibre/ebooks/metadata/book/render.py", line 128, in mi_to_html val = comments_to_html(val) File "/usr/lib64/calibre/calibre/library/comments.py", line 103, in comments_to_html pTag = result.new_tag('p') TypeError: 'NoneType' object is not callable |
![]() |
![]() |
![]() |
#2 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,377
Karma: 78877538
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
|
I'm not an expert in reading the config issue but are you running the official calibre version or is it from the distribution's repository?
If from the repository replace it by the official version. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Groupie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 170
Karma: 258122
Join Date: Dec 2007
Device: Ez Reader (hanlin v3)
|
Gentoo does a compile of the original sources. Should be no additional patches.
I suspect one of the dependencies is having an issue, but I can't make heads or tails out of the trackback to figure out which one to try to fix. |
![]() |
![]() |
![]() |
#4 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,251
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Use the official calibre linux build instead of the gentoo package and you will be fine.
|
![]() |
![]() |
![]() |
#5 |
Groupie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 170
Karma: 258122
Join Date: Dec 2007
Device: Ez Reader (hanlin v3)
|
I will try that. However, I've been using the gentoo build for years and this is the first time I've run into something like this. If you have any ideas on what is failing, I'd love to try to dig deeper and get it corrected.
|
![]() |
![]() |
Advert | |
|
![]() |
#6 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,251
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
That traceback refers to BeautifulSoup. Probably a version incompatibility somewhere.
|
![]() |
![]() |
![]() |
#7 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047190
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
Yes, the Gentoo ebuild from the Portage tree strips Calibre's vendored BeautifulSoup package.
(Mine doesn't). |
![]() |
![]() |
![]() |
#8 |
Groupie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 170
Karma: 258122
Join Date: Dec 2007
Device: Ez Reader (hanlin v3)
|
Thanks. The official build certainly does work. Sounds like a bug report to gentoo might also be in order.
Thanks for the help. |
![]() |
![]() |
![]() |
#9 |
Groupie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 170
Karma: 258122
Join Date: Dec 2007
Device: Ez Reader (hanlin v3)
|
NiLuJe,
In your ebuild, I see you add some additional patches as well as restoring Calibre's BeautifulSoap. Is that something you would recommend over the official calibre install? |
![]() |
![]() |
![]() |
#10 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047190
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@hyegeek: It certainly never caused any trouble on my end. But, for understandable reasons, expect to be asked to try with official binary installs if you ever need support
![]() Do note that this patch contains hard-coded paths, so you might want to drop it (or adapt it). Or simply forget about it if you're not using a Kobo ![]() Last edited by NiLuJe; 09-14-2019 at 09:22 PM. |
![]() |
![]() |
![]() |
#11 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,251
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
calibre does nothave a vendored beautifulsoup anymore, hasn't had one since it switched to bs4
|
![]() |
![]() |
![]() |
#12 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
So basically, yet another Linux distribution that completely inaccurately modifies calibre in order to strip out dependencies, but cannot even do it correctly.
calibre's internal Beautifulsoup.py was a fork of Beautifulsoup3 which changed some things for reasons I don't know and didn't keep track of, but like the other handful of vendored libraries, this can generally be assumed to have been:
So instead of working with upstream to try to get this resolved, and instead of respecting the wishes of upstream, they chose to strip it out anyway. I do not do this in my Arch Linux package! Then, once I do in fact work with upstream to get this properly resolved (by migrating to stock bs4), their completely incorrect downstream modifications no longer work, because the API wrapper interface which they have always broken for News recipes, is also now generally broken for everything that is using the new calibre/ebooks/Beautifulsoup.py which is a *wrapper* for bs4. Tell Gentoo to stop removing this, and next time they want to patch something out they should use a .patch which will stop cleanly applying if the code they are patching has changed in the meantime. Also, while you are at it, tell them to stop using the Debian project's filthy lying patch which removes the plugin downloader for totally illegitimate reasons. (Apparently some vaporware standard which died in 2009 is the only technology which Gentoo will allow for users to interactively download plugins from a centralized HTTPS server. Gag me.) |
![]() |
![]() |
![]() |
#13 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
@NiLuJe, seems like http://trac.ak-team.com is a 502 gateway error.
![]() |
![]() |
![]() |
![]() |
#14 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047190
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@kovidgoyal: Good to know, thanks
![]() ![]() @eschwartz: Yep, a build job ate through /tmp, fixed it ![]() Last edited by NiLuJe; 09-15-2019 at 11:12 AM. |
![]() |
![]() |
![]() |
#15 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
@NiLuJe, also you should be able to remove all xdg/mime/desktop hacks due to https://github.com/kovidgoyal/calibre/pull/988
And python-html2text at least is definitely a missing dependency (and beatifulsoup3 is an outdated one as Kovid noted). I don't know if Gentoo builds run in a minimal chroot like Arch Linux ones do, which tends to discover missing dependencies ![]() Also yes, you should probably use a system mathjax, see e.g. https://git.archlinux.org/svntogit/c...es/calibre#n69 But you might want a package for https://www.archlinux.org/packages/c...apydscript-ng/ as it will dramatically speed up building all .pyj, and you do need to regenerate the server javascript. |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Free (nook/Kindle/iTunes/DRM-free) Chasing Superwoman [Xtian Working Parent Advice] | ATDrake | Deals and Resources (No Self-Promotion or Affiliate Links) | 0 | 05-05-2016 01:11 PM |
Amazon Local App First: Free Voucher to Purchase Select Kindle Books for $1 | hwlester | Deals and Resources (No Self-Promotion or Affiliate Links) | 0 | 09-08-2013 11:19 AM |
Calibre Sync on Android stopped working properly with recent version of Calibre? | khahoon | Calibre | 5 | 07-06-2013 08:14 AM |
Free (DRM-free multi formats) Working Out [Modern BDSM Workplace Erotic Romance] | ATDrake | Deals and Resources (No Self-Promotion or Affiliate Links) | 0 | 12-15-2012 01:56 AM |
Sort by recent first not working | Barty | Amazon Kindle | 4 | 10-25-2010 05:06 PM |