[Koha-bugs] [Bug 25634] New: koha-foreach exits if 1 command has non-zero status

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon Jun 1 07:13:18 CEST 2020


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25634

            Bug ID: 25634
           Summary: koha-foreach exits if 1 command has non-zero status
 Change sponsored?: ---
           Product: Koha
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P5 - low
         Component: Architecture, internals, and plumbing
          Assignee: koha-bugs at lists.koha-community.org
          Reporter: dcook at prosentient.com.au
        QA Contact: testopia at bugs.koha-community.org

In 19.11.05 (and certainly other versions affected by Bug 17532), koha-foreach
will exit early if 1 command for 1 instance has a non-zero status.

It seems to me that we should warn on a failure, but we should continue the for
loop, because the failure could be instance (rather than system) specific. 

In my case, /usr/share/koha/bin/cronjobs/overdue_notices.pl isn't running for
most instances, because one of the instances starting with A is encountering
this error: "No branches with active overduerules at
/usr/share/koha/bin/cronjobs/overdue_notices.pl line 347".

While I'll address that individually, it's an unfortunate consequence of Bug
17532 to ditch out early.

I'm thinking the easiest solution would be to remove "set -e" from
koha-foreach, and warn on individual failures.

-- 
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.


More information about the Koha-bugs mailing list