[Bug 41318] New: AmazonLocale system preference - add Brazil as an option
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Bug ID: 41318 Summary: AmazonLocale system preference - add Brazil as an option Initiative type: --- Sponsorship --- status: Product: Koha Version: unspecified Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: OPAC Assignee: oleonard@myacpl.org Reporter: david@davidnind.com QA Contact: testopia@bugs.koha-community.org See the post on Mattermost chat https://chat.koha-community.org/koha-community/pl/7mr33cigziruzpjsutpy97acka on 27 November 2025: amandap Hello Kohers <3, I would like to propose an enhancement to the AmazonLocale System Preference to include Brazil (amazon.com.br) as a selectable option. Currently, the system preference does not list a Brazilian locale. Brazilian libraries using Koha are forced to select the US (amazon.com) or another locale, which results in a low cover image match rate for Brazilian Portuguese editions, as our editions often differ significantly from those listed in other Amazon stores. Including amazon.com.br would significantly improve the accuracy of cover images displayed on the OPAC and Staff Interface for libraries operating in Brazil and potentially other Portuguese-speaking countries, enhancing the value of the Enhanced Content feature for this region. Thank you for considering this enhancement. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|unspecified |Main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 --- Comment #1 from Jonathan Druart <jonathan.druart@gmail.com> --- Created attachment 189988 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=189988&action=edit Bug 41318: Rename AmazonLocale to AmazonLocaleTld To be more flexible we could allow the top-level domain instead of having a predefined list. However this patch still list the different available options (and adds Brazilian) for easy selection. Note that this system preference is not used to retrieve the image but only to link to from the image. Contrary to what the reporter of the bug report thought. And actually what I thought as well until I finished to write the patch and started testing it! Anyway now the patch is written, there should not be any changes in behaviour. Most of the time the links are actually broken when not using .com. So I think we either broke the whole feature at some point, or it never really worked. On a separate bug we could eventually have a look at fetching from the locale tld. Test plan: Turn on OPACAmazonCoverImages and AmazonCoverImages http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=5 http://localhost:8080/cgi-bin/koha/opac-detail.pl?biblionumber=5 => You see the PBP cover click on it, it opens the lightbox, click "(see the original image)" at the bottom => This is where the syspref AmazonLocale/AmazonLocaleTld acts Modify the syspref's value and confirm that the link is modified and point to the correct domain (leading to 404 or broken pages most of the time, at least in my tests). -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Jonathan Druart <jonathan.druart@gmail.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=41318 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@gmail.com Assignee|oleonard@myacpl.org |jonathan.druart@gmail.com --- Comment #2 from Jonathan Druart <jonathan.druart@gmail.com> --- The "fun" part is that the Brazilian's 404 is also a dog, not the same however :D -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 David Nind <david@davidnind.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=41318 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #189988|0 |1 is obsolete| | --- Comment #3 from David Nind <david@davidnind.com> --- Created attachment 190000 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=190000&action=edit Bug 41318: Rename AmazonLocale to AmazonLocaleTld To be more flexible we could allow the top-level domain instead of having a predefined list. However this patch still list the different available options (and adds Brazilian) for easy selection. Note that this system preference is not used to retrieve the image but only to link to from the image. Contrary to what the reporter of the bug report thought. And actually what I thought as well until I finished to write the patch and started testing it! Anyway now the patch is written, there should not be any changes in behaviour. Most of the time the links are actually broken when not using .com. So I think we either broke the whole feature at some point, or it never really worked. On a separate bug we could eventually have a look at fetching from the locale tld. Test plan: Turn on OPACAmazonCoverImages and AmazonCoverImages http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=5 http://localhost:8080/cgi-bin/koha/opac-detail.pl?biblionumber=5 => You see the PBP cover click on it, it opens the lightbox, click "(see the original image)" at the bottom => This is where the syspref AmazonLocale/AmazonLocaleTld acts Modify the syspref's value and confirm that the link is modified and point to the correct domain (leading to 404 or broken pages most of the time, at least in my tests). Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the| |This enhancement lets you release notes| |manually set the top-level | |domain using the | |AmazonLocaleTld system | |preference (previously | |AmazonLocale), instead of | |using a hard-coded | |predefined list. | | | |Notes: | |- AmazonLocale system | |preference is now renamed | |to AmazonLocaleTld. | |- There is no dropdown | |list, but you can click on | |the domains listed under | |options in the description | |to add it. | |- The system preference is | |not actually used to | |retrieve the image, it is | |used for the link "Amazon | |cover image (see the | |original image)" at the | |bottom of the light box | |after clicking on the | |image. | |- If AmazonLocale is set | |and you click the link in | |the light box, it often | |leads to a page not found | |(404) or broken pages on | |the Amazon country domain. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |katrin.fischer@bsz-bw.de |y.org | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #4 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Tests are failing on an updated installation - probably also needs to remove the options? Please also make the success message green :) Running tests (1) * Proving /kohadevbox/koha/t/db_dependent/check_sysprefs.t FAIL # Failed test 'Comparing AmazonLocaleTld' # at /kohadevbox/koha/t/db_dependent/check_sysprefs.t line 189. # Structures begin differing at: # $got->{options} = 'US|CA|DE|FR|IN|JP|UK' # $expected->{options} = '' # Looks like you failed 1 test of 1755. # Failed test 'Compare database with sysprefs.sql file' # at /kohadevbox/koha/t/db_dependent/check_sysprefs.t line 41. # Looks like you failed 1 test of 3. /kohadevbox/koha/t/db_dependent/check_sysprefs.t .. Dubious, test returned 1 (wstat 256, 0x100) Failed 1/3 subtests -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|katrin.fischer@bsz-bw.de | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #190000|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 --- Comment #5 from Jonathan Druart <jonathan.druart@gmail.com> --- Created attachment 202584 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=202584&action=edit Bug 41318: Rename AmazonLocale to AmazonLocaleTld To be more flexible we could allow the top-level domain instead of having a predefined list. However this patch still list the different available options (and adds Brazilian) for easy selection. Note that this system preference is not used to retrieve the image but only to link to from the image. Contrary to what the reporter of the bug report thought. And actually what I thought as well until I finished to write the patch and started testing it! Anyway now the patch is written, there should not be any changes in behaviour. Most of the time the links are actually broken when not using .com. So I think we either broke the whole feature at some point, or it never really worked. On a separate bug we could eventually have a look at fetching from the locale tld. Test plan: Turn on OPACAmazonCoverImages and AmazonCoverImages http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=5 http://localhost:8080/cgi-bin/koha/opac-detail.pl?biblionumber=5 => You see the PBP cover click on it, it opens the lightbox, click "(see the original image)" at the bottom => This is where the syspref AmazonLocale/AmazonLocaleTld acts Modify the syspref's value and confirm that the link is modified and point to the correct domain (leading to 404 or broken pages most of the time, at least in my tests). Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 --- Comment #6 from Jonathan Druart <jonathan.druart@gmail.com> --- (In reply to Katrin Fischer from comment #4)
Tests are failing on an updated installation - probably also needs to remove the options?
Done.
Please also make the success message green :)
Also done. And patch rebased. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact| |katrin.fischer@bsz-bw.de -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Small patch Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #202584|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 --- Comment #7 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 203389 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=203389&action=edit Bug 41318: Rename AmazonLocale to AmazonLocaleTld To be more flexible we could allow the top-level domain instead of having a predefined list. However this patch still list the different available options (and adds Brazilian) for easy selection. Note that this system preference is not used to retrieve the image but only to link to from the image. Contrary to what the reporter of the bug report thought. And actually what I thought as well until I finished to write the patch and started testing it! Anyway now the patch is written, there should not be any changes in behaviour. Most of the time the links are actually broken when not using .com. So I think we either broke the whole feature at some point, or it never really worked. On a separate bug we could eventually have a look at fetching from the locale tld. Test plan: Turn on OPACAmazonCoverImages and AmazonCoverImages http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=5 http://localhost:8080/cgi-bin/koha/opac-detail.pl?biblionumber=5 => You see the PBP cover click on it, it opens the lightbox, click "(see the original image)" at the bottom => This is where the syspref AmazonLocale/AmazonLocaleTld acts Modify the syspref's value and confirm that the link is modified and point to the correct domain (leading to 404 or broken pages most of the time, at least in my tests). Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 --- Comment #8 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 203390 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=203390&action=edit Bug 41318: (QA follow-up) Change Options to Examples in system preference description While 'Options' might give the impression that the selection is limited to the listed values, 'Examples' seems the better wording. Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Pedro Amorim (ammopt) <pedro.amorim@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to main Version(s)| |26.11.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=41318 --- Comment #9 from Pedro Amorim (ammopt) <pedro.amorim@openfifth.co.uk> --- Thanks everyone! Pushed to main for 26.11! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to main |Pushed to stable Version(s)|26.11.00 |26.11.00,26.05.06 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 --- Comment #10 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Nice work everyone! Pushed to 26.05.x for the upcoming 26.05.06 release. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the|This enhancement lets you |The AmazonLocale system release notes|manually set the top-level |preference is renamed to |domain using the |AmazonLocaleTld. It sets |AmazonLocaleTld system |the top-level Amazon domain |preference (previously |used for the "see the |AmazonLocale), instead of |original image" link at the |using a hard-coded |bottom of the cover image |predefined list. |lightbox. The cover image | |itself is not fetched from |Notes: |this domain. Any domain can |- AmazonLocale system |be entered, and the |preference is now renamed |description lists examples, |to AmazonLocaleTld. |now including com.br for |- There is no dropdown |Brazil. Links to domains |list, but you can click on |other than .com often lead |the domains listed under |to missing or broken Amazon |options in the description |pages, so check the link |to add it. |after changing the value. |- The system preference is | |not actually used to |**Changed system |retrieve the image, it is |preferences** |used for the link "Amazon |- `AmazonLocaleTld` |cover image (see the |(renamed from |original image)" at the |`AmazonLocale`, default: |bottom of the light box |`com`) - top-level domain |after clicking on the |for the "see the original |image. |image" link. |- If AmazonLocale is set | |and you click the link in |**Upgrade notes** |the light box, it often |- Existing values are |leads to a page not found |converted on upgrade: CA, |(404) or broken pages on |UK, DE, FR, IN and JP |the Amazon country domain. |become ca, co.uk, de, fr, | |in and jp. Any other value | |becomes com. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the|The AmazonLocale system |This enhancement lets you release notes|preference is renamed to |manually set the top-level |AmazonLocaleTld. It sets |domain using the |the top-level Amazon domain |AmazonLocaleTld system |used for the "see the |preference (previously |original image" link at the |AmazonLocale), instead of |bottom of the cover image |using a hard-coded |lightbox. The cover image |predefined list. |itself is not fetched from | |this domain. Any domain can |Notes: |be entered, and the |- AmazonLocale system |description lists examples, |preference is now renamed |now including com.br for |to AmazonLocaleTld. |Brazil. Links to domains |- There is no dropdown |other than .com often lead |list, but you can click on |to missing or broken Amazon |the domains listed under |pages, so check the link |options in the description |after changing the value. |to add it. | |- The system preference is |**Changed system |not actually used to |preferences** |retrieve the image, it is |- `AmazonLocaleTld` |used for the link "Amazon |(renamed from |cover image (see the |`AmazonLocale`, default: |original image)" at the |`com`) - top-level domain |bottom of the light box |for the "see the original |after clicking on the |image" link. |image. | |- If AmazonLocale is set |**Upgrade notes** |and you click the link in |- Existing values are |the light box, it often |converted on upgrade: CA, |leads to a page not found |UK, DE, FR, IN and JP |(404) or broken pages on |become ca, co.uk, de, fr, |the Amazon country domain. |in and jp. Any other value | |becomes com. | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41318 --- Comment #11 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- Hello, On 18 November I ran a bulk update of the "Text to go in release notes" field on bugs in the 26.11 range, to fill in missing notes using a consistent template. A mistake in that run also overwrote the release note you had written on this bug. That was not intended, and I am sorry for the noise. I have restored your original text from the bug history, so the field is exactly as you wrote it. Nothing else on this bug was changed. Thank you for writing the note. Martin -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org