Repository navigation
Backfill more than one page of an account's posts - #232
Merged
Merged
Conversation
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.
Closes #203.
Adds
max_posts_per_account, defaulting to 40 — one page, which is what we fetch today — so nothing changes for anyone who doesn't set it.Please note that every post fetched costs a
search?resolve=trueon your own instance, plus a context fetch whenbackfill-with-contextis on.This means that setting
max_posts_per_accountto a high value will really slow down backfilling, as you are likely to hit your own server's rate limits.All four clients now page: Mastodon by
max_id, Misskey byuntilId, Lemmy by page number, PeerTube bystart/count. Each stops early when a server hands back less than it was asked for, so an account with fewer posts than the limit still costs a single request.