All rules

A start plus a length of time that does not reach the stated end

duration-mismatchon by defaultJapanese / English

A start date plus a length of time that does not reach the end date given

Example

Flagged
The trial runs for 3 months from April 1, 2026 (until July 31, 2026).
What chaff prints
1:55 April 1, 2026 plus 3 months ends around June 30, 2026, but the end is given as July 31, 2026
Fixed
The trial runs for 3 months from April 1, 2026 (until June 30, 2026).
What chaff prints
no finding

How to fix

Check whether the length or the end date is right and correct the other.

Why it matters

When a start, a length and an end are written together ("for 3 months from April 1, 2026, until July 31, 2026"), the reader cannot tell which of the three is right. It happens when the length or one date is changed and not the other. In a sentence with two dates and one length of time, the start plus the length is compared with the end. Three ways of counting are accepted: with the last day included (April 1 plus 3 months is June 30), without it (July 1), and the day after the period has passed when the first day is not counted (July 2); it is pointed out only when the end matches none. A number of nights is compared with the days between two dates (Oct 12 to Oct 14 is 2 nights), in a sentence with two dates and one number of nights, and in each row of a table with check-in, check-out and nights columns. Where nights and days are written together ("2 days, 1 night"), the days must be one more than the nights. Working hours ("9:00–17:30 with a 1-hour break, 8 hours a day") are checked by taking the start and the break from the end and comparing what is left with the stated hours. A timesheet (Start, End, Break and Hours columns, or one cell holding the time range beside Break and Hours) is checked row by row the same way, and a break longer than the shift is pointed out.

What it does not flag

Only an end that matches none of the three ways of counting is pointed out. A rough length ("about 3 months"), a count in each period ("3 days a week"), a sentence with three or more dates or two or more lengths, and a pair of one date with a year and one without are left alone. So are a rough number of nights ("up to 3 nights") and nights written without dates. Working hours are left alone without a stated total, with a break of no length ("breaks provided"), with two or more ranges of time on a line (a shift table only on rows that state their own hours), and across midnight without a next-day mark. In a timesheet, a table without a Break or an Hours column, a row with a cell that cannot be read exactly (no break, a bare number of break, a.m. or p.m. on only one time), and a row across midnight in a document that does not mention night work are left alone.

Turning it off or relaxing it

Silence this one spot (in the document)
<!-- stet: duration-mismatch — reason -->
Relax it for the team (the reason is kept as a comment in chaff.yaml)
npx chaffjs relax duration-mismatch --why "reason"
Turn it off for the team (chaff.yaml)
rules: duration-mismatch: off
Technical details
Layer
L3
Status
stable
Severity
warning
Languages
Japanese and English
Suited to
business, technical, blog, legal, docs, academic, literature, speech
Reads from the document
dates

Levels

Set a level for this rule under rules in chaff.yaml. With nothing set, it runs at the level its genre gives it (see By genre below).

normalwarning
relaxedinfo

This rule has no limit to count to. A level sets how a finding is marked: relaxed keeps the finding and marks it a step lower.

By genre

Runs by default in
technical/spec, technical/readme, blog/tech, blog/essay, blog/owned-media, business/proposal, business/report, business/email, business/press-release, business/meeting-notes, legal/contract, legal/statute, legal/judgment, legal/patent, docs/manual, docs/faq, docs/glossary, academic/paper, literature/fiction, literature/essay, literature/poetry, literature/play, speech/address, speech/transcript

Genres

Message

{start} plus {duration} ends around {expected}, but the end is given as {end}

{start} to {end} makes {expected} as the number of nights, but {nights} is written

{nights} makes {expected} days, but {days} is written

{start} to {end} less the break ({break}) makes {hours} hours {minutes} minutes, but {total} is written

{start} to {end} less the break ({break}) makes {hours} hours, but {total} is written

{start} to {end} less the break ({break}) makes {minutes} minutes, but {total} is written

The break ({break}) is longer than the shift from {start} to {end}

Rewrite depth (chaff fix-plan --depth): light — words and sentences; the structure and the voice stay

This page is built from the rule's definition file:packages/chaff/rules/duration-mismatch.yaml