anxdpanic / plugin.video.youtube

Watch your favorite YouTube content on Kodi
https://ytaddon.panicked.xyz/forum
691 stars 114 forks source link

Purchased movies stop after about 5 minutes #35

Closed MartChic closed 7 months ago

MartChic commented 4 years ago

Context

Please provide any relevant information about your setup


Expected Behavior

Purchased movies should play normally.


Current Behavior

As the title says, purchased movies stop after about 5 minutes. All other videos play fine.


Steps to Reproduce

Please provide detailed steps for reproducing the issue.

  1. Purchase movie on Youtube
  2. Play with with the Youtube extension.

Log

https://drive.google.com/file/d/1unGGfOnqNmZvEzyAlFmnle4IR81Wy9Ls/view?usp=sharing 01_KODI.log


Additional Information

Please provide any additional information that may be helpful.


MisterD81 commented 3 years ago

I have the same issue on Windows and LibreElec RPi. But I was not able to reproduce it on Linux x64. So I took a look at it and the issue is from my understanding not in the YT addon. The license expires after 5 minutes and inputstream.adaptive is not renewing the license. I could see in the EME logger that CDM is triggering this event, but it was not triggered in inputstream.adaptive. I managed to modify inputstream.adaptive so that also there the license renewal is triggered, since the main code was already there but commented out. After that for me the playback worked. If I find the time the next days I will create a PR for inputstream.adaptive.

MartChic commented 3 years ago

Great! Could you tell which lines need to be commented out?

MisterD81 commented 3 years ago

In inputstream.adaptive addon you need to find the file:

  1. wvdecrypter/cdm/media/cdm/cdm_adapter.cc
  2. wvdecrypter/wvdecrypter.cpp

In both files there are lines that start with: "//LICENSERENEWAL: ". If you remove this part and compile the addon the playback started to work for me. But when you stop the playback Kodi will crash. There are some more additions required so that Kodi does not crash. I still need to some more testing before I can create the PR.

MisterD81 commented 3 years ago

Finally I was able to test the changes successfully on the "production" system at home. Therefor I have created the two PRs for Matrix and Leia.

MartChic commented 3 years ago

Did you fix the crash on stop issue?

MisterD81 commented 3 years ago

Yes. There are some additions as mentioned previously required so that every is cleaned when playback stops.