NewPipeExtractor icon indicating copy to clipboard operation
NewPipeExtractor copied to clipboard

[YouTube] New regex for player throttling function

Open ow-ro opened this issue 1 year ago • 0 comments

yt-dlp reference: https://github.com/yt-dlp/yt-dlp/pull/10611

As of today seeing new JS players referenced 20dfca59 and d2e656ee on age-restricted videos which fail.

Fix is working for me on the 2 new and past b22ef6e7 hash. Could not get the new regex to work in the same way as the others in the DEOBFUSCATION_FUNCTION_NAME_REGEXES array with matcher.group(1)/matcher.group(2) for func name/array index. Therefore the fix I have is likely problematic and may not be compatible with untested player hashes. Hopefully someone can improve on this. Seems to me a couple of better options would be:

  • make new regex work with current matcher.group(1)/matcher.group(2) format, if possible
  • use named groups rather than hardcoded group indexes

or alternatively just split this new regex up from the others in some other way.

ow-ro avatar Aug 01 '24 02:08 ow-ro