Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[YouTube] Trends are not returned sometimes #1046

Closed
AudricV opened this issue Apr 2, 2023 · 0 comments · Fixed by #1045
Closed

[YouTube] Trends are not returned sometimes #1046

AudricV opened this issue Apr 2, 2023 · 0 comments · Fixed by #1045
Labels
bug Issue is related to a bug youtube service, https://www.youtube.com/

Comments

@AudricV
Copy link
Member

AudricV commented Apr 2, 2023

YouTube is A/B testing a new trending UI which completely reworks what data is sent and how it is displayed. This new structure is currently not supported by the extractor.

Here is a screenshot of the new UI in French:

yt_new_trending_ui

With this UI, the Recently trending section is removed and the trending videos section has now a title (Trending videos), which makes the current code returning no items, as the current/previous UI returned no title for trending videos but one for recently trending videos and shorts.

Here is how looks the new videos trending data structure which is now returned (some fields have been omitted):

{
    "itemSectionRenderer": {
        "contents": [
            {
                "shelfRenderer": {
                    "title": {
                        "runs": [
                            {
                                "text": "Trending videos"
                            }
                        ]
                    },
                    "endpoint": {
                        "commandMetadata": {
                            "webCommandMetadata": {
                                "url": "/feed/trending?bp=4gIOGgxtb3N0X3BvcHVsYXI%3D",
                                "webPageType": "WEB_PAGE_TYPE_BROWSE",
                                "rootVe": 6827,
                                "apiUrl": "/youtubei/v1/browse"
                            }
                        },
                        "browseEndpoint": {
                            "browseId": "FEtrending",
                            "params": "4gIOGgxtb3N0X3BvcHVsYXI%3D"
                        }
                    },
                    "content": {
                        "horizontalListRenderer": {
                            "items": [
                                {
                                    "gridVideoRenderer": {
                                        // A gridVideoRenderer without description
                                    }
                                },
                                // Other gridVideoRenderers
                            ]
                        }
                    }
                }
            }
        ]
    }
}

In this A/B test, a new trending tab called Videos has been added and replaces the Now tab. It returns only the trending videos without anything else and is accessible with a browse request on the InnerTube API with the FEtrending browseId and the parameters 4gIOGgxtb3N0X3BvcHVsYXI%3D (a protobuf object which means as a raw value 44 { 3: "most_popular"}).

This tab works regardless of the inclusion of the request in the A/B test.

Video items on this tab contains their description like on the current/previous UI and on search results.

Reproduce rate of this A/B test is very low right now (1 or 2% in my region at the time this issue is written).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue is related to a bug youtube service, https://www.youtube.com/
Projects
None yet
1 participant