mirror of
https://github.com/sigma67/ytmusicapi.git
synced 2026-04-25 07:16:00 +03:00
[GH-ISSUE #269] Search limit #209
Labels
No labels
a/b
bug
documentation
enhancement
good first issue
help wanted
invalid
pull-request
question
wontfix
yt-error
yt-update
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ytmusicapi#209
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Drimkaa on GitHub (Apr 15, 2022).
Original GitHub issue: https://github.com/sigma67/ytmusicapi/issues/269
Hi, can you explain how the search works with setting a limit? (I'm just trying to do something similar to node.js)
@sigma67 commented on GitHub (Apr 16, 2022):
Limit only works if you have some kind of filter (i.e.
songs). The default number of songs being returned is 20. If you set the limit value to a value higher than that, ytmusicapi will keep asking the server for continuations until your limit parameter is reached. So say you putlimit=50, it will return 60 song results.You can check the code below.
get_continuationsis a generic function that's being used by all methods that have continuation logic, so check that if you want to know how continuations work in general.github.com/sigma67/ytmusicapi@1d30910e23/ytmusicapi/mixins/browsing.py (L289-L298)@Drimkaa commented on GitHub (Apr 16, 2022):
Thanks, it helped.