Open
Conversation
EndOf#final_date subtracted 1 period before adding period_count, causing V1E12M to expire at end of month 11 instead of month 12. Remove the offset so the notation matches user expectations: V1E12M from Dec 1 now correctly expires Dec 31 (not Nov 30). Fixed: EndOf cycle expiration was 1 month early (QUAL-6189)
This was referenced Mar 17, 2026
With the off-by-one fixed, "18th month" is literally correct. "18th subsequent month" was ambiguous about whether it meant "18 months after" or "the 18th month following the current one." Also simplifies dormant_to_s from heredoc+squish to a plain string, and renames subsequent_ordinal to ordinalized_period_count.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Split from #69 per review feedback — this PR contains only the EndOf bugfix (QUAL-6189).
EndOf#final_datesubtracted 1 period before addingperiod_count, causingV1E12Mto expire at end of month 11 instead of month 12- 1.send(period)offset so notation matches user expectationsExample — V1E12M from Dec 1, 2025:
Confirmed by AFMAN 10-3500V1 A2.3.3: "For tasks with a minimum frequency determined by months, currency on the task is maintained through the last day of the expiration month."
SOFJTAC migration note
If SOFJTAC is reactivated, JTAC EndOf cycles will compute differently under this fix. Per jdowd: JTACs described evaluations as "18 month cycle" but the old code gave them 17 months. If no one compensated by bumping the period count (e.g., using
V1E19Mto get 18 actual months), existing notations are now correct per AFMAN and no migration is needed. Worth verifying against JTAC seed data before reactivation.Test plan
Fixes QUAL-6189
Split from #69