VideoHelp Forum


Try StreamFab Downloader and download from Netflix, Amazon, Youtube! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!


Try StreamFab Downloader and download streaming video from Youtube, Netflix, Amazon! Download free trial.


+ Reply to Thread
Results 1 to 2 of 2
Thread
  1. A quick rundown,...

    A folder called D:\YT_Rips\WKS-KEYS

    Inside this folder is pywidevine

    All scripts were working fine up until tonight, I was after a prog from STV,..
    My first attempt was to use a script called boltdnsnet.py (I gave up with it)
    I found a couple of scripts by Angela, called:
    stv_loader.py or stvgetter.py

    These worked great.

    but since downloading my files I was after a prog from CH5,... I have a script which I found from here, it removes 720p from URL (if required) to give 1080p.
    This is where my problem starts. ModuleNotFoundError: No module named 'pywidevine.L3'

    So I tried to do a pip install widevine from an admin command prompt, this seemed to work. but again the same error occured.
    I thought, okay uninstall widevine and reinstall to see if that would solve the problem.
    this is where it goes a bit weird,... widevine uninstalled fine... but when trying to reinstall with pip install widevine i get an error in red letters thats says:

    D:\YT_Rips\WKS-KEYS>pip uninstall pywidevine
    Found existing installation: pywidevine 1.6.0
    Uninstalling pywidevine-1.6.0:
    Would remove:
    c:\users\westhamboy\appdata\local\programs\python\ python311\lib\site-packages\pywidevine-1.6.0.dist-info\*
    c:\users\westhamboy\appdata\local\programs\python\ python311\lib\site-packages\pywidevine\*
    c:\users\westhamboy\appdata\local\programs\python\ python311\scripts\pywidevine.exe
    Proceed (Y/n)? y
    Successfully uninstalled pywidevine-1.6.0

    D:\YT_Rips\WKS-KEYS>pip install widevine
    ERROR: Could not find a version that satisfies the requirement widevine (from versions: none)
    ERROR: No matching distribution found for widevine

    I'm kind of at a loss through my blatant stupidity.

    edit: yes i can see my mistake... pip install widevine..... dohhh

    I actually thought that was going to solve my initial problem, but its still there, When i run ch5.py i get:

    D:\YT_Rips\WKS-KEYS>ch5.py
    Traceback (most recent call last):
    File "D:\YT_Rips\WKS-KEYS\CH5.py", line 7, in <module>
    from pywidevine.L3.cdm import deviceconfig
    ModuleNotFoundError: No module named 'pywidevine.L3' A probable wrong guess, but could it be because i'm running the scripts from within the WKS-KEYS folder, I can see line 7 which says "from pywidevine.L3.cdm import deviceconfig" so i'm guessing i've somehow screwed things up by running ch4 ch5 and itv script's all from the WKS-KEYS folder.

    I'm also getting the same error with my itv script which was fine yesterday,... now i'm getting the following:

    D:\YT_Rips\WKS-KEYS>itvx.py
    Traceback (most recent call last):
    File "D:\YT_Rips\WKS-KEYS\itvx.py", line 45, in <module>
    from pywidevine.L3.cdm import deviceconfig # no CDM? Comment out this line
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    ModuleNotFoundError: No module named 'pywidevine.L3'

    And the same error with my all4.py script. weeps,.... what the hell did i do ???

    okay... i read this from angela: https://forum.videohelp.com/threads/410098-Problem-with-wks-keys#post2694513

    all of my folders had __init__.py within L3 and lower,... but there was not an __init__.py within the pywidevine folder itself. so i added one.

    getting there. but now it seems to have got worse,... i tried running my all4.py script which failed before but now i'm getting this:

    D:\YT_Rips\WKS-KEYS>all4.py
    Traceback (most recent call last):
    File "D:\YT_Rips\WKS-KEYS\all4.py", line 10, in <module>
    from pywidevine.L3.decrypt.wvdecryptcustom import WvDecrypt
    File "D:\YT_Rips\WKS-KEYS\pywidevine\L3\decrypt\wvdecryptcustom.py", line 6, in <module>
    from pywidevine.L3.cdm import cdm, deviceconfig
    File "D:\YT_Rips\WKS-KEYS\pywidevine\L3\cdm\cdm.py", line 10, in <module>
    from pywidevine.L3.cdm.formats import wv_proto2_pb2 as wv_proto2
    File "D:\YT_Rips\WKS-KEYS\pywidevine\L3\cdm\formats\wv_proto2_pb2.py", line 33, in <module>
    _descriptor.EnumValueDescriptor(
    File "C:\Users\**********\AppData\Local\Programs\Python \Python311\Lib\site-packages\google\protobuf\descriptor.py", line 755, in __new__
    _message.Message._CheckCalledFromGeneratedFile()
    TypeError: Descriptors cannot not be created directly.
    If this call came from a _pb2.py file, your generated code is out of date and must be regenerated with protoc >= 3.19.0.
    If you cannot immediately regenerate your protos, some other possible workarounds are:
    1. Downgrade the protobuf package to 3.20.x or lower.
    2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).

    More information: https://developers.google.com/protocol-buffers/docs/news/2022-05-06#python-updates

    I read somewhere about downgrading protoc,..... (I have been doing a lot of reading, sorry) but cannot remember where.... could this be the cause of the problem, and get things back to normal???
    Last edited by LastResort; 24th Sep 2023 at 00:36. Reason: typo
    Quote Quote  
  2. I have it all back working...... somehow, and i do not know how, but __init__.py was missing from pywidevine folder,... and i had to downgrade protobuf. itv is fine,.. but the only one i'm having problems with is ch5.

    the version number to the script is
    #### version 20230205-1
    #### version 20230816-1 remove 720p from URL (if required) to give 1080p


    example:
    https://www.channel5.com/show/wayne-couzens-killer-in-plain-sight

    https://akadash0.akamaized.net/hydra/C5428660001/C5428660001B/20230615143136/C54286600...f59509429df%22

    i tried removing _SD-tt

    https://akadash0.akamaized.net/hydra/C5428660001/C5428660001B/20230615143136/C54286600...f59509429df%22

    requests lic url

    2 appear:

    https://cassie.channel5.com/api/v2/licences/widevine/491/C5428660001?expiry=1695546085...24%22%2Cst%3Dv

    https://cassie.channel5.com/api/v2/licences/widevine/491/C5428660001?expiry=1695546085...24%22%2Cst%3Dv

    using the second and adding it to cmd prompt request:

    PSSH is AAAAMnBzc2gAAAAA7e+LqXnWSs6jyCfc1R0h7QAAABISEM+LYc edv0pgssQAUSEtJJM=
    KID:KEY found is cf8b61c79dbf4a60b2c40051212d2493:79cf271f2fe155f49 f07c0c2a6d580f7
    KEY# is 79cf271f2fe155f49f07c0c2a6d580f7



    WARNING: You have asked for UNPLAYABLE formats to be listed/downloaded. This is a developer option intended for debugging.
    If you experience any issues while using this option, DO NOT open a bug report
    [generic] Extracting URL: https://akadash0.akamaized.net/hydra/C5428660001/C5428660001B/20230615143136/C54286600...f59509429df%22
    [generic] C5428660001: Downloading webpage
    WARNING: [generic] Falling back on generic information extractor
    [generic] C5428660001: Extracting information
    [info] C5428660001: Downloading 1 format(s): 1
    [download] encryptVid.mp4 has already been downloaded
    [download] 100% of 9.04KiB

    What do you want to call your final file? (do not include file .extension like .mp4) (lets call it "jim")

    What do you want to call your final file? (do not include file .extension like .mp4) jim
    ffmpeg version n3.4.5-g87c165c237+355 Copyright (c) 2000-2018 the FFmpeg developers
    built with gcc 7.4.0 (Rev1, Built by MSYS2 project)
    configuration: --enable-bzlib --enable-d3d11va --enable-dxva2 --enable-lzma --enable-nvenc --enable-zlib --disable-debug --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-fontconfig --enable-libass --enable-libbluray --enable-libfreetype --enable-libmfx --enable-libopenjpeg --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libwavpack --enable-libwebp --enable-libshine --enable-gpl --enable-avisynth --enable-libxvid --enable-libssh --enable-network --enable-decklink --enable-librtmp --enable-openssl --extra-cflags=-DLIBTWOLAME_STATIC --extra-cflags=-DLIBSSH_STATIC --extra-ldflags='-Wl,--allow-multiple-definition' --enable-nonfree
    libavutil 55. 78.100 / 55. 78.100
    libavcodec 57.107.100 / 57.107.100
    libavformat 57. 83.100 / 57. 83.100
    libavdevice 57. 10.100 / 57. 10.100
    libavfilter 6.107.100 / 6.107.100
    libswscale 4. 8.100 / 4. 8.100
    libswresample 2. 9.100 / 2. 9.100
    libpostproc 54. 7.100 / 54. 7.100
    [mov,mp4,m4a,3gp,3g2,mj2 @ 06263ec0] Format mov,mp4,m4a,3gp,3g2,mj2 detected only with low score of 1, misdetection possible!
    [mov,mp4,m4a,3gp,3g2,mj2 @ 06263ec0] moov atom not found
    video_decrypt.mp4: Invalid data found when processing input
    Traceback (most recent call last):
    File "D:\YT_Rips\WKS-KEYS\CH5.py", line 113, in <module>
    os.rename("mux_file.mp4", f'{output_name}')
    FileNotFoundError: [WinError 2] The system cannot find the file specified: 'mux_file.mp4' -> 'jim.mp4'


    any clues please chaps??

    I'll try the updated d e ccavox version from https://forum.videohelp.com/threads/410822-My5-(Channel-5)#post2705627

    maybe ch5 has changed again... can anyone check to see if this is working please..

    okay... for some unknown reason firefox is the only way i can get it to work using the old ch5 script with copy and paste the mpd onto a text file then removing the _SD-tt before re-copying and pasting into cmd prompt.
    Last edited by LastResort; 24th Sep 2023 at 03:08. Reason: edit
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!