The KindleGen plugin is giving me some trouble on Sigil 0.9.15, which may be due to the same problem happening with the SVG plugin
here. If so, the fix KevinH implemented should take care of it (and I'm hoping that's the case), but I wanted to report this just in case this is useful to anyone.
When I run KindleGen on a book with absolutely no images, it runs fine.
When there are jpgs, I get this:
When all the images are PNG, I get this:
Spoiler:
Code:
Status: failed
Traceback (most recent call last):
File "/Applications/Sigil.app/Contents/plugin_launchers/python/launcher.py", line 135, in launch
self.exitcode = target_script.run(container)
File "/Users/oda/Library/Application Support/sigil-ebook/sigil/plugins/KindleGen/plugin.py", line 542, in run
cover_def = os.path.basename(cover_href)
File "posixpath.py", line 146, in basename
TypeError: expected str, bytes or os.PathLike object, not NoneType
Error: expected str, bytes or os.PathLike object, not NoneType
Before I pinpointed this to images, I tried a clean install (deleted KindleGen plugin and preferences folder then added the plugin back in). I expected it to ask me for the filepath to KindleGen on first-run, but instead got the following error message. (I solved it by copying the json file from a backup of my preferences folder, but would have been stuck if I didn't have the backup.)
Spoiler:
Code:
Status: failed
Traceback (most recent call last):
File "/Applications/Sigil.app/Contents/plugin_launchers/python/launcher.py", line 135, in launch
self.exitcode = target_script.run(container)
File "/Users/oda/Library/Application Support/sigil-ebook/sigil/plugins/KindleGen/plugin.py", line 605, in run
app = Dialog(root, bk)
File "/Users/oda/Library/Application Support/sigil-ebook/sigil/plugins/KindleGen/plugin.py", line 152, in __init__
self.initUI()
File "/Users/oda/Library/Application Support/sigil-ebook/sigil/plugins/KindleGen/plugin.py", line 193, in initUI
kg_path = findKindleGen()
File "/Users/oda/Library/Application Support/sigil-ebook/sigil/plugins/KindleGen/plugin.py", line 118, in findKindleGen
if os.path.isfile(default_osx_path3):
NameError: name 'default_osx_path3' is not defined
Error: name 'default_osx_path3' is not defined
As I said, I'm hoping the fix KevinH implemented for the InsertSVG plugin will solve the image problem, but I wanted to report all this in case it is useful to anyone.
Thank you!