Register Guidelines E-Books Search Today's Posts Mark Forums Read

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

Notices

Reply
 
Thread Tools Search this Thread
Old 05-12-2019, 11:56 AM   #3421
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 3,702
Karma: 634558
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Voyage
New Test Version Posted

2019-05-12
- Fixes for adapter_storiesonlinenet site changes--login and use datetime by default because one was missing date-only.
- adapter_finestoriescom shares code with adapter_storiesonlinenet, also do datetimes.
- Comment out some debugs in XF/XF2
JimmXinu is offline   Reply With Quote
Old 05-12-2019, 12:23 PM   #3422
ILB
Zealot
ILB began at the beginning.
 
ILB's Avatar
 
Posts: 101
Karma: 10
Join Date: Jun 2012
Location: Germany
Device: Kindle Voyage
Quote:
Originally Posted by JimmXinu View Post
Calibre's Polish feature has an option for add/update (and one for remove) 'metadata jacket'. The jacket is placed directly after the cover (if present). It does not effect the FFF title page, nor does it appear in the TOC like FFF title page does in multi-chapter books.

You can customize it by copying the default jacket template directory to your personal resources dir and then editing the files. The manual page explains it, but it may be a little out of date as for me the source dir is C:\Program Files\Calibre2\app\resources\jacket . Custom columns can be added by using _ instead of #. For #genre:
Code:
        <div>
          <p class="cbj_label">{_genre_label}:</p>
          <p class="cbj_content">{_genre}</p>
        </div>
FFF on update will discard the jacket file. But FFF already has an option to invoke the Polish option to smarten punctuation and I would be willing to add a similar option to automatically call Polish update jacket.

UPDATE: Calling Polish to update jacket might be more difficult than that--there are some 'interesting' interactions between conversion and jacket I would need to explore more.

(BTW, note that if you use Polish to add/update cover page, it will name the cover page file titlepage.xhtml. FFF's title page (title_page.xhtml) is unchanged.)
Thanks JimmXinu and ilovejedd, I tried polish but it gives me a whole extra page that I don´t need – nor want.
It also copies my epub in “Original-EPUB” and adds the new title page in “EPUB” – which makes two EPUBs for which I need memory space when I want only one epub.

It´s only one maybe two of my custom columns that I want to add.
I liked the existing option to add columns to the “normal” title page. And all columns that are filled by settings in personal.ini already work when downloading.
It is just the hassle with columns that are manually filled after downloading.
ILB is online now   Reply With Quote
Advert
Old 05-12-2019, 06:28 PM   #3423
ownedbycats
Enthusiast
ownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheese
 
Posts: 47
Karma: 1044
Join Date: Oct 2018
Device: Kobo Aura HD
New question: I unchecked the "set calibre author URL." Is there a way to remove the URL from already-downloaded fics, though?

As well, why doesn't this work?

Code:
replace_metadata: publisher=>www.fanfiction.net=>FanFiction.net

Last edited by ownedbycats; 05-12-2019 at 06:32 PM.
ownedbycats is offline   Reply With Quote
Old 05-12-2019, 06:54 PM   #3424
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 3,702
Karma: 634558
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Voyage
Quote:
Originally Posted by ownedbycats View Post
New question: I unchecked the "set calibre author URL." Is there a way to remove the URL from already-downloaded fics, though?
Calibre doesn't store author URL by book, it has a separate author table. So to remove an author URL, you have to edit the author record.

The way I know how to do that is to show the Tag Browser (under Layout), right click Authors and choose Manage Authors. Edit author URLs there.

There may be other ways, but I don't know them.

Quote:
Originally Posted by ownedbycats View Post
As well, why doesn't this work?

Code:
replace_metadata: publisher=>www.fanfiction.net=>FanFiction.net
Calibre's Publisher column is populated from site. FFF doesn't have a publisher metadata entry. Use:

Code:
replace_metadata:
 site=>www.fanfiction.net=>FanFiction.net
This is at least twice this has come up, I wonder if it's worth adding publisher as a copy of site and using it...
JimmXinu is offline   Reply With Quote
Old 05-12-2019, 09:59 PM   #3425
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 3,702
Karma: 634558
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Voyage
Quote:
Originally Posted by ILB View Post
Thanks JimmXinu and ilovejedd, I tried polish but it gives me a whole extra page that I don´t need – nor want.
It also copies my epub in “Original-EPUB” and adds the new title page in “EPUB” – which makes two EPUBs for which I need memory space when I want only one epub.

It´s only one maybe two of my custom columns that I want to add.
I liked the existing option to add columns to the “normal” title page. And all columns that are filled by settings in personal.ini already work when downloading.
It is just the hassle with columns that are manually filled after downloading.
I have spent waaay more time (including another hour today) than this corner case can justify trying to fit this into the existing system in way that both works 'as I expect to' and without breaking anything else. I give up.

It's not like there isn't already a way to do it, it's just not as efficient. Use 'Update EPUB always', or don't; it's your choice.
JimmXinu is offline   Reply With Quote
Advert
Old 05-13-2019, 09:30 AM   #3426
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,289
Karma: 83106505
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
You can disable the creation of ORIGINAL_EPUB for polishing books, or delete it right after. Calibre only creates it in order to give you a way to recover your valuable data, if the conversion/polish broke the ebook. Once you know that it didn't break you can always delete it... Or, as I said, you can stop it from ever being created in the first place.
eschwartz is offline   Reply With Quote
Old 05-13-2019, 11:13 AM   #3427
Arkeus
Member
Arkeus began at the beginning.
 
Posts: 17
Karma: 10
Join Date: Oct 2016
Device: Kobo
Wuxiaworld.co currently has a bug. I can update stories just fine, but adding a new one gives me a "utf8' codec can't decode byte 0xe9 in position 58: invalid continuation byte" error. Tried it with 10 random stories.

EDIT: seems to work now?

EDIT: not completely... I am not sure if it's my computer or what.

Last edited by Arkeus; 05-13-2019 at 03:50 PM.
Arkeus is offline   Reply With Quote
Old 05-13-2019, 08:58 PM   #3428
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 3,702
Karma: 634558
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Voyage
@Arkeus - I'm not able to duplicate the issue.

When a problem comes and goes it's usually due to the site having issues.

More rarely, it could be the site slowly rolling out an update across multiple servers.

If you continue to see it, and post a story URL that displays the problem, I'll look into it again.
JimmXinu is offline   Reply With Quote
Old 05-14-2019, 02:18 PM   #3429
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 3,702
Karma: 634558
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Voyage
New Test Version Posted

2019-05-14
- Some fixes for Russian language adapter_masseffect2in.
- Fixes for adapter_quotevcom due to site changes.
- Removing filter()/map() calls--not consistent between Py2/Py3.
- Some Py3 compat / optimization fixes, thanks eschwartz
JimmXinu is offline   Reply With Quote
Old 05-14-2019, 04:11 PM   #3430
ownedbycats
Enthusiast
ownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheeseownedbycats can extract oil from cheese
 
Posts: 47
Karma: 1044
Join Date: Oct 2018
Device: Kobo Aura HD
Quote:
Originally Posted by JimmXinu View Post
This is at least twice this has come up, I wonder if it's worth adding publisher as a copy of site and using it...
That wouldn't be a bad idea. I got it all sorted out now. Thank you.
ownedbycats is offline   Reply With Quote
Old 05-14-2019, 06:35 PM   #3431
MrGarrison
Junior Member
MrGarrison began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Sep 2017
Device: Tablet
There appears to be a problem with Storiesonline - it doesn't prompt me for my login info, thus it only downloads the bit of the story that's viewable to unregistered users.

Edit - I neglected to mention that I'm using the latest test version (05/14/19).
MrGarrison is offline   Reply With Quote
Old 05-14-2019, 07:33 PM   #3432
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 3,702
Karma: 634558
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Voyage
New Test Version Posted

2019-05-14
- Fix for adapter_storiesonlinenet not detecting login failure.
- Some fixes for Russian language adapter_masseffect2in.
- Fixes for adapter_quotevcom due to site changes.
- Removing filter()/map() calls--not consistent between Py2/Py3.
- Some Py3 compat / optimization fixes, thanks eschwartz

This was reported by a web service user, but I didn't put up a plugin version for it until now.

Quote:
I am seeing the problem now: if you don't have username/password set in personal.ini, FFF doesn't ask for user/pass and continues on to collect incomplete chapters.

The text(s) we used to detected failed login changed. I've fixed that and added a check to make sure there is a user/pass before even trying.
JimmXinu is offline   Reply With Quote
Old 05-14-2019, 09:12 PM   #3433
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,289
Karma: 83106505
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Quote:
Originally Posted by JimmXinu View Post
- Removing filter()/map() calls--not consistent between Py2/Py3.
Actually this is not strictly true, they create iterables on py3 and `for i in iterable` works, as does `' '.join(iterable)`. What doesn't work is len(iterable) or iterable[0], and in many, but not all cases, FanFicFare needs to save variables that will later be consumed that way -- but the difference between py2 and py3 is that py2's map() is py3's list(map()).

That being said, there are many who would say filter is un-pythonic. It's sort of a bikeshed issue whether to surround everything with list() or replace it with list comprehensions.

Last edited by eschwartz; 05-14-2019 at 09:15 PM.
eschwartz is offline   Reply With Quote
Old 05-14-2019, 09:50 PM   #3434
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 3,702
Karma: 634558
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Voyage
Quote:
Originally Posted by eschwartz View Post
Actually this is not strictly true, they create iterables on py3 and `for i in iterable` works, as does `' '.join(iterable)`. What doesn't work is len(iterable) or iterable[0], and in many, but not all cases, FanFicFare needs to save variables that will later be consumed that way -- but the difference between py2 and py3 is that py2's map() is py3's list(map()).
I'm not going to argue the point. All I know is that code that worked in Py2 failed in spectacularly obscure ways when I was making the FFF CLI run in Py3.

And rather than worry about the esoteric details about how and why they are different, I decided filter() & map() are simply broken and not to be used in code that needs to run on both Py2 and Py3.

Quote:
Originally Posted by eschwartz View Post
That being said, there are many who would say filter is un-pythonic. It's sort of a bikeshed issue whether to surround everything with list() or replace it with list comprehensions.
From what I understand (which I admit is very shallow), they were the 'pythonic' solutions before list comprehension came along to avoid writing loops and were extremely common. In my ignorance, I copied them from older code which probably copied from even older code.

Okay, I may be arguing the point a bit after all...
JimmXinu is offline   Reply With Quote
Old 05-14-2019, 09:56 PM   #3435
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,289
Karma: 83106505
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Quote:
Originally Posted by JimmXinu View Post
All I know is that code that worked in Py2 failed in spectacularly obscure ways when I was making the FFF CLI run in Py3.
I think it is probably fair to say many developers of python applications thought the same.

Quote:
Originally Posted by JimmXinu View Post
From what I understand (which I admit is very shallow), they were the 'pythonic' solutions before list comprehension came along to avoid writing loops and were extremely common. In my ignorance, I copied them from older code which probably copied from even older code.

Okay, I may be arguing the point a bit after all...
List comprehensions, as well as generator expressions which are the predictable way to get a lighter-memory iterator when you actually want an iterator.

It is probably worth noting that python-modernize will happily convert filter()/map() to list/generator expressions. Can't be too wrong to do the same yourself...

Last edited by eschwartz; 05-14-2019 at 10:00 PM.
eschwartz is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[GUI Plugin] Open With kiwidude Plugins 332 08-31-2018 08:54 AM
[GUI Plugin] KindleUnpack - The Plugin DiapDealer Plugins 412 04-24-2018 06:07 PM
[GUI Plugin] Marvin XD Philantrop Plugins 126 01-29-2017 12:48 PM
[GUI Plugin] KiNotes -axel- Plugins 0 07-14-2013 06:39 PM
[GUI Plugin] Plugin Updater **Deprecated** kiwidude Plugins 159 06-19-2011 12:27 PM


All times are GMT -4. The time now is 11:44 PM.


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