[GH-ISSUE #633] search: playlistId always returns None on albums #430

Closed
opened 2026-02-27 23:00:45 +03:00 by kerem · 1 comment
Owner

Originally created by @sushiroles on GitHub (Jul 28, 2024).
Original GitHub issue: https://github.com/sigma67/ytmusicapi/issues/633

When using the search function to search for albums, ytmusicapi returns the playlistId value as None.
This occurs for all albums under the "Albums" category, weirdly albums in the "Top result" category are exempt from this.
Aside playlist ID-s, they're also missing durations.

I am using a computer running Windows 11 version 23H2.
I am using the newest version of ytmusicapi, which is at the time of writing 1.8.0.
Issue persists on both authenticated and unauthenticated instances.

Here is a snippet of the JSON returned after running ytmusic.search('radiohead album') to illustrate my issue:

[
    {
        "category": "Top result",
        "resultType": "album",
        "videoId": null,
        "videoType": null,
        "title": "In Rainbows",
        "artists": [
            {
                "name": "Radiohead",
                "id": "UCr_iyUANcn9OX_yy9piYoLw"
            }
        ],
        "browseId": "MPREb_R6C9lU4QEg2",
        "playlistId": "OLAK5uy_m59x-hBFsC789l1_qWwFXwH3gjntwy_CA",
        "thumbnails": [
            {
                "url": "https://lh3.googleusercontent.com/BAl1FqoDaFrpWSSrr95Yjii4fJSeitdRcVt7f-uOVrhxQfmo5ActMNysFErQfI-CiOZR4GH2fePoVQtd=w60-h60-l90-rj",
                "width": 60,
                "height": 60
            },
            {
                "url": "https://lh3.googleusercontent.com/BAl1FqoDaFrpWSSrr95Yjii4fJSeitdRcVt7f-uOVrhxQfmo5ActMNysFErQfI-CiOZR4GH2fePoVQtd=w120-h120-l90-rj",
                "width": 120,
                "height": 120
            },
            {
                "url": "https://lh3.googleusercontent.com/BAl1FqoDaFrpWSSrr95Yjii4fJSeitdRcVt7f-uOVrhxQfmo5ActMNysFErQfI-CiOZR4GH2fePoVQtd=w226-h226-l90-rj",
                "width": 226,
                "height": 226
            },
            {
                "url": "https://lh3.googleusercontent.com/BAl1FqoDaFrpWSSrr95Yjii4fJSeitdRcVt7f-uOVrhxQfmo5ActMNysFErQfI-CiOZR4GH2fePoVQtd=w544-h544-l90-rj",
                "width": 544,
                "height": 544
            }
        ]
    },
    {
        "category": "Albums",
        "resultType": "album",
        "title": "Kid A",
        "type": "Album",
        "duration": null,
        "year": "2000",
        "artists": [
            {
                "name": "Radiohead",
                "id": "UCr_iyUANcn9OX_yy9piYoLw"
            }
        ],
        "browseId": "MPREb_ob5cslgCNc0",
        "isExplicit": false,
        "playlistId": null,
        "thumbnails": [
            {
                "url": "https://lh3.googleusercontent.com/yJLXG7QJySOUp57Nff9te1cqhRqvz9BHusWk8c9ek08m-DRv5TJhCqW0HV2tAk5K2ErChBlHEUeFfGt_6A=w60-h60-l90-rj",
                "width": 60,
                "height": 60
            },
            {
                "url": "https://lh3.googleusercontent.com/yJLXG7QJySOUp57Nff9te1cqhRqvz9BHusWk8c9ek08m-DRv5TJhCqW0HV2tAk5K2ErChBlHEUeFfGt_6A=w120-h120-l90-rj",
                "width": 120,
                "height": 120
            },
            {
                "url": "https://lh3.googleusercontent.com/yJLXG7QJySOUp57Nff9te1cqhRqvz9BHusWk8c9ek08m-DRv5TJhCqW0HV2tAk5K2ErChBlHEUeFfGt_6A=w226-h226-l90-rj",
                "width": 226,
                "height": 226
            },
            {
                "url": "https://lh3.googleusercontent.com/yJLXG7QJySOUp57Nff9te1cqhRqvz9BHusWk8c9ek08m-DRv5TJhCqW0HV2tAk5K2ErChBlHEUeFfGt_6A=w544-h544-l90-rj",
                "width": 544,
                "height": 544
            }
        ]
    },
...
Originally created by @sushiroles on GitHub (Jul 28, 2024). Original GitHub issue: https://github.com/sigma67/ytmusicapi/issues/633 When using the search function to search for albums, ytmusicapi returns the playlistId value as None. This occurs for all albums under the "Albums" category, weirdly albums in the "Top result" category are exempt from this. Aside playlist ID-s, they're also missing durations. I am using a computer running Windows 11 version 23H2. I am using the newest version of ytmusicapi, which is at the time of writing 1.8.0. Issue persists on both authenticated and unauthenticated instances. Here is a snippet of the JSON returned after running `ytmusic.search('radiohead album')` to illustrate my issue: ``` [ { "category": "Top result", "resultType": "album", "videoId": null, "videoType": null, "title": "In Rainbows", "artists": [ { "name": "Radiohead", "id": "UCr_iyUANcn9OX_yy9piYoLw" } ], "browseId": "MPREb_R6C9lU4QEg2", "playlistId": "OLAK5uy_m59x-hBFsC789l1_qWwFXwH3gjntwy_CA", "thumbnails": [ { "url": "https://lh3.googleusercontent.com/BAl1FqoDaFrpWSSrr95Yjii4fJSeitdRcVt7f-uOVrhxQfmo5ActMNysFErQfI-CiOZR4GH2fePoVQtd=w60-h60-l90-rj", "width": 60, "height": 60 }, { "url": "https://lh3.googleusercontent.com/BAl1FqoDaFrpWSSrr95Yjii4fJSeitdRcVt7f-uOVrhxQfmo5ActMNysFErQfI-CiOZR4GH2fePoVQtd=w120-h120-l90-rj", "width": 120, "height": 120 }, { "url": "https://lh3.googleusercontent.com/BAl1FqoDaFrpWSSrr95Yjii4fJSeitdRcVt7f-uOVrhxQfmo5ActMNysFErQfI-CiOZR4GH2fePoVQtd=w226-h226-l90-rj", "width": 226, "height": 226 }, { "url": "https://lh3.googleusercontent.com/BAl1FqoDaFrpWSSrr95Yjii4fJSeitdRcVt7f-uOVrhxQfmo5ActMNysFErQfI-CiOZR4GH2fePoVQtd=w544-h544-l90-rj", "width": 544, "height": 544 } ] }, { "category": "Albums", "resultType": "album", "title": "Kid A", "type": "Album", "duration": null, "year": "2000", "artists": [ { "name": "Radiohead", "id": "UCr_iyUANcn9OX_yy9piYoLw" } ], "browseId": "MPREb_ob5cslgCNc0", "isExplicit": false, "playlistId": null, "thumbnails": [ { "url": "https://lh3.googleusercontent.com/yJLXG7QJySOUp57Nff9te1cqhRqvz9BHusWk8c9ek08m-DRv5TJhCqW0HV2tAk5K2ErChBlHEUeFfGt_6A=w60-h60-l90-rj", "width": 60, "height": 60 }, { "url": "https://lh3.googleusercontent.com/yJLXG7QJySOUp57Nff9te1cqhRqvz9BHusWk8c9ek08m-DRv5TJhCqW0HV2tAk5K2ErChBlHEUeFfGt_6A=w120-h120-l90-rj", "width": 120, "height": 120 }, { "url": "https://lh3.googleusercontent.com/yJLXG7QJySOUp57Nff9te1cqhRqvz9BHusWk8c9ek08m-DRv5TJhCqW0HV2tAk5K2ErChBlHEUeFfGt_6A=w226-h226-l90-rj", "width": 226, "height": 226 }, { "url": "https://lh3.googleusercontent.com/yJLXG7QJySOUp57Nff9te1cqhRqvz9BHusWk8c9ek08m-DRv5TJhCqW0HV2tAk5K2ErChBlHEUeFfGt_6A=w544-h544-l90-rj", "width": 544, "height": 544 } ] }, ... ```
kerem 2026-02-27 23:00:45 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@sigma67 commented on GitHub (Jul 28, 2024):

Good catch, it's actually available

The reason it works for top results is that the parsing is different there. As you can tell from the UI the return format is totally different

<!-- gh-comment-id:2254629945 --> @sigma67 commented on GitHub (Jul 28, 2024): Good catch, it's actually available The reason it works for top results is that the parsing is different there. As you can tell from the UI the return format is totally different
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/ytmusicapi#430
No description provided.