Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 06-02-2016, 05:30 PM   #46
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,421
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Post-processing, like the OP says:

Quote:
If activated, either a random 12 character ASIN or an ASIN defined as a metadata entry will be added to the file using KevinH's dualmetafix_mmap.py.
(emphasis mine)
eschwartz is offline   Reply With Quote
Old 06-03-2016, 11:14 AM   #47
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 28,044
Karma: 199464182
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by jcsalomon View Post
How does the kindlegen plug-in add the ASIN when the option is selected? Is there an undocumented kindlegen option to this effect, or is it post-processing the generated file?
The plugin creates the ASIN metadata when it already exists in certain records in the Kindlebook's metadata.

ASINs are either part of the Kindlebook inherently (purchased from Amazon), or they've been added to the Kindlebooks through an external (post-proccessing) step such as the one eschwartz mentioned.
DiapDealer is offline   Reply With Quote
Advert
Old 06-03-2016, 11:44 AM   #48
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,640
Karma: 23191067
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by DiapDealer View Post
The plugin creates the ASIN metadata when it already exists in certain records in the Kindlebook's metadata.
That's correct. For example, if a user imports an Kindle book with the KindleImport plugin, it'll generate the following metadata entry for books that already have an ASIN:

Code:
<dc:identifier opf:scheme="AMAZON">B00XXXXXXX</dc:identifier>
If the KindleGen plugin can't find the above metadata entry it'll also look for the following metadata entry:

Code:
<dc:identifier opf:scheme="MOBI-ASIN">B00XXXXXXX</dc:identifier>
As eschwartz has already mentioned, if none of these entries exist, the plugin will use KevinH's dualmetafix_mmap.py file to add a random 12 character ASIN to the MOBI/AZW3 files.

BTW, on eInk Kindles, AZW3 files with an ASIN number will be displayed without a cover thumbnail. That's why the plugin can also optionally generate a cover thumbnail file.
Doitsu is offline   Reply With Quote
Old 06-03-2016, 11:56 AM   #49
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 28,044
Karma: 199464182
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Oops! I thought I was posting in my kindleimport plugin's thread!

At least everything I said made a bit of sense regardless.
DiapDealer is offline   Reply With Quote
Old 08-28-2016, 11:20 AM   #50
Vampyr
Junior Member
Vampyr began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Jun 2015
Location: Poland
Device: PW2
I have two problems. In kindlegen.ini i have:
Code:
azw3_only = True
but its generating still both files: azw3 and mobi. Second problem is in azw3 files, not always, but often missing style file. I have manually add style.ini from epub.
Vampyr is offline   Reply With Quote
Advert
Old 08-28-2016, 11:34 AM   #51
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,640
Karma: 23191067
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by Vampyr View Post
I have two problems. In kindlegen.ini i have:
Code:
azw3_only = True
but its generating still both files: azw3 and mobi.
That's the default behavior. You can either delete the .mobi file or comment out line #367 in plugin.py.

from:
Code:
                    open(outmobi7, 'wb').write(mobisplit.getResult7())
to:

Code:
                    #open(outmobi7, 'wb').write(mobisplit.getResult7())
Quote:
Originally Posted by Vampyr View Post
Second problem is in azw3 files, not always, but often missing style file. I have manually add style.ini from epub.
You can't change style settings with a style.ini file. (The plugin only checks the settings in kindlegen.ini.)
If you have problems with styles, you most likely didn't link the style sheets in Sigil via Link Stylesheets...
Doitsu is offline   Reply With Quote
Old 08-28-2016, 12:34 PM   #52
Vampyr
Junior Member
Vampyr began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Jun 2015
Location: Poland
Device: PW2
Quote:
Originally Posted by Doitsu View Post
That's the default behavior. You can either delete the .mobi file or comment out line #367 in plugin.py.[..]
Thanks, works. I don't know why, but in mine file plugin.py it's line #352. Log file still says that mobi file is generated, but there is no mobi file now.
Vampyr is offline   Reply With Quote
Old 01-03-2017, 10:16 AM   #53
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,640
Karma: 23191067
Join Date: Dec 2010
Device: Kindle PW2
I added a simple GUI with Sigil preferences support and some checks for epub3 books. For details see the first post.
Doitsu is offline   Reply With Quote
Old 04-26-2017, 09:27 AM   #54
severus
Member
severus began at the beginning.
 
severus's Avatar
 
Posts: 21
Karma: 10
Join Date: Aug 2013
Device: Kindle Voyage
Thanks for your work on the plugin.

When I run the plugin, I get this message:

Quote:
Status: failed

Traceback (most recent call last):
File "C:\Program Files\Sigil\plugin_launchers\\python\launcher.py", line 134, in launch
target_script = __import__(script_module)
File "C:\Users\...\AppData\Local\sigil-ebook\sigil\plugins\KindleGen\plugin.py", line 11, in <module>
from PIL import Image
ImportError: No module named 'PIL'
Error: No module named 'PIL'
Any suggestions what can be wrong, and how to fix this? Thanks!
severus is offline   Reply With Quote
Old 04-26-2017, 10:18 AM   #55
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,640
Karma: 23191067
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by severus View Post
Any suggestions what can be wrong, and how to fix this? Thanks!
This message is usually being displayed if the PIL library can't be found.
Select Plugins > Manage Plugins and enable the Use Bundled Python option. If you're using an older Sigil version that doesn't come with a bundled Python interpreter, try the following:
  1. Open an administrator prompt.
  2. Go to the Python folder that contains pip.exe (or pip3.exe) and enter the following command:
    Code:
    pip install Pillow

(You also might have to install beautifulsoup4 and lxml.)
Doitsu is offline   Reply With Quote
Old 04-26-2017, 01:02 PM   #56
severus
Member
severus began at the beginning.
 
severus's Avatar
 
Posts: 21
Karma: 10
Join Date: Aug 2013
Device: Kindle Voyage
Thanks! I have neither of the three installed. Will do it straight away.
severus is offline   Reply With Quote
Old 04-26-2017, 01:29 PM   #57
.MP
Junior Member
.MP began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Apr 2017
Device: Kindle
Anyone knows the difference between mobi files generated normally with kindlegen and the ones using -amzncreator argument (possibly how previewer generates them)?

Thanks for the plugin.

Last edited by .MP; 04-26-2017 at 06:52 PM.
.MP is offline   Reply With Quote
Old 04-26-2017, 01:52 PM   #58
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,640
Karma: 23191067
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by .MP View Post
Anyone knows the difference between mobi files generated normally with kindlegen and the ones using -amzncreator argument (possibly how previewer generates them)?
AFAIK, jhowell, has reverse-engineered parts of Kindle Previewer for his Calibre KFX plugin. He might know what this parameter does.
Doitsu is offline   Reply With Quote
Old 04-26-2017, 06:51 PM   #59
.MP
Junior Member
.MP began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Apr 2017
Device: Kindle
Quote:
Originally Posted by Doitsu View Post
AFAIK, jhowell, has reverse-engineered parts of Kindle Previewer for his Calibre KFX plugin. He might know what this parameter does.
Thanks for the information. I will send him a PM.
.MP is offline   Reply With Quote
Old 06-09-2017, 01:57 AM   #60
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 677
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by Doitsu View Post
I added a simple GUI with Sigil preferences support and some checks for epub3 books. For details see the first post.
I had an version 0.1 working and uninstalled that, installed 0.4.
I'm using Sigil 0.91.

When I run it, it it just runs for a few seconds then I get :

Quote:
Status: failed

Traceback (most recent call last):
File "d:\sigil\plugin_launchers\python\launcher.py" , line 135, in launch
self.exitcode = target_script.run(container)
File "C:\DOCUME~1\Owner\Local Settings\Application Data\sigil-ebook\sigil\plugins\KindleGen\plugin.py", line 316, in run
epubversion = bk.epub_version()
AttributeError: 'OutputContainer' object has no attribute 'epub_version'
Error: 'OutputContainer' object has no attribute 'epub_version'
Looking at the code, this is the very first thing it does in the main routine.

This for an epub I had just run the old version on earlier, so I don't think there is any problem with that. Epubcheck says no errors. I tried a few others with the same result.

I didn't see the preferences GUI. How do I get that?

Also there is no kindlegen.ini file anywhere. The old one was deleted when I uninstalled it, but no new one was created.

So I reinstalled 0.1, copied the ini file, uninstalled, installed 0.4, copied the 0.1 ini file into its folder, but still the same error as above.

0.1 worked to make the basic file, but I wanted the later version to get the thumbnail as well.

Full disclosure: I am running DiapDealer's "Unofficial Sigil Windows XP Build" on XP, so if there is some Win 7 or later dependency, I could be screwed.
Are the earlier versions of this plugin available to try? When was the thumbnail option introduced?

Last edited by AlanHK; 06-09-2017 at 03:20 AM.
AlanHK is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
epubcheck plugin for Sigil Doitsu Plugins 533 10-24-2024 04:32 PM
[Plugin] PunctuationSmarten Sigil plugin DiapDealer Plugins 138 07-11-2023 12:22 PM
[Plugin] KindleImport Sigil plugin DiapDealer Plugins 187 07-04-2022 11:11 AM
font change sigil to mobi with kindlegen wyatt650 Sigil 4 09-05-2013 11:49 AM
Sigil to Kindlegen -- No Table of Contents paul-b Sigil 70 05-03-2012 05:57 PM


All times are GMT -4. The time now is 01:18 PM.


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