Skip to content

Handle ThirdWednesdayInclusive in Schedule stub-date validation - #2993

Open
saanvimundra wants to merge 1 commit into
lballabio:masterfrom
saanvimundra:fix/2989-thirdwednesdayinclusive-validation
Open

saanvimundra wants to merge 1 commit into
lballabio:masterfrom
saanvimundra:fix/2989-thirdwednesdayinclusive-validation

Conversation

@saanvimundra

Copy link
Copy Markdown

Fixes #2989.

ThirdWednesdayInclusive was handled when generating dates but missing from the firstDate/nextToLastDate validation switches in Schedule, so using it with either date threw "unknown rule". It is now handled like ThirdWednesday, so those dates must be IMM dates; happy to relax that if you'd prefer. The catbond stubDate switch now rejects ThirdWednesdayInclusive, CDS, CDS2015 and OldCDS with the "not allowed" message instead of "unknown rule".

Added a regression test (ScheduleTests/testThirdWednesdayInclusiveWithStubDates). It fails without the fix, and the rest of ScheduleTests still passes.

ThirdWednesdayInclusive was handled by the generation switch but not by
the firstDate/nextToLastDate validation switches in Schedule, so using it
with either date failed with "unknown rule". Handle it like
ThirdWednesday in both.

Also handle ThirdWednesdayInclusive, CDS, CDS2015 and OldCDS in the
catbond stubDate switch, which previously reported them as unknown rules.

Fixes lballabio#2989.
@CLAassistant

CLAassistant commented Oct 31, 2026 •

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@boring-cyborg

boring-cyborg Bot commented Oct 31, 2026

Copy link
Copy Markdown

Thanks for opening this pull request! It might take a while before we look at it, so don't worry if there seems to be no feedback. We'll get to it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ThirdWednesdayInclusive reported as 'unknown rule' in Schedule firstDate/nextToLastDate validation and catbond stubDate switch

2 participants