mirror of
https://github.com/sigma67/ytmusicapi.git
synced 2026-04-25 07:16:00 +03:00
[GH-ISSUE #858] get_playlist ignores limit parameter and always returns max 100 tracks #525
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#525
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 @Hengen42 on GitHub (Jan 27, 2026).
Original GitHub issue: https://github.com/sigma67/ytmusicapi/issues/858
Checklist
Describe the bug
When calling
get_playlist()with a largelimitvalue, the API still returns only100tracks, even though the playlist contains significantly more items.The playlist metadata correctly reports the real track count via
trackCount, but thetracksarray is capped at100and does not paginate further.This makes it impossible to programmatically retrieve large playlists (e.g.
1000+ tracks) usingget_playlist()alone.ytmusicapi version
ytmusicapi 1.11.4(please adjust if needed)
To Reproduce
Steps to reproduce the behavior:
get_playlist()with a playlist containing more than100trackslimitvalue (e.g.5000)Example code
Output
Shown tracks: 100
Actual track count: 1527
Expected behavior
get_playlist()should either:limitparameter and fetch all tracks up to that limit using continuations, or100tracks and provide an official alternative for full playlist retrieval.Additional context
trackCount) correctly reports the full sizeThis limitation breaks automation use cases such as:
If this is a known limitation, clarification or guidance on the recommended approach would be appreciated.
@kipavy commented on GitHub (Jan 27, 2026):
I have also encountered this issue, the following code shows 100 tracks but the real playlist has 154 tracks
@sgvictorino commented on GitHub (Jan 28, 2026):
@Hengen42 does this only happen when you're authed? Is the playlist private?
@kipavy commented on GitHub (Jan 28, 2026):
It happened to me without being logged in, on a public playlist
@sgvictorino commented on GitHub (Jan 28, 2026):
@kipavy your issue should be fixed by #860
@kipavy commented on GitHub (Jan 28, 2026):
Thank you a lot, I hope ytmusicapi releases a hotfix soon on PyPi
@Hengen42 commented on GitHub (Jan 31, 2026):
Problem description
The issue still persists.
The important point here is not the ability to see the total track count — that part already works and can be obtained from the playlist metadata.
The real problem is that there is no way to retrieve the full track data as JSON for playlists larger than 100 items.
No matter what approach is used, the API always returns only the first 100 tracks, and there is currently no supported way to access the remaining tracks programmatically.
In other words, while the playlist may contain hundreds or even thousands of tracks, it is impossible to fetch all track objects (titles, artists, video IDs, etc.) as a complete JSON list. The limitation is always hard-capped at 100 items.
This means the core issue is data access, not track counting — and this issue has still not been resolved.
Explanation of the problem
If you print the
#print(tracks)line in the code as a normal statement instead of a comment, you will see that it still returns JSON data for only 100 tracks; this is where I want to point out that the actual issue lies.@sigma67 commented on GitHub (Jan 31, 2026):
Yeah sorry guys, I tried
provided by @kipavy and it's giving me back exactly 154 tracks.
Unfortunately OP did not provide any playlists for reproduction. So I'm going to mark this as invalid, unless you can provide more concrete instructions for reproduction.
And besides, we have plenty of tests testing with more than 100 limit tracks, so unless it's something specific to your account or playlist we would have seen it a long time ago if it was a general issue.
@Hengen42 commented on GitHub (Feb 4, 2026):
Yes, I want to state that I have solved the issue and provide feedback. In the problematic playlist, under the “Edit list” section, the “Voting” option must definitely be set to “Closed.” In the photo below, I showed where it needs to be corrected:

Also, as proof: the screenshot I obtained when my automatic backup program ran the day after changing only that setting:

@kipavy my friend, could you try it and let me know whether it’s resolved or not?
@sgvictorino commented on GitHub (Feb 4, 2026):
@Hengen42 thanks for troubleshooting this. I can tweak the parser so we return all the tracks when voting is enabled.
@sigma67 commented on GitHub (Feb 5, 2026):
That option seems new - we should create a separate issue to track it.