Skip to content

fix(ranobes): chapter order, RU summary and ranobes.net domain - #2747

Open
RikCost wants to merge 9 commits into
lnreader:masterfrom
RikCost:fix/russian-ranobes
Open

RikCost wants to merge 9 commits into
lnreader:masterfrom
RikCost:fix/russian-ranobes

Conversation

@RikCost

@RikCost RikCost commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

Fixes the Ranobes multisrc template (Ranobes (RU) on ranobes.com and Ranobes on ranobes.net).

  • Chapter order: the site's table of contents is newest first and the novel page only shows the latest chapters, so the app listed chapters backwards, starting from the newest page. Chapters are now paged by index from the first one: app page k holds chapters 25(k−1)+1…25k, built from the two neighbouring site pages (only the site's last page is partial). Because the table of contents is newest first, every new chapter shifts all its pages; each page request therefore re-reads the newest page, counts the chapters published since the last request, and places freshly fetched chapters by their index from the first chapter, so releases while paging do not repeat or skip chapters. latestChapter is the newest chapter. If the table of contents cannot be loaded, the error reaches the app (WebView hint) instead of silently showing the latest chapters as page 1.
  • Table of contents URL: it is taken from the novel page's "Перейти в оглавление" link. Its slug can be shorter than the novel slug, and the URL derived from the novel path answered 404 for such novels.
  • Summary (RU): the description block lost its itemprop="description" / moreless attributes, so summaries were empty. The plugin now takes the first cont-text block inside .r-desription, skips its inline <style> and keeps paragraph breaks.
  • English domain: ranobes.top now answers 403; the same site works at ranobes.net. Its "One moment..." challenge page is now treated as a captcha, so the app asks to open the WebView instead of showing an empty list.
  • English search: ranobes.net answers HTTP 404 when a search finds nothing, so every search without a match (e.g. any global search) failed with "Could not reach site (404)". A 404 from the search page now means no results.

Version 2.0.2 → 2.0.3.

Testing

  • Ranobes (RU): live check that bundles the plugin and calls popularNovels, searchNovels, parseNovel, parsePage and parseChapter. On "Лабиринт монстров" all 652 chapters come out over 27 pages in increasing order without duplicates (page 1: 1–25, page 14: 326–350, last page: 652–653). Novels whose table of contents slug differs from the novel slug (e.g. "Мужчина во главе женского флота") load again. Summaries are plain text.
  • Ranobes (EN): the site is behind a browser challenge from my network, so I checked it in a real browser. The table of contents is newest first with pages_count (page 1: chapters 691→666, page 28: 14→1), and the catalog and chapter links work on ranobes.net.
  • Ranobes (RU) tested in the LNReader app on Android through a local plugin repository; the ranobes.net switch is not yet tested in the app.

Related: #1953 (next chapter jumps to the first chapter of the previous page). The chapter list is now in increasing order across pages, which should fix it; not yet verified in the app on the English source.

Checklist

  • Update version code if an existing plugin was modified
  • Test changes in Plugin Playground or the app
  • Reference related issues in the PR body (e.g. Closes #xyz)
  • Commit messages follow type(scope): description (e.g. feat(<generator>): add new source)

This change was written with an AI coding agent (Claude Code) and reviewed and tested by the author.

🤖 Generated with Claude Code

RikCost and others added 3 commits October 23, 2026 20:53
The description block lost its itemprop/moreless attributes; take the
first cont-text block inside .r-desription, skip its inline <style> and
keep paragraph breaks.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The site's table of contents is newest first, and the novel page only
shows the latest chapters, so the app listed chapters in reverse with the
newest page first. Map app page N to site page (pages - N + 1), reverse
each page, take the page count from the pagination (or pages_count), and
load the oldest page in parseNovel. latestChapter is the newest chapter.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ranobes.top now answers 403; the same site works at ranobes.net. Treat
its 'One moment...' challenge page as a captcha so the app asks to open
the WebView instead of showing an empty list.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The changes affect chapter reading and English browsing in the two Ranobes sources.

Fix chapter paging before merging; newly published chapters can make readers skip a chapter and see another twice.

Findings

  1. P1 Growing novels skip chapters ▶

Summary

Updates both Ranobes sources to read chapters from oldest to newest.

  • Ranobes chapter pages run from the oldest chapter to the newest.
  • Russian summaries keep the text and paragraph breaks from Ranobes descriptions.
  • English Ranobes uses ranobes.net and handles its site responses.

Reviews (2) · Last reviewed commit: "fix(ranobes): return no results instead ..." · Reviewed by Greptile

Comment thread plugins/multisrc/ranobes/template.ts Outdated
Comment thread plugins/multisrc/ranobes/template.ts Outdated
RikCost and others added 5 commits October 23, 2026 22:13
- do not fall back to the novel page's latest chapters when the table of
  contents cannot be loaded: they would land on page 1 out of order
- map app pages with the page count read by parseNovel (or the first
  parsePage call) instead of updating it on every request, so a novel
  that grows a page while paging does not repeat or skip pages

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- take the table of contents link from the novel page: its slug can be
  shorter than the novel slug, and the derived URL answered 404, so these
  novels failed with 'Unable to load novel'
- page the chapter list by chapter index instead of by site page: app
  page k holds chapters 25(k-1)+1..25k from the first one (a slice of two
  neighbouring site pages), so page 1 is no longer a 2-chapter remainder
- keep the table of contents read by parseNovel while paging

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ranobes.net answers HTTP 404 when a search finds nothing, so every
global search without a match failed with 'Could not reach site (404)'.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Comment thread plugins/multisrc/ranobes/template.ts Outdated
The table of contents is newest first, so every published chapter shifts
all its pages. Mixing cached first/last pages with freshly fetched middle
pages repeated or skipped a chapter after a release. Each page request
now re-reads the newest page, counts the chapters added since, and places
freshly fetched chapters by their index from the first chapter.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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.

1 participant