-
Notifications
You must be signed in to change notification settings - Fork 0
ETT-61 Exclude */man items from newyear.pl #207
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- Add `NewYear` module with tests for `are_rights_in_scope` extracted and expanded from what is in bin/newyear.pl - TODO: check the items listed in the tests, which are comprehensive, with KH to get confirmation this is the correct list
This is intended to replace one of the nastiest blocks of code encountered in `bin/newyear.pl` around lines 198-215 and duplicated at 359-376. Much depends on this being comprehensible and working as intended, so this is an attempt to get a better handle on it. Currently this new method is not swapped in. I would like to do an A/B comparison between the two methods of comparing PDD rights predictions.
- Make sure to call ClearErrors on the CRMS object, otherwise a catalog error can become sticky and pollute the output - Only log metadata failure if verbose
aelkiss
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wish this process didn't need to exist, but given that it does, this looks fine to me so far:
- the documentation in
CRMS::NewYearmakes sense, and the comments are helpful given the opacity of the logic inchoose_rights_prediction - it appears the tests cover the cases discussed in the documentation
are_rights_in_scopemakes sense
…fter successful A/B test. - Pass current rights to `SubmitNewYearReview` to eliminate a redundant Rights DB hit. - Short circuit no-op attempt to add to queue when generating TSV report and remove "message" field from the TSV.
|
A/B testing result: no discrepancies between the two versions of the code, except approximately five cases where a random choice was made between pd/add and pd/exp. The randomness exists in both the old code and the new, and is a side effect of using hash keys as a set. KH says "don't care" and I have added a comment in NewYear.pm about the behavior. |
aelkiss
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new changes to use choose_rights_prediction look good to me.
NewYearmodule with tests forare_rights_in_scopeextracted and expanded from what is in bin/newyear.plCRMS::NewYearmethodchoose_rights_predictionbin/newyear.plaround lines 198-215 and duplicated at 359-376.KH and I have examined and discussed both methods in the new module and are in agreement that what is here seems right as long as nothing peculiar emerges in the A/B comparison (which should be done by Nov 7 -- it's a time consuming script to run twice). [Edit: see below on result of A/B]
I am now convinced
choose_rights_predictionshould be wired intonewyear.plas part of this branch.