CastagnaIT / plugin.video.netflix

InputStream based Netflix plugin for Kodi
MIT License
1.91k stars 259 forks source link

cannot run NFAuthenticationKey.py #1642

Closed Kidlike closed 11 months ago

Kidlike commented 11 months ago

Netflix add-on version

1.22.3

Operative systems used

Linux (Ubuntu / Mint / ...)

Kodi version used

Kodi 19 (Matrix)

Description of the bug

Browser startup... (/usr/bin/chromium-browser) please wait
Establish connection with the browser... please wait
An error is occurred:
Connection to remote host was lost.
Traceback (most recent call last):
  File "/run/media/theponds/aaa/Downloads/NFAuthenticationKey.py", line 63, in __init__
    self.operations()
  File "/run/media/theponds/aaa/Downloads/NFAuthenticationKey.py", line 83, in operations
    self.get_browser_debug_endpoint()
  File "/run/media/theponds/aaa/Downloads/NFAuthenticationKey.py", line 153, in get_browser_debug_endpoint
    self._ws = websocket.create_connection(endpoint)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/websocket/_core.py", line 601, in create_connection
    websock.connect(url, **options)
  File "/usr/lib/python3.11/site-packages/websocket/_core.py", line 248, in connect
    self.handshake_response = handshake(self.sock, url, *addrs, **options)
                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/websocket/_handshake.py", line 57, in handshake
    status, resp = _get_resp_headers(sock)
                   ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/websocket/_handshake.py", line 146, in _get_resp_headers
    status, resp_headers, status_message = read_headers(sock)
                                           ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/websocket/_http.py", line 312, in read_headers
    line = recv_line(sock)
           ^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/websocket/_socket.py", line 131, in recv_line
    c = recv(sock, 1)
        ^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/websocket/_socket.py", line 122, in recv
    raise WebSocketConnectionClosedException(
websocket._exceptions.WebSocketConnectionClosedException: Connection to remote host was lost.

Steps to reproduce the behavior

python NFAuthenticationKey.py

Debug log - mandatory

n/a

Possible fix

No response

Additional context

trying to authenticate. Username/password doesn't work. This script doesn't work either.

Screenshots

No response

Kidlike commented 11 months ago

I managed to figure it out by adding some print messages... It turns out that --incognito causes a segfault to all chrom* variants these days, at least on Linux. Removing that from the browser params makes everything work! :tada: