Skip to content

Add CLI resume and crawl rate limit options#3105

Merged
dipu-bd merged 4 commits into
lncrawl:devfrom
HaProxyMage:dev
Jul 13, 2026
Merged

Add CLI resume and crawl rate limit options#3105
dipu-bd merged 4 commits into
lncrawl:devfrom
HaProxyMage:dev

Conversation

@HaProxyMage

@HaProxyMage HaProxyMage commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Add CLI resume and crawl rate limit options

Type of change

  • Bug fix
  • New source
  • Feature / enhancement
  • Docs / chore

Details

Add --resume / --missing to the CLI crawl command to download only chapters that are not marked as downloaded.
Add --refresh to force re-downloading selected chapters.
Add --rate-limit to override the crawler task rate for a single CLI crawl run.

The crawler services already skip available chapters and the scheduler already supports fetching missing chapters, but the non-interactive CLI did not expose that behavior clearly. This makes interrupted downloads easier to continue and gives users a per-run throttle without editing crawler source code.

Checklist

  • make lint passes with no errors
  • Tested manually (crawl command or server)

@dipu-bd dipu-bd left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good. Thanks for taking up this task. I will wait for further clarification on the resume option before merging it

metavar="N",
help="Download latest few chapters",
),
resume: bool = typer.Option(

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why add an explicit resume since the default behavior of the crawl command is to resume the download?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah I understand, you are not even fetching the list of chapters that is marked with is_crawled True

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Exactly. That keeps the progress bar and queued task count focused on only missing chapters, which is especially useful for large novels or interrupted downloads. The default behavior remains unchanged.

@dipu-bd
dipu-bd merged commit 47dad37 into lncrawl:dev Jul 13, 2026
6 checks passed
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.

2 participants