Hold targeter script fails to read --retarget-interval

Bug #1675899 reported by Bill Erickson on 2017-03-24
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Undecided
Unassigned

Bug Description

Evergreen 2.12.

/openils/bin/hold_targeter_v2.pl contains a thinko in the command line arguments configuration, causing any interval value passed to --retarget-interval to result in a value of "1". The field was erroneously configured as a boolean field, instead of a field that accepts a string value.

This field is used to override the default retarget interval configured in the database. As it stands, if this field is used, all targetable holds will be retargeted regardless of their previous check time.

To confirm, run the targeter script with any value for --retarget-interval, grep the logs for DESC (to get the holds-to-target-query) and note that the query contains:

 "-or":[{"prev_check_time":null},{"prev_check_time":{"<=":"<RIGHT NOW>"}}]

Once patched, <RIGHT NOW> will contain <RIGHT NOW minus RETARGET INTERVAL>

Wee patch en route.

Bill Erickson (berick) wrote :
tags: added: pullrequest
Changed in evergreen:
milestone: none → 2.12.1
description: updated
Galen Charlton (gmc) wrote :

Sign-off branch is user/gmcharlt/lp1675899_signoff

tags: added: signedoff
Galen Charlton (gmc) wrote :

Since a week has passed, pushed to master and rel_2_12. Thanks, Bill!

Changed in evergreen:
status: New → Fix Committed
Changed in evergreen:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers