Bug 30714

Summary: Checkins from other branches spam the cataloguing log
Product: Koha Reporter: Nick Clemens (kidclamp) <nick>
Component: Architecture, internals, and plumbingAssignee: Nick Clemens (kidclamp) <nick>
Status: CLOSED FIXED QA Contact: Marcel de Rooy <m.de.rooy>
Severity: normal    
Priority: P5 - low CC: fridolin.somers, joonas.kylmala, m.de.rooy
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
22.05.00
Circulation function:
Attachments: Bug 30714: Unit test
Bug 30714: Do no log update to holdingbranch
Bug 30714: Unit test
Bug 30714: Do no log update to holdingbranch
Bug 30714: Do no log update to holdingbranch

Description Nick Clemens (kidclamp) 2022-05-06 20:20:48 UTC
When an item from another branch is checked in, the holdingbranch is updated, and this change is logged.  We record the checkin in statistics, we do not need the cataloguing update logged

To recreate:
1 - Enable cataloguing log
2 - Check in an item with a different holding branch
3 - Check the action logs
4 - There is a cataloguing log for the holdingbranch update
Comment 1 Nick Clemens (kidclamp) 2022-05-06 20:37:01 UTC
Created attachment 134763 [details] [review]
Bug 30714: Unit test
Comment 2 Nick Clemens (kidclamp) 2022-05-06 20:37:05 UTC
Created attachment 134764 [details] [review]
Bug 30714: Do no log update to holdingbranch

When an item from another branch is checked in, the holdingbranch is updated, and this change is logged.  We record the checkin in statistics, we do not need the cataloguing update logged

To recreate:
1 - Enable cataloguing log
2 - Check in an item with a different holding branch
3 - Check the action logs
4 - There is a cataloguing log for the holdingbranch update
5 - Apply patch
6 - Repeate with another item
7 - No log added!
Comment 3 Owen Leonard 2022-05-11 11:06:52 UTC
Created attachment 134863 [details] [review]
Bug 30714: Unit test

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Comment 4 Owen Leonard 2022-05-11 11:06:56 UTC
Created attachment 134864 [details] [review]
Bug 30714: Do no log update to holdingbranch

When an item from another branch is checked in, the holdingbranch is
updated, and this change is logged.  We record the checkin in
statistics, we do not need the cataloguing update logged

To recreate:
1 - Enable cataloguing log
2 - Check in an item with a different holding branch
3 - Check the action logs
4 - There is a cataloguing log for the holdingbranch update
5 - Apply patch
6 - Repeate with another item
7 - No log added!

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Comment 5 Joonas Kylmälä 2022-05-16 19:15:22 UTC
I'm a bit unsure about this proposal, as the info in statistics table might be deleted at some point and the CataloguingLog syspref promises to log all item record changes.

Why do you propose this change?
Comment 6 Katrin Fischer 2022-05-17 12:08:08 UTC
We had decided not to add checkins/checkouts to the cataloguing log (they update the onloan column). 

So I think it seems consequential to say that changes that happen due to circulation actions should not update.

Having changes to holding library and onloan not log would personally be ok for me as a rule.

But if this is controversial maybe we could have something like a "MarkLostItemsAsReturned" for this log where we list what is logged more clearly?
Comment 7 Nick Clemens (kidclamp) 2022-05-17 15:41:22 UTC
To me CataloguingLog implies changes made during cataloging, that is changes to a record by a person - not changes made second-hand as in circulation, and I don't think this is the correct place to maintain this information

I could be convinced that 'ReturnLog' should record the return, hence the branch update, even if item not issued, but I think that would be a separate bug
Comment 8 Marcel de Rooy 2022-05-18 11:29:16 UTC
Created attachment 135100 [details] [review]
Bug 30714: Do no log update to holdingbranch

When an item from another branch is checked in, the holdingbranch is
updated, and this change is logged.  We record the checkin in
statistics, we do not need the cataloguing update logged

To recreate:
1 - Enable cataloguing log
2 - Check in an item with a different holding branch
3 - Check the action logs
4 - There is a cataloguing log for the holdingbranch update
5 - Apply patch
6 - Repeate with another item
7 - No log added!

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 9 Fridolin Somers 2022-05-19 02:56:05 UTC
This also rises again the need to separate biblio cataloguing logs from items cataloguing logs
Comment 10 Fridolin Somers 2022-05-19 03:23:02 UTC
Pushed to master for 22.05, thanks to everybody involved ﷐[U+1F984]﷑