Bug 39786

Summary: ILL get_notice errors if request does not have a patron
Product: Koha Reporter: Pedro Amorim <pedro.amorim>
Component: ILLAssignee: Pedro Amorim <pedro.amorim>
Status: RESOLVED INVALID QA Contact: Tomás Cohen Arazi (tcohen) <tomascohen>
Severity: enhancement    
Priority: P5 - low CC: martin.renvoize, nick, pedro.amorim, tomascohen
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Bug Depends on: 36197    
Bug Blocks:    

Description Pedro Amorim 2025-04-30 10:52:33 UTC
Koha allows for ILL requests without patrons, and since bug 32630 this may happen more often.
Backends compatible with ILLOpacUnauthenticatedRequest will likely have requests without patrons associated, but may still need to make use of Koha::ILL::Request::get_notice (e.g. Koha2Koha backend https://gitlab.com/koha-community/plugins/koha-plugin-ill-koha)

get_notice should be more defensive and consider the possibility of the request not having a patron. Core Koha should handle this validation, the alternative is every backend in this scenario needs to handle it.
Comment 1 Pedro Amorim 2025-04-30 10:56:23 UTC
This is actually handled by bug 32630 already. Missed it while working on a 24.11.x branch.