Repository navigation
Conversation
The site now shows chapter release dates as DD/MM/YYYY (e.g. "17/07/2024"). parseDate expected "month day, year" text, so the split produced undefined parts and dayjs(...).toISOString() threw "Invalid time value", failing parseNovel on every novel. parseDate now reads DD/MM/YYYY, still accepts the older month-name layout, and returns null for a missing or unrecognised date instead of throwing. Version 1.0.1 -> 1.0.2.
[Medium impact] The PR appears safe to merge; no blocking issue was found. SummaryUpdates
No actionable issues were found. This review checked the code; it did not repeat the live tests described in the PR. Reviews (2) · Last reviewed commit: "no-mistakes(review): Reject impossible c..." · Reviewed by Greptile |
RibatTRW
marked this pull request as draft
October 15, 2026 12:06
RibatTRW
marked this pull request as ready for review
October 15, 2026 13:22
This branch has not been deployed
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.
Intent
Fix the broken tsundoku source so a reader can open its novels again, and include screenshots of the working fix in the PR.
plugins/portuguese/tsundoku.ts fails at its own live check at parseNovel with
Invalid time value, while the site's list page answers 200 with about 100 KB. So the site is up and serving listings - a date field the plugin parses with dayjs has changed shape and now throws. This is one of the plugins this fleet's plugin health sweep confirmed as genuinely broken today (not a site-side block).Make sure the fix's pull request shows a photo of the plugin working correctly inside the plugin playground, and run that screenshot process headless if possible.
What Changed
parseDateinplugins/portuguese/tsundoku.tsnow accepts onlyDD/MM/YYYYchapter dates and rejects impossible calendar dates (for example31/02/2026). Anything else returnsnullinstead of throwing, so a chapter with an unrecognised date loads without a release time rather than failingparseNovelwithInvalid time value.janeiro,fevereiro, ...) is removed, since the site no longer emits those dates.1.0.1to1.0.2.Risk Assessment
✅ Low: The change is confined to one date-parsing method in a single standalone plugin, the review-2 calendar-rollover guard holds for the cases I traced (31/02, 29/02 in a non-leap year, day 00, month 00), and no unrequested behavior remains.
Testing
Baseline: check:plugin passes on the target commit and reproduces the reported Invalid time value failure on the base commit. Driven live: the playground Parse Novel flow for Tsundoku (novel parses, 115 chapters with release dates, headless screenshot captured), plus in-page and Node probes of parseDate for the calendar and malformed-date guards, which return null without throwing or rolling over. Overall the fix restores parsing and the guards hold. Parse Chapter is covered by the live check against the real site rather than a separate playground drive.
~/.no-mistakes/evidence/01M4ZNQPN49S5E9EZ2E2X5978T/tsundoku-parse-novel-fixed.png)Screenshots
These screenshots come from this repository's plugin playground (
npm run dev:start), not from the LNReader app. The Android toolchain is not installed on the machine that made this change, so this fix has not been tested in the app.Captured headless (Chromium driven through chrome-devtools-axi), with the Tsundoku source selected:
This PR was written by an AI agent (Claude), and the change and its tests were AI-driven. No human has reviewed it yet.
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
🔧 **Review** - 1 issue found → auto-fixed (2) ✅
plugins/portuguese/tsundoku.ts:42- Simplification: the legacy month-name date branch (janeiro 5, 2024) and itsmonthMappingtable (lines 16-29, 42-49) are a second date layout the intent does not require. The intent asks only that the current chapter date field, which has changed shape, parse so the novels open again. No source in the diff proves the site still emits the month-name layout. Remove the legacy branch andmonthMappingas the smallest remedy; parse only the DD/MM/YYYY form and return null for anything else. If the owner has evidence the old layout is still served, keep it and say so in the PR.🔧 Fix applied.
2 issues (1 warning, 1 info) still open:
plugins/portuguese/tsundoku.ts:42- Simplification: the legacy month-name date branch (janeiro 5, 2024) and itsmonthMappingtable (lines 16-29, 42-49) are a second date layout the intent does not require. The intent asks only that the current chapter date field, which has changed shape, parse so the novels open again. No source in the diff proves the site still emits the month-name layout. Remove the legacy branch andmonthMappingas the smallest remedy; parse only the DD/MM/YYYY form and return null for anything else. If the owner has evidence the old layout is still served, keep it and say so in the PR.plugins/portuguese/tsundoku.ts:22- parseDate accepts calendar-impossible DD/MM/YYYY dates and silently rolls them over:31/02/2024becomes2024-2-31, which dayjs turns into 2024-03-02 with isValid() true, so the chapter gets a wrong release time instead of null. OnlyisValid()guards the overflow-free path. Fix: after parsing, checkparsed.date() === Number(day) && parsed.month() === Number(month) - 1(or use a strict format parse) and return null on mismatch. Rare in practice since the site emits real dates.🔧 Fix applied.
✅ Re-checked - no issues remain.
✅ **Test** - passed
✅ No issues found.
npm run check:plugin -- plugins/portuguese/tsundoku.tson the target commit: all four checks PASS (popularNovels 48, searchNovels 1, parseNovel 115 chapters, parseChapter 881 chars).npm run check:pluginon a temporary copy of the base-commit file (49b4727, removed afterwards): parseNovel FAIL withInvalid time value, reproducing the reported failure.npm run dev:startplayground Vite bound to 127.0.0.1:3100; Chromium maps localhost:3000 to it via --host-resolver-rules because the playground proxy hard-codes localhost:3000.Headless Chromium via chrome-devtools-axi: opened http://localhost:3000/?plugin=tsundoku, Parse Novel tab, entered /manga/86-oitenta-e-seis/, clicked Fetch. Novel header, 115 chapters, first chapter Jun 23, 2024, last updated Jul 17, 2024, release times in the table. Screenshot captured.In-page probe of the served plugin module calling parseDate: '29/02/2024' valid, '31/02/2024' -> null, '' -> null, 'janeiro 5, 2024' -> null.Node esbuild-bundle probe of parseDate: '00/01/2024' -> null, '29/02/2023' -> null, '31/04/2024' -> null, '1/7/2024' and ' 11/07/2024 ' valid.Site emits DD/MM/YYYY chapter dates (curl of novel page: class chapterdate 17/07/2024).Cleanup: stopped my own Vite and Chromium only (other sessions' processes on 3000, 9333 untouched);npm run clean:multisrc; git status clean.✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.