![]() |
#1 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
[GUI Plugin] Audit Log
[GUI Plugin] Audit Log
Summary: Undo/Reverse most metadata deletes and updates days or weeks later for selected books and log entries. Creates a log entry for every addition, change or delete for most Calibre standard metadata columns, and for all custom metadata columns. The 'Audit Log Activity Detail' listing may be viewed, optionally exported to the Clipboard as a tab-delimited file, and then purged (or not). If it is purged, no Undo's may be performed for the deleted items, but rather for only future metadata changes. Undo's may themselves be Undone, of course. Logging Metadata Scope: The Standard Calibre metadata columns that are tracked by Audit Log are:
[1] Author_sort is used as a proxy for authors, as it greatly simplifies the logging for books with multiple co-authors. Example: a book with 100 co-authors would require 100 lines in the log, whereas using author_sort requires only 1 line in the log. [2] Pubdate is expressed in the original +0000 UTC, not the Local Time of the User initiating a change in pubdate. [3] Comments can be quite long, so only the first 25 characters are shown in the 'Audit Log Activity Detail'. Internally, AL captures the full length, which is available for viewing via a DB browsing utility if necessary. The table to browse is '_audit_log'. Optionally, AL also tracks all changes to all Custom Columns. You can track Custom Columns and not Standard Columns, and vice versa. Plus, both of course. Undo/Reverse Metadata Scope: The Standard Calibre metadata columns that may be Undone:
Types of Activities Triggering Logging:
Example Uses:
Requires Minimum Calibre Version: 6.0.0 Version History: Spoiler:
Last edited by DaltonST; 01-08-2023 at 05:55 PM. Reason: Version 1.0.19 |
![]() |
![]() |
![]() |
#2 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Reserved for future use.
|
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Version 1.0.1 Custom Columns now in Scope
Version 1.0.1 - 2017-04-19 The scope of metadata now includes all custom columns if desired. Standard Calibre columns and/or custom columns may be activated. However, deactivation deactivates everything.
DaltonST |
![]() |
![]() |
![]() |
#4 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Version 1.0.2-Technical Enhancements Requring Deactivation, Restart, then Activation
Version 1.0.2 - 2017-04-20 All triggers and the log table have been reworked to improve both performance and functionality. AL must be totally deactivated to drop all of AL's SQLite objects, Calibre restarted, and then AL re-activated.
DaltonST |
![]() |
![]() |
![]() |
#5 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Version 1.0.3 - Undo/Reverse Deletes and Updates
New menu option: Undo/Reverse Delete or Update. This is available for all custom columns plus title, pubdate, language, series, comments, identifiers, and publisher.
A few SQLite triggers have been reworked to improve functionality, so to install this Version, AL must be totally deactivated to drop all of AL's SQLite objects in every Library for which it was ever activated, then Calibre restarted, and then AL re-activated. See the attached Undo/Reverse example. DaltonST |
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,782
Karma: 30548723
Join Date: Dec 2006
Location: Singapore
Device: Boyue
|
This plugin seem really useful specially for mass metadata downloads. But I think the name doesn't describe what it does as well as it should. You should name it something like undo metadata or Log for metadata undo.
|
![]() |
![]() |
![]() |
#7 |
Is that a sandwich?
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,245
Karma: 101696762
Join Date: Jun 2010
Device: Nook Glowlight Plus
|
Where does it obtain the book number?
|
![]() |
![]() |
![]() |
#8 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Version 1.0.9 - Python 3 Compatibility
Version 1.0.9 - 2019-04-21 Python 3 Compatibility; Minimum Calibre Version now 3.41.3
Back up your Calibre metadata.db files before installing or upgrading Audit Log. DaltonST |
![]() |
![]() |
![]() |
#9 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Version 1.0.13 Technical Tweaks after compiling with Python 3.8
Version 1.0.13 - 2019-12-16 Technical Tweaks after compiling with Python 3.8.
|
![]() |
![]() |
![]() |
#10 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Version 1.0.14 Technical changes after Python 3.8 testing with Calibre 4.99.2
Version 1.0.14 - 2019-12-20 Technical changes after Python 3.8 testing with Calibre 4.99.2
DaltonST |
![]() |
![]() |
![]() |
#11 |
Junior Member
![]() Posts: 5
Karma: 10
Join Date: Feb 2019
Device: kindle
|
Can you Please release HERE your last Calibre 3.48.0 compatible version of your plugin.
I think it was 1.0.9 maybe 1.0.11 There are some poor People who have to stay on 3.48 on some Devices. I lost my last 3.48 instance with the old Pluginversion. And its not possible to download old versions from inbuilt PluginManager. THANKs |
![]() |
![]() |
![]() |
#12 |
Junior Member
![]() Posts: 8
Karma: 10
Join Date: Dec 2015
Device: K4T
|
Is there a way to have this plugin track changes made via the Tag Browser?
For example, if I change a misspelled tag, Los Angels to Los Angeles and it edits the tag in 18 books, I'd like that to be logged. Also is there a way to know what book # corresponds to what book? For example when it says book 30583 books_tags_link tag insert ... what's the easiest way of finding book 30583? Thanks! |
![]() |
![]() |
![]() |
#13 | ||
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Quote:
As the Original Post says, Tags is one of the Standard Columns that AL logs at the database level. If some Calibre action changes table "tags" in metadata.db, and if you have AL activated for that Library, it will log it as soon as Calibre updates the database from its Cache, which is updated from its GUI by you. AL has no control over when Calibre updates metadata.db. To force the Tag Browser to totally refresh itself, simply close it and then reopen it using the icon in the lower right corner of the GUI. You might use a more powerful editing tool such as "Manage Tags" to change the spelling en masse. Quote:
DaltonST |
||
![]() |
![]() |
![]() |
#14 | |
Junior Member
![]() Posts: 8
Karma: 10
Join Date: Dec 2015
Device: K4T
|
Quote:
I think I've done what you said, but I still can't seem to get the plugin to work though when changing tags via the "Manage Tags" or "Tag Browser" calibre, version 4.15.0 Audit Log: These are the current Audit Log statuses of each Library for which AL activation has taken place. Missing Libraries, if any, will be added here the next time that you use them: T:/FULL LIBRARY-2017-07-25 status: ...ACTIVATED... If I change a single book's tag the log looks like this: Code:
Time +0000 UTC Book Table Name Table Column Table Action Value Old Value New Other 2020-05-13 19:47:26 30562 books_tags_link tag insert Test Tag Code:
2020-05-13 19:59:36Time +0000 UTC Book Table Name Table Column Table Action Value Old Value New Other 2020-05-13 19:59:36 30580 books_tags_link tag insert Test Tag 2020-05-13 19:59:36 30582 books_tags_link tag insert Test Tag If I go to Category Editor (tags) and rename TestTag to Testing Tag, click ok, close the tag browser, reopen tag browser, I still see the changes in the books, and in the tag browser, but nothing in the audit log. I even tried rebooting the computer and restarting Calibre. I know I must be doing something wrong if you say it tracks changes made by the tag browser and Category Editor... but I haven't a clue what! Any ideas? Thanks! |
|
![]() |
![]() |
![]() |
#15 |
Deviser
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
AL logs at the book level
AL logs at the book level. Every log entry it makes must have a book id in it. When you did a rename at the very top tag level, and did nothing at the book level, nothing was logged because nothing at the book level was changed.
However, if you selected only books with the "old tag", and then used bulk metadata edit of books (book level) to simultaneously delete the "old tag" and add the "new tag", then AL would show everything (deletes and adds). Also, if you drag-and-drop a book onto a tag in the Tag Browser to which it should be assigned, that also triggers a book-level event which will be logged by AL. DaltonST Last edited by DaltonST; 05-13-2020 at 06:32 PM. Reason: drag-and-drop |
![]() |
![]() |
![]() |
Tags |
audit, undo |
Thread Tools | Search this Thread |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
[GUI Plugin] KindleUnpack - The Plugin | DiapDealer | Plugins | 506 | 02-14-2025 10:52 PM |
[GUI Plugin] Hyphenate This! | bookbinder | Plugins | 0 | 05-06-2015 02:07 PM |
[GUI Plugin] KiNotes | -axel- | Plugins | 0 | 07-14-2013 07:39 PM |
How to log within plugin? | charlweed | Development | 4 | 08-24-2012 09:19 PM |
[GUI Plugin] Plugin Updater **Deprecated** | kiwidude | Plugins | 159 | 06-19-2011 01:27 PM |