[Bug 26578] New: OverDrive results can return false positives when searches contain CCL syntax
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Bug ID: 26578 Summary: OverDrive results can return false positives when searches contain CCL syntax Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: OPAC Assignee: oleonard@myacpl.org Reporter: nick@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org This problem is from the ':' and '=' signs, along with field codes, that can be passed to overdrive when forming queries or clicking links. Depending on the overdrive catalog, these can match records causing inaccurate results To recreate: 1 - Have OverDrive enabled and configured 2 - set UseAuthoritiesForTracings to "Don't use" 3 - Search in the catalog for a record 4 - From the details page for a record click on an author link 5 - Note the query in catalog is like 'au:"Whitford, Bradley."' 6 - Some overdrive catalogs will return records matching 'au:' -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 --- Comment #1 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 110987 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=110987&action=edit Bug 26578: Clean overdrive searches before passing to OD This patch copies regex used in buildQuery to detect ccl code in queries, but here we adapt it to remove any ccl signifiers to ensure correct results from OD To test: 1 - Have OverDrive enabled and configured 2 - set UseAuthoritiesForTracings to "Don't use" 3 - Search in the catalog for a record 4 - From the details page for a record click on an author link 5 - Note the query in catalog is like 'au:"Whitford, Bradley."' 6 - Some overdrive catalogs will return records matching 'au:' 7 - Apply patch 8 - Reload the page, if spurious results now, they should be gone 9 - Perform a search that returns overdrive results 10 - For a title in overdrive search koha with: au:{Author} AND ti:{Title} 11 - Confirm overdrive results are returned 12 - Check the link to overdrive results and note query section is: q=Author AND Title -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|oleonard@myacpl.org |nick@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #110987|0 |1 is obsolete| | --- Comment #2 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 113923 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113923&action=edit Bug 26578: Clean overdrive searches before passing to OD This patch copies regex used in buildQuery to detect ccl code in queries, but here we adapt it to remove any ccl signifiers to ensure correct results from OD To test: 1 - Have OverDrive enabled and configured 2 - set UseAuthoritiesForTracings to "Don't use" 3 - Search in the catalog for a record 4 - From the details page for a record click on an author link 5 - Note the query in catalog is like 'au:"Whitford, Bradley."' 6 - Some overdrive catalogs will return records matching 'au:' 7 - Apply patch 8 - Reload the page, if there were spurious results before, they should now be gone 9 - Perform a search that returns overdrive results 10 - For a title in overdrive search koha with: au:{Author} AND ti:{Title} 11 - Confirm overdrive results are returned 12 - Check the link to overdrive results and note query section is: q=Author AND Title -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113923|0 |1 is obsolete| | --- Comment #3 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 114058 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114058&action=edit Bug 26578: Clean overdrive searches before passing to OD This patch copies regex used in buildQuery to detect ccl code in queries, but here we adapt it to remove any ccl signifiers to ensure correct results from OD To test: 1 - Have OverDrive enabled and configured 2 - set UseAuthoritiesForTracings to "Don't use" 3 - Search in the catalog for a record 4 - From the details page for a record click on an author link 5 - Note the query in catalog is like 'au:"Whitford, Bradley."' 6 - Some overdrive catalogs will return records matching 'au:' 7 - Apply patch 8 - Reload the page, if there were spurious results before, they should now be gone 9 - Perform a search that returns overdrive results 10 - For a title in overdrive search koha with: au:{Author} AND ti:{Title} 11 - Confirm overdrive results are returned 12 - Check the link to overdrive results and note query section is: q=Author AND Title Current status: Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Kelly McElligott <kelly@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Kelly McElligott <kelly@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #114058|0 |1 is obsolete| | --- Comment #4 from Kelly McElligott <kelly@bywatersolutions.com> --- Created attachment 114098 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114098&action=edit Bug 26578: Clean overdrive searches before passing to OD This patch copies regex used in buildQuery to detect ccl code in queries, but here we adapt it to remove any ccl signifiers to ensure correct results from OD To test: 1 - Have OverDrive enabled and configured 2 - set UseAuthoritiesForTracings to "Don't use" 3 - Search in the catalog for a record 4 - From the details page for a record click on an author link 5 - Note the query in catalog is like 'au:"Whitford, Bradley."' 6 - Some overdrive catalogs will return records matching 'au:' 7 - Apply patch 8 - Reload the page, if there were spurious results before, they should now be gone 9 - Perform a search that returns overdrive results 10 - For a title in overdrive search koha with: au:{Author} AND ti:{Title} 11 - Confirm overdrive results are returned 12 - Check the link to overdrive results and note query section is: q=Author AND Title Signed-off-by: Kelly McElligott <kelly@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #114098|0 |1 is obsolete| | --- Comment #5 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 116014 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=116014&action=edit Bug 26578: Clean overdrive searches before passing to OD This patch copies regex used in buildQuery to detect ccl code in queries, but here we adapt it to remove any ccl signifiers to ensure correct results from OD To test: 1 - Have OverDrive enabled and configured 2 - set UseAuthoritiesForTracings to "Don't use" 3 - Search in the catalog for a record 4 - From the details page for a record click on an author link 5 - Note the query in catalog is like 'au:"Whitford, Bradley."' 6 - Some overdrive catalogs will return records matching 'au:' 7 - Apply patch 8 - Reload the page, if there were spurious results before, they should now be gone 9 - Perform a search that returns overdrive results 10 - For a title in overdrive search koha with: au:{Author} AND ti:{Title} 11 - Confirm overdrive results are returned 12 - Check the link to overdrive results and note query section is: q=Author AND Title Signed-off-by: Kelly McElligott <kelly@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl QA Contact|testopia@bugs.koha-communit |m.de.rooy@rijksmuseum.nl |y.org | --- Comment #6 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Looks good to me. Cannot actually test OverDrive. Decoding html entities with DomParser is a recommended approach. This change will only affect people with OD enabled. No harm expected. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |21.05.00 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 --- Comment #7 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 21.05, thanks to everybody involved! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to master |Pushed to stable CC| |fridolin.somers@biblibre.co | |m Version(s)|21.05.00 |21.05.00,20.11.03 released in| | --- Comment #8 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to 20.11.x for 20.11.03 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Andrew Fuerste-Henry <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |andrew@bywatersolutions.com --- Comment #9 from Andrew Fuerste-Henry <andrew@bywatersolutions.com> --- Doesn't apply cleanly to 20.05, please rebase if needed -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26578 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |caroline.cyr-la-rose@inlibr | |o.com -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org