mirror of
https://github.com/ciromattia/kcc
synced 2025-12-13 01:36:27 +00:00
make error message more clear for covers (#938)
* add error reporting to cover * fix period
This commit is contained in:
@@ -513,8 +513,11 @@ def buildEPUB(path, chapternames, tomenumber, ischunked):
|
||||
dirnames, filenames = walkSort(dirnames, filenames)
|
||||
for afile in filenames:
|
||||
if cover is None:
|
||||
cover = os.path.join(os.path.join(path, 'OEBPS', 'Images'),
|
||||
'cover' + getImageFileName(afile)[1])
|
||||
try:
|
||||
cover = os.path.join(os.path.join(path, 'OEBPS', 'Images'),
|
||||
'cover' + getImageFileName(afile)[1])
|
||||
except Exception as e:
|
||||
raise UserWarning(f"{afile}: {e}")
|
||||
options.covers.append((image.Cover(os.path.join(dirpath, afile), cover, options,
|
||||
tomenumber), options.uuid))
|
||||
if not chapter:
|
||||
|
||||
Reference in New Issue
Block a user