[Bug 21627] New: System preference for recipient emails of gather_print_notices.pl
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Bug ID: 21627 Summary: System preference for recipient emails of gather_print_notices.pl Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Command-line Utilities Assignee: koha-bugs@lists.koha-community.org Reporter: joonas.kylmala@helsinki.fi QA Contact: testopia@bugs.koha-community.org CC: robin@catalyst.net.nz I think it would be nice if the librarians without shell access to the server could change the email address list that the gather_print_notices.pl cronjob uses to send emails to. Now the only way is to specify the --email option when running the script. I suggest a system preference for this that would have a comma separated list of emails. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Olli-Antti Kivilahti <olli-antti.kivilahti@helsinki.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |olli-antti.kivilahti@helsin | |ki.fi --- Comment #1 from Olli-Antti Kivilahti <olli-antti.kivilahti@helsinki.fi> --- We could have a syspref category 'cronjobs' and we could configure all the cronjobs there. Atleast the portions which make sense to configure via sysprefs. That should be most/all of them. Also what is needed is way to validate that the syspref values are valid. For ex. we use a lot of YAML-valued sysprefs. It would be important to be able to pop in a custom validation subroutine. Also syspref changes need to be logged. I recall there was some kind of a logging subsystem for sysprefs, and that may be sufficient. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 --- Comment #2 from Joonas Kylmälä <joonas.kylmala@helsinki.fi> --- (In reply to Olli-Antti Kivilahti from comment #1)
We could have a syspref category 'cronjobs' and we could configure all the cronjobs there. Atleast the portions which make sense to configure via sysprefs. That should be most/all of them.
Great idea!
Also what is needed is way to validate that the syspref values are valid. For ex. we use a lot of YAML-valued sysprefs. It would be important to be able to pop in a custom validation subroutine.
Also syspref changes need to be logged. I recall there was some kind of a logging subsystem for sysprefs, and that may be sufficient.
These should have their own reports. At least the first issue has already: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20930 -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de --- Comment #3 from Katrin Fischer <katrin.fischer@bsz-bw.de> ---
We could have a syspref category 'cronjobs' and we could configure all the cronjobs there. Atleast the portions which make sense to configure via sysprefs. That should be most/all of them.
+1 And yes, system preference changes are loggged - saved me more than one time. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Danielle Elder <danielle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |danielle@bywatersolutions.c | |om --- Comment #4 from Danielle Elder <danielle@bywatersolutions.com> --- I would love to see the email address default to the branches.branchemail when the --split parameter is used.Otherwise I have to set up additional crons to send the individual notices to each branch e-mail. This gets very lengthy and can end up being dozens of crons for systems with multiple branches. I'd love to simplify this for multi-branch libraries. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 --- Comment #5 from Danielle Elder <danielle@bywatersolutions.com> --- I would love to see the email address default to the branches.branchemail when the --split parameter is used.Otherwise I have to set up additional crons to send the individual notices to each branch e-mail. This gets very lengthy and can end up being dozens of crons for systems with multiple branches. I'd love to simplify this for multi-branch libraries. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Magnus Enger <magnus@libriotech.no> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |magnus@libriotech.no --- Comment #6 from Magnus Enger <magnus@libriotech.no> --- (In reply to Danielle Elder from comment #5)
I would love to see the email address default to the branches.branchemail when the --split parameter is used.Otherwise I have to set up additional crons to send the individual notices to each branch e-mail.
How do you do that? If you do --split and several --email, does not all the files get sent to all the addresses? -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Imani <imani.thomas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |imani.thomas@bywatersolutio | |ns.com Assignee|koha-bugs@lists.koha-commun |imani.thomas@bywatersolutio |ity.org |ns.com -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 --- Comment #7 from Imani <imani.thomas@bywatersolutions.com> --- (In reply to Danielle Elder from comment #5)
I would love to see the email address default to the branches.branchemail when the --split parameter is used.Otherwise I have to set up additional crons to send the individual notices to each branch e-mail. This gets very lengthy and can end up being dozens of crons for systems with multiple branches. I'd love to simplify this for multi-branch libraries.
Hi Danielle, I'm looking at the issue above and saw your comment. I'm curious about your circumstances if they are still relevant. Is this a security concern with sending all the files to all the branches or simply a quality of life issue with the branches not having to sort through the files for other branches to get the notices for their own? Either way I think it will be a little bit out of scope for this bug but can be its own separate issue which I can make after I address the original issue. Thanks! ~Imani -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Imani <imani.thomas@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=21627 --- Comment #8 from Imani <imani.thomas@bywatersolutions.com> --- Created attachment 176339 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=176339&action=edit Bug 21627: Add option to set emails for send_print_notices cronjob To test: 1. Apply Patch, updatedatabase, restart_all 2. go to misc/cronjobs/gather_print_notices.pl and uncomment line 77 which says `say $_ for @emails;` 3. from the misc/cronjobs folder run `perl gather_print_notices.pl -e dev@null.org -e any@other.email` 1. the emails you entered in the command line should be printed and nothing else 4. Search for the system preference 'SendPrintNoticesEmails' and set its value to a comma separated list of values 5. run gather_print_notices again and you should see the values you entered in the system preference instead of the ones you enter at the command line 6. search for the system preference SendPrintNoticesCombineEmails and set its value to 'in addition to' 7. run gather_print_notices again and you should see a combination of the command line emails and the emails you set in the SendPrintNoticesEmails system preference. 8. recomment line 77 in gather_print_notices.pl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 --- Comment #9 from Imani <imani.thomas@bywatersolutions.com> --- Created attachment 176340 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=176340&action=edit Bug 21627: Add SendPrintNoticesCombineEmails and SendPrintNoticesEmails system preferences. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 holly@bywatersolutions.com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |holly@bywatersolutions.com --- Comment #10 from holly@bywatersolutions.com --- Dani's comment is still relevant. Large library systems have a need for the cron to split and send notice files to the library email matching the patron home library. The primary need is simplicity for libraries (not having to sort through for their files). Some libraries do limit patron visibility by library or library group for patron data security. Some library systems will have a security want or need for separated files. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 trevor.diamond@mainlib.org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |trevor.diamond@mainlib.org --- Comment #11 from trevor.diamond@mainlib.org --- My consortium is pretty new, but we would LOVE this functionality. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA CC| |lucas@bywatersolutions.com --- Comment #12 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- QA tool complains about tidiness: Result: [FAIL] installer/data/mysql/atomicupdate/bug_21627.pl FAIL tidiness File is not tidy, please run `perl misc/devel/tidy.pl installer/data/mysql/atomicupdate/bug_21627.pl` [PASS] installer/data/mysql/mandatory/sysprefs.sql [FAIL] koha-tmpl/intranet-tmpl/prog/en/includes/prefs-menu.inc FAIL tidiness File is not tidy, please run `perl misc/devel/tidy.pl koha-tmpl/intranet-tmpl/prog/en/includes/prefs-menu.inc` [PASS] koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/cron.pref [FAIL] misc/cronjobs/gather_print_notices.pl FAIL tidiness File is not tidy, please run `perl misc/devel/tidy.pl misc/cronjobs/gather_print_notices.pl` -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Imani <imani.thomas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 --- Comment #13 from Imani <imani.thomas@bywatersolutions.com> --- Created attachment 189408 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=189408&action=edit Bug 21627: ran perl misc/devel/tidy.pl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Patch doesn't apply -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #176339|0 |1 is obsolete| | --- Comment #14 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 194020 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=194020&action=edit Bug 21627: Add option to set emails for send_print_notices cronjob To test: 1. Apply Patch, updatedatabase, restart_all 2. go to misc/cronjobs/gather_print_notices.pl and uncomment line 77 which says `say $_ for @emails;` 3. from the misc/cronjobs folder run `perl gather_print_notices.pl -e dev@null.org -e any@other.email` 1. the emails you entered in the command line should be printed and nothing else 4. Search for the system preference 'SendPrintNoticesEmails' and set its value to a comma separated list of values 5. run gather_print_notices again and you should see the values you entered in the system preference instead of the ones you enter at the command line 6. search for the system preference SendPrintNoticesCombineEmails and set its value to 'in addition to' 7. run gather_print_notices again and you should see a combination of the command line emails and the emails you set in the SendPrintNoticesEmails system preference. 8. recomment line 77 in gather_print_notices.pl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #176340|0 |1 is obsolete| | --- Comment #15 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 194021 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=194021&action=edit Bug 21627: Add SendPrintNoticesCombineEmails and SendPrintNoticesEmails system preferences. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #189408|0 |1 is obsolete| | --- Comment #16 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 194022 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=194022&action=edit Bug 21627: ran perl misc/devel/tidy.pl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 --- Comment #17 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- rebased for current main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21627 Chris Mathevet <chris.mathevet@inLibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |chris.mathevet@inLibro.com Status|Needs Signoff |Patch doesn't apply -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org