Closed Jool-Pi closed 3 years ago
i see a lot of timeouts something not works in your system do not know what
sugest you to try update librelec with latest hotfix
I think I am experiencing a similar issue. I sometimes see timeouts and errors, and afterwards the addon will not respond anymore until I restart Kodi.
Here are a couple of examples of the timeouts I saw:
2020-11-01 00:07:11.896 T:1200800640 ERROR: [plugin.video.netflix (3)] Traceback (most recent call last):
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/run_addon.py", line 32, in wrapper
func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/run_addon.py", line 254, in run
success = route(pathitems)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/run_addon.py", line 89, in lazy_login_wrapper
return func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/run_addon.py", line 128, in route
_execute(nav_handler, pathitems[1:], G.REQUEST_PARAMS, root_handler)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/run_addon.py", line 156, in _execute
executor(pathitems=pathitems)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/utils/logging.py", line 164, in timing_wrapper
return func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/common/videoid.py", line 313, in wrapper
return func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/navigation/directory.py", line 116, in show
self._seasons(videoid, pathitems)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/navigation/directory.py", line 125, in _seasons
list_data, extra_data = common.make_call('get_seasons', call_args)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/utils/logging.py", line 164, in timing_wrapper
return func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/common/ipc.py", line 87, in make_call
return make_http_call(callname, data)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/common/ipc.py", line 106, in make_http_call
urlopen(url=url, data=json.dumps(data).encode('utf-8'), timeout=IPC_TIMEOUT_SECS).read(),
File "/usr/lib/python2.7/urllib2.py", line 154, in urlopen
File "/usr/lib/python2.7/urllib2.py", line 429, in open
File "/usr/lib/python2.7/urllib2.py", line 447, in _open
File "/usr/lib/python2.7/urllib2.py", line 407, in _call_chain
File "/usr/lib/python2.7/urllib2.py", line 1228, in http_open
File "/usr/lib/python2.7/urllib2.py", line 1201, in do_open
File "/usr/lib/python2.7/httplib.py", line 1121, in getresponse
File "/usr/lib/python2.7/httplib.py", line 438, in begin
File "/usr/lib/python2.7/httplib.py", line 394, in _read_status
File "/usr/lib/python2.7/socket.py", line 480, in readline
timeout: timed out
...
2020-11-01 00:23:54.137 T:1329382272 ERROR: [plugin.video.netflix (0)] IPC callback raised exception: HTTPSConnectionPool(host='www.netflix.com', port=443): Read timed out. (read timeout=None)
2020-11-01 00:23:54.163 T:1329382272 ERROR: [plugin.video.netflix (0)] Traceback (most recent call last):
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/common/ipc.py", line 212, in _perform_ipc_return_call
result = _call(func, data)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/common/ipc.py", line 250, in _call
return func(**data)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/utils/logging.py", line 164, in timing_wrapper
return func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/services/nfsession/directorybuilder/dir_builder.py", line 72, in get_seasons
season_list = self.req_seasons(tvshowid, perpetual_range_start=perpetual_range_start)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/common/cache_utils.py", line 84, in wrapper
output = func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/services/nfsession/directorybuilder/dir_path_requests.py", line 118, in req_seasons
path_response = self.nfsession.perpetual_path_request(**call_args)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/utils/logging.py", line 164, in timing_wrapper
return func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/services/nfsession/session/path_requests.py", line 77, in perpetual_path_request
path_response = self.path_request(_set_range_selector(paths, range_start, range_end))
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/utils/logging.py", line 164, in timing_wrapper
return func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/services/nfsession/session/path_requests.py", line 37, in path_request
data=data)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/services/nfsession/session/access.py", line 91, in post_safe
return self.post(endpoint, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/services/nfsession/session/http_requests.py", line 45, in post
**kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/utils/logging.py", line 164, in timing_wrapper
return func(*args, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/services/nfsession/session/http_requests.py", line 49, in _request_call
return self._request(method, endpoint, None, **kwargs)
File "/storage/.kodi/addons/plugin.video.netflix/resources/lib/services/nfsession/session/http_requests.py", line 65, in _request
data=data)
File "/storage/.kodi/addons/script.module.requests/lib/requests/sessions.py", line 581, in post
return self.request('POST', url, data=data, json=json, **kwargs)
File "/storage/.kodi/addons/script.module.requests/lib/requests/sessions.py", line 533, in request
resp = self.send(prep, **send_kwargs)
File "/storage/.kodi/addons/script.module.requests/lib/requests/sessions.py", line 646, in send
r = adapter.send(request, **kwargs)
File "/storage/.kodi/addons/script.module.requests/lib/requests/adapters.py", line 529, in send
raise ReadTimeout(e, request=request)
ReadTimeout: HTTPSConnectionPool(host='www.netflix.com', port=443): Read timed out. (read timeout=None)
Later, when I try to play a video (at least I think this is what happened):
2020-11-01 06:15:20.133 T:1655833472 DEBUG: CWebServer[8080]: request received for /jsonrpc
2020-11-01 06:15:20.349 T:1937084432 DEBUG: Previous line repeats 1 times.
2020-11-01 06:15:20.349 T:1937084432 DEBUG: ------ Window Deinit (DialogConfirm.xml) ------
2020-11-01 06:15:20.376 T:1444967296 ERROR: GetDirectory - Error getting plugin://plugin.video.netflix/directory/show/80049832/
2020-11-01 06:15:20.376 T:1444967296 DEBUG: Thread waiting 1444967296 terminating
2020-11-01 06:15:20.376 T:1200800640 INFO: CPythonInvoker(16, /storage/.kodi/addons/plugin.video.netflix/addon.py): script successfully run
2020-11-01 06:15:20.377 T:1200800640 DEBUG: onExecutionDone(16, /storage/.kodi/addons/plugin.video.netflix/addon.py)
2020-11-01 06:15:20.409 T:1937084432 DEBUG: ------ Window Deinit (DialogBusy.xml) ------
2020-11-01 06:15:20.419 T:1937084432 ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.netflix/directory/show/80049832/) failed
2020-11-01 06:15:20.420 T:1937084432 DEBUG: CGUIMediaWindow::GetDirectory ()
2020-11-01 06:15:20.420 T:1937084432 DEBUG: ParentPath = [plugin://plugin.video.netflix/directory/show/80049832/]
2020-11-01 06:15:20.515 T:1444967296 DEBUG: Thread waiting start, auto delete: false
2020-11-01 06:15:20.520 T:1444967296 DEBUG: Thread waiting 1444967296 terminating
2020-11-01 06:15:20.555 T:1444967296 DEBUG: Thread BackgroundLoader start, auto delete: false
2020-11-01 06:15:20.575 T:1444967296 DEBUG: Thread BackgroundLoader 1444967296 terminating
2020-11-01 06:15:20.655 T:1200800640 INFO: Python interpreter stopped
2020-11-01 06:15:20.655 T:1200800640 DEBUG: Thread LanguageInvoker 1200800640 terminating
This is with LibreELEC 9.2.4. I'll try installing the hotfix and check again.
It seems like the LibreELEC 9.2.5 hotfix is only for Raspberry Pi 4, and I have a 3B.
this problem depends on some external factor, so is not inherent to the source code i do not know how to help you
it is started after a libreElec update? what could be changed in your system?
you can verify one thing, if in your country there have been changes in the website the addon could not working in other machine, This can be done by installing kodi and the addon on a personal computer, and see if run correctly or not, and also try change temporary the DNS
it is started after a libreElec update? what could be changed in your system?
It started about two weeks ago. I don't think there was any LibreELEC update.
you can verify one thing, if in your country there have been changes in the website the addon could not working in other machine, This can be done by installing kodi and the addon on a personal computer
Thanks for the suggestion, I'll try on another machine and compare.
also try change temporary the DNS
I will.
this problem depends on some external factor, so is not inherent to the source code
I understand that you can't solve connectivity issues of course :) But is it possible that some connection error causes the addon to crash in a way that it cannot recover from without restarting?
good let me know
But is it possible that some connection error causes the addon to crash in a way that it cannot recover from without restarting?
The addon service instance and the addon instance are already protected by any exceptions I just tried to emulate the exception by manually raising the ReadTimeout at same point and the addon still works as expected (tried also to force timeout to Request module nothing changed, so still works)
but when Kodi crash internally no way to restore
HI,
sugest you to try update librelec with latest hotfix
I reinstalled Kodi on Pi. It was already version 18.9 of Kodi (vs 18.8 when posting the original post) same error persist. I can watch one video. After that there is an error and only restart Kodi or reinstall add on fix the issue.
also try change temporary the DNS
I tried using Google's DNS (8.8.8.8) but the problem remains.
I also noticed that disabling and re-enabling the addon also allows watching a new video. @Jool-Pi is that what you meant when you said "Reinstall the add on before watching each video" is a possible fix?
I also noticed that disabling and re-enabling the addon also allows watching a new video. @Jool-Pi is that what you meant when you said "Reinstall the add on before watching each video" is a possible fix?
I use the update option. basically from the add on information page I choose to update (to the same version). I suppose by doing that it does kinda of reinstall. I didn't try enable disable option you are referring to.
Same issue here on: Ubuntu 20.04.1 Kodi 18.9 Netflix 1.10.1
I'm sorry but I cannot provide the debug log in the next days.
I have exactly the same problem. It appeared on Retropie (based on Debian 9 Stretch) with Kodi 18.2. Few days ago I did fresh Retropie install, newest version based on Debian 10, with Kodi 18.7 and the problem still exist. Plugin version: 1.10.1
saying it doesn't work without publishing a debug log doesn't help anyone...
saying it doesn't work without publishing a debug log doesn't help anyone...
I will try to post the new log of my error tomorrow
Sorry for the delay, here the log: https://gist.github.com/elbowz/5600fc92b795e6e58a1f9b1e32b2b3c7 The use of gist was due pasebin size limit...I hope could be good.
The log is cut off in the middle, stripping out some verbose information (make me know if you need).
It's not so simple reproduce the failure because I have to playback for an unknown time a video. If I play, stop and play without wait a sort of time the error don't appear.
Thanks for the hard work and time you spent on this amazing project.
@elbowz your log is good unfurnately has not improved to understand the situation
the problem happen only when you play from Kodi library? if you rollback to v1.10.0 the problem persist?
the problem happen only when you play from Kodi library?
I don't know, because is the only way I use your plugin.
if you rollback to v1.10.0 the problem persist?
I have just downgrade to 1.10.0.
As I said, on my environment is not easy to reproduce the bug, i have to play a film/episode for un unknown unmount of time.
I'll make your requested test and try to answer to your question.
what is the exact line where you have cut the log?
now i have found something:
[plugin.video.netflix (0)] Requesting releasing license
https://gist.github.com/elbowz/5600fc92b795e6e58a1f9b1e32b2b3c7#file-gistfile1-txt-L3462-L3465
there is the http request for relasing license, but seem to be freezed in waiting a response or other, after this line there is no more NF service messages, so I could deduce that the service is freezed to the post request and then other interactions with the addon will not work
I would like to see if it is the same for the other users here
You have catch it, great!
I have updated the gist with the full log if can be useful.
I have tried to play video directly in the plugin on version 1.10.0 and it seems the same failure (timeout) appear. But also an "OSError"...so, I'm not sure of this result...I'll do further tests
Edit:
I confirm, also with 1.10.0v and directly inside Netflix plugin (no through kody library) i get:
Exception: Addon Signals call timeout
I think the "OSError" is related to the fact that inside the plugin also the video list cannot be refreshed, receiving it from netflix...the "OSError" disappear, unlike the "timeout error", when I play from library side.
@elbowz the problem is to understand why the http request does not happen correctly
I tried to add a timeout/retry, please try: plugin.video.netflix_1.10.1_20201111_t1.zip and get a log even if it works, because the error may not be shown on screen and i need to know what happen
Hello, Sorry, I didn't have the possibility to generate logs earlier. I've installed plugin.video.netflix_1.10.1_20201111_t1.zip Here are the logs: https://drive.google.com/file/d/1UmqeSW99D46p3nX7T5AInj4wfUwcC7AL/view?usp=sharing I hope it will be helpful. Please let me know if you need any additional information. I'll try to deliver it.
@gmasluch good log from what i see you have the same issue of @elbowz the workaround for "relasing license" to force http timeout has worked, and the second http request is gone succesfully but has freezed on a different http request endpoint
apparently seems random sound like more a network problem or a problem on their netflix server only theories i see no viable solutions, i have add timeout also to the others endpoints, this is an WIP test that should works better, so intead freeze the addon should show the error on screen, then you can try again the operation: plugin.video.netflix_1.10.1_20201111_t2.zip
let me know if you are able to use addon without disable/reenable it
Thanks @CastagnaIT, the lastest release works like you describe: the error is still present as dialog msgbox (HttpErrorTimeout), but we can retry the playback again, without restart Kodi, and all works as expected.
It's very strange behaviour...make me know if you need the log or furrher tests.
The issue is not so high severity, a little bit annoyance in the use, and Up next plugin cannot be used
Hello I have the same problem, I posted a log few days ago and you said it was due to a problem with my network. I have tested plugin.video.netflix_1.10.1_20201111_t2.zip, I get HttpErrorTimeout message but can retry the playback without have to disable/enable the addon or restart Kodi.
maybe, there is a possibility that the error will not occur with this definitive patch if someone can update and verify: plugin.video.netflix_1.10.1_20201112_t3.zip
Still the same issue unfortunately.
Still the same issue unfortunately.
more detailed response please
I have tried the t3 version, I confirm the same error (HttpErrorTimeout in a DialogBox).
Here the new log: https://gist.githubusercontent.com/elbowz/5600fc92b795e6e58a1f9b1e32b2b3c7/raw/fa6d5c3f3f700a653c5dd5f9287589dfe478bc25/kodi.netflix.t3.log
I have try to understand your code, but is too huge and I don't know the whole context around (anyway very well written!).
I think this is the endpoint you referring: https://www.netflix.com/nq/msl_v1/cadmium/
I don't know which appended path (eg. event/1
) throw the timeout error.
I would have liked play with curl/wget to make multiple requests on the same endpoint and see what happen...but I get 404 or 502, so there is something that I have missing (eg. authentication).
TL;DR ask if you need some "particular" test on my side, I know that can be hard fix a bug that you can't reproduce in your environment.
it took me months to full understand how works addon code written by previous developers and study the netflix protocols, to begin to understand how endpoints work you need to analyze the network flow of NF website browser by seeing what is called when you do an single simple operation, then see how the addon does the same operation
the endpoint mentioned is only a base url, MSL section has multiple endpoints composed by (BASE+FINAL URL PART)=endpoint
so the event/1
stand for https://www.netflix.com/msl/playapi/cadmium/event/1
it is an endpoint used to send HTTP request to manage watched status, not your case
the first case where the HTTP request fail is to endpoint CHROME_BASE_URL + 'pbo_licenses/%5E1.0.0/router'
and only when we have to request the release of the license,
but after this will also fail a shakti http request in nfsession, strangely related, that use pathEvaluator
endpoint:
https://www.netflix.com/api/shakti/vdeb953cf/pathEvaluator
use curl/wget to MSL endpoint will never work because the MSL in an encrypted protocol over HTTPS and you have to send encrypted data, maybe continuous ping to the endpoint could maybe show if the connection request will be blocked, but will not give a precise explanation of the problem...
for now i am interested in making sure that the addon does not freeze because soon i will make the release
from my experience a problem like this, could be:
if in the meantime you discover something will help
Hi,
I tried t3. I got the onscreen httperror time out error when trying accessing another folder after playing one video. I could just retry to access same folder (or episode or movie) and then it worked I can add log file today or tomorrow
it took me months to full understand how works addon code written by previous developers and study the netflix protocols, to begin to understand how endpoints work you need to analyze the network flow of NF website browser by seeing what is called when you do an single simple operation, then see how the addon does the same operation
So, you do a sort of reverse engineering to understand the internal protocol, maybe using the web developer tools (eg. Networks tab)...it seems an hard and interesting work.
the endpoint mentioned is only a base url, MSL section has multiple endpoints composed by (BASE+FINAL URL PART)=endpoint so the
event/1
stand forhttps://www.netflix.com/msl/playapi/cadmium/event/1
it is an endpoint used to send HTTP request to manage watched status, not your casethe first case where the HTTP request fail is to endpoint CHROME_BASE_URL + 'pbo_licenses/%5E1.0.0/router' and only when we have to request the release of the license, but after this will also fail a shakti http request in nfsession, strangely related, that use
pathEvaluator
endpoint:https://www.netflix.com/api/shakti/vdeb953cf/pathEvaluator
ok, so netflix use (and have developed) a specif protocol (ie. MSL) for make secure communication. I don't have knowledge for understand the specific flow of the requests, related FINAL URL PART
, payload and response....and I don't want learn it ;)
use curl/wget to MSL endpoint will never work because the MSL in an encrypted protocol over HTTPS and you have to send encrypted data, maybe continuous ping to the endpoint could maybe show if the connection request will be blocked, but will not give a precise explanation of the problem...
Yeah, I thought the same test. Quite stupid but is the only one can do a this point. Anyway, if the error is a timeout and not a response with a status code (eg. 200, 404, 502), I guess also "ping test" should reveal the issue...or at least exclude a kodi/python issue (?)
for now i am interested in making sure that the addon does not freeze because soon i will make the release
The addon NOT freeze with the latest release :+1:
from my experience a problem like this, could be:
- Some change in MSL protocol But i do not see changes in website flow at least in my country, if NF are making changes could also take weeks to be implemented worldwide. Previous experiences i have noticed that NF can makes "sample" changes, so enable the website changes only for a limited group of user accounts only to test the changes, then after days will be applied to all accounts.
If can help I use Netflix from Italy with an Hungarian account.
- Problems in their servers, has already happened many times in the past, and looking for the problem is only a waste of time, so the best solution is to wait at least 7 days to see if the amount of users having problems increases or decreases
I should test the web client for NF...but I'm quite sure that there aren't issues there. Wait some days is the better approach
- Some kind of anti-bot protection > but sound very strange because seem that happen when we try to release the license only
I pray that this is not the reason...could be the end of this amazing addon
if in the meantime you discover something will help
if some idea hit your mind make know... :)
Thanks for the long and exhaustive explanation!
I've also tried t3 and while I did see an occasional HTTP error, I was able to retry browsing without disabling/re-enabling the addon. Thanks!
Any progress yet? My wife is already threatening to get a Fire TV stick đŸ˜
Same with me. Interesting facts - today I was able to log in on one of the devices without an Authentication key - normally with a login and password. It acted like a storm for a while. And then timeout again ... Tested on 1.11.0 and github. In 1.10.1 this doesn't happen that often.
We are few people with this issues for what understand.
All on Linux OS?
I'm on Ubuntu 20.04.01
Coreelec ans Ubuntu.
LibreELEC 9.2.6 (Kodi 18.9) @ RPi 3
Someone that still have this problem can let me know if this test solve the problem? plugin.video.netflix_1.12.0_20201230_t1.zip
I just had an error again but no debug loggin enabled. Maybe this helps anyway, it contains the error at the end: https://pastebin.com/wuQrSXqN
On my laptop (ubuntu) the error stopped appearing. On the coreelec - it appears much less often - on 30 different menu, playback, it jumped out once
can you confirm that with these steps the problem not occours? steps: 1) play a single video 2) stop playback 3) wait at least 10 seconds 4) play another single video 5) stop
Following the above instructions, the error does not appear (maybe once or twice it happened). However, when using UpNext it did not appear for 1-2 days, now it started to appear again, after each attempt to play the next episode (so one is played and in the background the other one starts playing)
Another user also said that with this steps it works with no errors
I suspect that the website wants the context continuewatching to be updated before doing other http requests but this is very strange that happen only for some users I don't know if it is a change they are going to implement in slow release, or it is a some kind of website bug
Also thinking of finding a solution of this kind, is difficult to implement at the moment because:
perhaps a solution could be force the stop of playback when user play next video, and keep waiting for all things are completed, this means show a loading screen for some amonth of seconds a bit ugly to see... and it should be done without constantly blocking the IPC system otherwise it could block the add-on system...
I am currently using the latest version 1.12.1 on Liberelec 9.2.6 with Kodi 18.9 on Pi 3. Error are less frequent compare to when I first open the issue. even when error appears I can usually just click on 'ok' on the error message and retry immediately to play the video. In some cases it will jump to main kodi menu after the error; error seems to have less consistency to when and why they appear.
Hi guys, found a fix for this issue....please look at
https://github.com/CastagnaIT/plugin.video.netflix/issues/1004
that solution works for this issue as well...
Steffano provided a new version that As far for me....solve this issue without any special config...just from the scracth...try the version t3 from the mentioned referral
someone has tried if the problem happen on Kodi 19? it would be useful to know
This is the definitive "fix" if someone can give a feedback: Kodi18: plugin.video.netflix_1.12.1_20210123_t17.zip
Bug report
Your Environment
Used Operating system:
Describe the bug
go to Netflix add on --> go to folder (eg.. my user, my lsit, TV seriex X > eposide 1) -> play video --> when vdieo ends or I press stop the video stops sweithc to kodi screen but the content is empty (the screen with two colors with dark blue on the left and lighter in the right but there is no content - no folder names or anything) --> I press back --> the rounding wheel start to turn --> after 10 sec I get error message --> click ok --> wheel turning --> another erroe emssage --> adn then fianlly it wil go to the main screen of Kodi. After that I canot use anymore the Ntelfix add on. I get errors. only after reinstall (or updadte) I can watch again one video. After that that video the whole process start again
Expected behavior
I expect to go back to to folder I was before the error eg. TV series X season 3 and see all the episodes
Actual behavior
Add crash and give an error and it can be use again until new installtion of the add on
Steps to reproduce the behavior
Possible fix
Reinstall the add on before watching each video
Debug log
The debug log can be found from this link: https://paste.kodi.tv/kihemuwara
Additional context or screenshots (if appropriate)
Installation
Other information
Screenshots