NewPipeExtractor icon indicating copy to clipboard operation
NewPipeExtractor copied to clipboard

[YouTube] Add fallback to system playlists when fetching age-restricted stream channel tabs directly

Open AudricV opened this issue 2 years ago • 1 comments

This PR adds support of the channel tabs fallback to system YouTube upload playlists when fetching directly Videos, Shorts or Live tabs of an age-restricted channel.

It makes the data returned in this case consistent as the ones returned when getting the data of tabs got from a YouTube ChannelExtractor instance.

If other tabs are requested directly, no items will be returned, like before this PR.

I updated the corresponding Shorts tab test, which fetches now directly the tabs, and added a Videos tab test which do so too.

I also kept the test using the original behavior of fetching the Videos channel tab from the channel tabs got by a ChannelExtractor instance, in order to ensure both approaches work properly.

As the Videos tab tests expect the same data, I put the common code of these two test classes inside an abstract test class.

I also removed unneeded test method overrides in YoutubeChannelTabExtractorTest, and updated the channel tabs tests' mocks.

AudricV avatar Aug 30 '23 17:08 AudricV

any reason why this PR was not merged?

TobiGr avatar Jul 22 '24 09:07 TobiGr