From cf0ecdf4c5e06935a801e5a6f3c4e81bf25114c2 Mon Sep 17 00:00:00 2001 From: Will Estes Date: Sat, 5 Sep 2026 14:08:36 -0400 Subject: [PATCH] Close latent Matins Gospel-homily dedup gap When a Gospel+homily pair is folded into one pool entry, the homily's own text was never registered in seenReadingText -- only the Gospel pericope's text was. Not live for any date today, but the same structural mistake already fixed once for two ids pooling the same Gregory the Great excerpt: a later pooled id whose solo lesson happens to share a homily's exact text would render as a visible duplicate. Co-Authored-By: Claude Sonnet 5 Claude-Session: https://claude.ai/code/session_01T6rG4RTNqLFYcyjbCGkPFs --- src/hours/matins.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/hours/matins.ts b/src/hours/matins.ts index 71dc185..a422746 100644 --- a/src/hours/matins.ts +++ b/src/hours/matins.ts @@ -966,7 +966,11 @@ function buildReadingPool(day: LiturgicalDay, temporalId: string, date: string, const next = readings[i + 1]; const homily = next && !next.isGospel && next.nocturn === reading.nocturn ? next : undefined; bucket.push(gospelReadingPart(reading, homily, id, commonPoolIndex++, day)); - if (homily) i++; + if (homily) { + i++; + const homilyKey = homily.text.la ?? homily.text.en ?? ''; + if (homilyKey) seenReadingText.add(homilyKey); + } } else { bucket.push(nocturnReadingPart(reading, id, commonPoolIndex++, day)); }