Mobileread
[Possible Bug] Unchanged Modification Date after Sigil edit
#1  recook 02-27-2021, 05:17 AM
Hi,

newest Calibre 5.12, Sigil 1.2.1:

After editing an EPUB with Sigil, saving and quitting, the Book modification date in Calibre stays unchanged.
--
regards,
-- recook
Reply 

#2  theducks 02-27-2021, 06:16 AM
Modified is a Calibre action (because Calibre knows when it does a change)
OTOH , you just used Sigil. Calibre has no idea if you viewed, edited or aborted a session.
Reply 

#3  KevinH 02-27-2021, 09:04 AM
But for epub3 couldn't calibre just use the official metadata dcterms:modified metadata item since it includes date and time down to the second as to when the file was last modified. That is part of the epub3 spec to update/change that anytime the edited epub3 is written.
Epub2 does not typically include the exact time in its modification date, so it probably can only be used if later than whatever value calibre sets now.
Reply 

#4  capink 02-27-2021, 10:00 AM
Still not possible. Calibre does not have a way to know that the metadata in the epub3 file has actually been changed, when the modification happens by another program outside of calibre's control. Maybe a plugin that can communicate with both programs, if someone is interested in writing it.
Reply 

#5  kovidgoyal 02-27-2021, 10:55 AM
The modified date in calibre refers to when any metadata associated with the book is changed, it *does not* know anything about changes to individual files in the book record.
Reply 

#6  KevinH 02-27-2021, 11:44 AM
Oh, that makes sense. And calibre would show the dc:terms modified value in its metadata as well so the user gets both.
Reply 

#7  recook 02-27-2021, 03:02 PM
Hi,

Quote kovidgoyal
The modified date in calibre refers to when any metadata associated with the book is changed, it *does not* know anything about changes to individual files in the book record.
But it could know because i start Sigil through the Pligin "Open With" and subsequently watch the file date, no?
--
regards,
-- recook
Reply 

#8  BetterRed 02-27-2021, 03:44 PM
Quote recook
But it could know because i start Sigil through the Pligin "Open With" and subsequently watch the file date, no?
Calibre's last_modified/Modified column refers to the date/time the metadata, as represented in the library database, was last changed.

When you edit a format file (epub or azw3) with the calibre editor, the last_modified/Modified column in the book's library metadata is not changed.

The formats_modtimes(date_format) template function could be used to populate a custom column with file system Date modified values, but it would probably carry a performance penalty. See The calibre template language

BR
Reply 

#9  recook 03-03-2021, 10:13 AM
Quote kovidgoyal
The modified date in calibre refers to when any metadata associated with the book is changed, it *does not* know anything about changes to individual files in the book record.
The quickest workaround i found is to make a trivial edit to a metadata field, like: focus title, F2, Enter. Presto, modification date changed.

Sorry i didn't have enough motivation yet to learn the template language (and Python). Is there some "Quick start" article i have overlooked?
--
regards,
-- recook
Reply 

Today's Posts | Search this Thread | Login | Register