Bug 41698 - Add maintenance script to revert found holds for items currently checked out
Summary: Add maintenance script to revert found holds for items currently checked out
Status: Needs Signoff
Alias: None
Product: Koha
Classification: Unclassified
Component: Command-line Utilities (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Kyle M Hall (khall)
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2026-01-23 19:08 UTC by Kyle M Hall (khall)
Modified: 2026-01-23 19:22 UTC (History)
2 users (show)

See Also:
GIT URL:
Initiative type: ---
Sponsorship status: ---
Comma delimited list of Sponsors:
Crowdfunding goal: 0
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 41698 - Add maintenance script to revert found holds for items currently checked out (3.50 KB, patch)
2026-01-23 19:10 UTC, Kyle M Hall (khall)
Details | Diff | Splinter Review
Bug 41698 - Add maintenance script to revert found holds for items currently checked out (3.53 KB, patch)
2026-01-23 19:15 UTC, Kyle M Hall (khall)
Details | Diff | Splinter Review
Bug 41698: Add maintenance script to revert found holds for items currently checked out (3.55 KB, patch)
2026-01-23 19:17 UTC, Kyle M Hall (khall)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Kyle M Hall (khall) 2026-01-23 19:08:12 UTC
For reasons unknown, it is possible to get into a situation where an item is both checked out to one patron and associated with a found hold for another patron. We should add a script to Koha to fix items in this situation by reverting the found holds.
Comment 1 Kyle M Hall (khall) 2026-01-23 19:10:23 UTC
Created attachment 191978 [details] [review]
Bug 41698 - Add maintenance script to revert found holds for items currently checked out

For reasons unknown, it is possible to get into a situation where an item is both checked out to one patron and associated with a found hold for another patron. We should add a script to Koha to fix items in this situation by reverting the found holds.

Test Plan:
1) Check an item out to a patron
2) Place an item specific hold for another patron
3) Manually set the priority to 0 and found to "W" for that hold
4) Run misc/maintenance/fix_holds_waiting_and_issued.pl
5) Note the hold has been reverted!
Comment 2 Kyle M Hall (khall) 2026-01-23 19:15:35 UTC
Created attachment 191979 [details] [review]
Bug 41698 - Add maintenance script to revert found holds for items currently checked out

For reasons unknown, it is possible to get into a situation where an item is both checked out to one patron and associated with a found hold for another patron. We should add a script to Koha to fix items in this situation by reverting the found holds.

Test Plan:
1) Check an item out to a patron
2) Place an item specific hold for another patron
3) Manually set the priority to 0 and found to "W" for that hold
4) Run misc/maintenance/fix_holds_waiting_and_issued.pl
5) Note the hold has been reverted!
Comment 3 Kyle M Hall (khall) 2026-01-23 19:17:01 UTC
Created attachment 191980 [details] [review]
Bug 41698: Add maintenance script to revert found holds for items currently checked out

For reasons unknown, it is possible to get into a situation where an item is both checked out to one patron and associated with a found hold for another patron. We should add a script to Koha to fix items in this situation by reverting the found holds.

Test Plan:
1) Check an item out to a patron
2) Place an item specific hold for another patron
3) Manually set the priority to 0 and found to "W" for that hold
4) Run misc/maintenance/fix_holds_waiting_and_issued.pl
5) Note the hold has been reverted!