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] Fix extraction of Shorts in channels and remove visitor data usage #1221

Merged
merged 3 commits into from
Sep 29, 2024

Conversation

AudricV
Copy link
Member

@AudricV AudricV commented Sep 12, 2024

This PR fixes the extraction of Shorts in their channel tab due to a new UI element being rolled-out replacing the reelItemRenderer, shortsLockupViewModel. It doesn't provide more information than a reelItemRenderer.

It also removes the usage of a visitor data in continuations of Shorts channel tabs, which used to be mandatory to get valid continuations with more Shorts. It isn't the case anymore, and the visitor data wasn't used since 5a6da5f, due to a lack of an index update with the channel IDs changes in this commit (the channel verified status was used instead).

The method prepareDesktopJsonBuilder of YoutubeParsingHelper with the visitor data argument isn't now used directly, but has been kept for now as it is (it will be very likely used with the PoToken changes for streaming URLs).

Due to these visitor data changes, the mocks of YoutubeChannelTabExtractorTest.Shorts test class had to be updated.

Fixes TeamNewPipe/NewPipe#11554.

This new UI data type is replacing the reelItemRenderer one.
It isn't required anymore and not used by extractor anymore since commit
5a6da5f, as the wrong page ID is used as a
visitor data (the VerifiedStatus value as a string).
@AudricV AudricV added bug Issue is related to a bug youtube service, https://www.youtube.com/ labels Sep 12, 2024
@AudricV AudricV changed the title [YouTube] Fix extraction of Shorts in channels and Shorts-only playlists and remove visitor data usage [YouTube] Fix extraction of Shorts in channels and remove visitor data usage Sep 12, 2024
Copy link
Member

@Stypox Stypox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks good to me, although I didn't test. Thank you!

@mrkrabs206

This comment was marked as off-topic.

@AudricV AudricV merged commit 596bce2 into TeamNewPipe:dev Sep 29, 2024
3 of 4 checks passed
@AudricV AudricV deleted the yt_support-new-shorts-ui-data branch September 29, 2024 12:54
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
Development

Successfully merging this pull request may close these issues.

Shorts not being shown in its channels tab
3 participants