Closed moo-the-cow closed 10 months ago
I mean it is clear that there is no correct json response, I suspect some 404 error page is shown, but I know too little about the parsing library. Thank you for your time
I've also been getting this JSON error. not always though. it might work for a while, then I try another stream and it won't work, then I try it again the next day it does work.
is there anything we can do to supply samples of the data we're receiving?
tried the following streams a few minutes ago (I don't watch any of these but I thought they would be good examples):
kick.com/devour kick.com/xqc kick.com/destiny kick.com/yassuo
(I noticed my streamlink and websocket-client are out of date compared to previous report, I'll update them but I doubt it matters)
[02:14:33.026134][cli][debug] OS: Windows 10
[02:14:33.027134][cli][debug] Python: 3.11.3
[02:14:33.028134][cli][debug] Streamlink: 5.5.1
[02:14:33.029135][cli][debug] Dependencies:
[02:14:33.031134][cli][debug] certifi: 2023.5.7
[02:14:33.032141][cli][debug] isodate: 0.6.1
[02:14:33.033133][cli][debug] lxml: 4.9.2
[02:14:33.035133][cli][debug] pycountry: 22.3.5
[02:14:33.036133][cli][debug] pycryptodome: 3.18.0
[02:14:33.037133][cli][debug] PySocks: 1.7.1
[02:14:33.039131][cli][debug] requests: 2.31.0
[02:14:33.040131][cli][debug] urllib3: 2.0.2
[02:14:33.041130][cli][debug] websocket-client: 1.5.2
[02:14:33.056126][cli][debug] Arguments:
[02:14:33.056126][cli][debug] url=kick.com/devour
[02:14:33.057125][cli][debug] --loglevel=all
[02:14:33.058125][cli][debug] --player="C:\Program Files\MPC-HC\mpc-hc64.exe"
[02:14:33.058125][cli][debug] --ffmpeg-ffmpeg=C:\Streamlink\ffmpeg\ffmpeg.exe
[02:14:33.059126][cli][info] Found matching plugin kick for URL kick.com/devour
[02:14:33.219220][plugins.kick][debug] Unable to validate result: ValidationError:
Unable to parse JSON: Expecting value: line 1 column 1 (char 0) ('<!DOCTYPE html><html lang="en-US"> ...)
error: No playable streams found on this URL: kick.com/devour
I've also been getting this JSON error. not always though. it might work for a while, then I try another stream and it won't work, then I try it again the next day it does work.
is there anything we can do to supply samples of the data we're receiving?
tried the following streams a few minutes ago (I don't watch any of these but I thought they would be good examples):
kick.com/devour kick.com/xqc kick.com/destiny kick.com/yassuo
(I noticed my streamlink and websocket-client are out of date compared to previous report, I'll update them but I doubt it matters)
[02:14:33.026134][cli][debug] OS: Windows 10 [02:14:33.027134][cli][debug] Python: 3.11.3 [02:14:33.028134][cli][debug] Streamlink: 5.5.1 [02:14:33.029135][cli][debug] Dependencies: [02:14:33.031134][cli][debug] certifi: 2023.5.7 [02:14:33.032141][cli][debug] isodate: 0.6.1 [02:14:33.033133][cli][debug] lxml: 4.9.2 [02:14:33.035133][cli][debug] pycountry: 22.3.5 [02:14:33.036133][cli][debug] pycryptodome: 3.18.0 [02:14:33.037133][cli][debug] PySocks: 1.7.1 [02:14:33.039131][cli][debug] requests: 2.31.0 [02:14:33.040131][cli][debug] urllib3: 2.0.2 [02:14:33.041130][cli][debug] websocket-client: 1.5.2 [02:14:33.056126][cli][debug] Arguments: [02:14:33.056126][cli][debug] url=kick.com/devour [02:14:33.057125][cli][debug] --loglevel=all [02:14:33.058125][cli][debug] --player="C:\Program Files\MPC-HC\mpc-hc64.exe" [02:14:33.058125][cli][debug] --ffmpeg-ffmpeg=C:\Streamlink\ffmpeg\ffmpeg.exe [02:14:33.059126][cli][info] Found matching plugin kick for URL kick.com/devour [02:14:33.219220][plugins.kick][debug] Unable to validate result: ValidationError: Unable to parse JSON: Expecting value: line 1 column 1 (char 0) ('<!DOCTYPE html><html lang="en-US"> ...) error: No playable streams found on this URL: kick.com/devour
It's because of cloudflare antibot. HTML response is a cloudflare security method to block access for bots. Sometimes it works better sometimes nah.
The solution might be use the nodejs with cloudscraper.
well I used python cloudscraper exactly as suggested for setup. elaborate on nodejs?
well I used python cloudscraper exactly as suggested for setup. elaborate on nodejs?
You need to change js interpreter for cloudscraper in script just like this: https://github.com/VeNoMouS/cloudscraper#javascript-engines-and-interpreters Don't know if it help, but might be a solution. Of course you need to have nodejs installed.
ok, I think I will keep it open until kick is doing better (they are not really developer friendly). when they are it probably needs re-work and then we can close the issue in my opinion.
OK the solution is to use https://github.com/lwthiker/curl-impersonate instead cloudcraper. I tested it and it works very well with kick. Similar project https://github.com/park-onezero/streamlink-plugin-kick-advanced also using it and works well.
that's great! thank you for the updates! I will close the issue now. depending on which implementation will get updates more frequently I decide which one to use (personally). Good to have options. I will try both
using the windows version installed the libs and also into the correct target plus put the plugin into the correct folder. are there any known issues at the moment? this is the verbose output (I obfuscated the streamer url)