AlphaSlayer1964 / kemono-dl

A simple kemono.party downloader using python.
503 stars 81 forks source link

Network links problem #28

Closed ghost closed 2 years ago

ghost commented 2 years ago

Excuse me. My region does not support overseas network connection, which leads to a slow download speed of about 100kib/s even lower. however, when I use VPN to change IP and try to enter the overseas network for acceleration, there will be a download error.This is a common situation. I confirmed that the problem is not cookies. It is related to network links. How can I solve it. Thank you very much.

Here are the error codes

G:\1kemono-dl-2021.11.03>python kemono-dl.py --cookies "cookie.txt" --links https://kemono.party/patreon/user/25691365 Traceback (most recent call last): File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\connectionpool.py", line 696, in urlopen self._prepare_proxy(conn) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\connectionpool.py", line 964, in _prepare_proxy conn.connect() File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\connection.py", line 364, in connect conn = self._connect_tls_proxy(hostname, conn) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\connection.py", line 501, in _connect_tls_proxy socket = ssl_wrapsocket( File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\util\ssl.py", line 453, in ssl_wrap_socket ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_intls) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\util\ssl.py", line 495, in _ssl_wrap_socket_impl return ssl_context.wrap_socket(sock) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\ssl.py", line 500, in wrap_socket return self.sslsocket_class._create( File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\ssl.py", line 1040, in _create self.do_handshake() File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\ssl.py", line 1309, in do_handshake self._sslobj.do_handshake() ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:1129)

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\adapters.py", line 439, in send resp = conn.urlopen( File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\connectionpool.py", line 783, in urlopen return self.urlopen( File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\connectionpool.py", line 783, in urlopen return self.urlopen( File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\connectionpool.py", line 783, in urlopen return self.urlopen( [Previous line repeated 5 more times] File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen retries = retries.increment( File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\util\retry.py", line 574, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='kemono.party', port=443): Max retries exceeded with url: /api/creators/ (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1129)')))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "G:\1kemono-dl-2021.11.03\kemono-dl.py", line 4, in main() File "G:\1kemono-dl-2021.11.03\src\main.py", line 15, in main if not extract_link_info(link): File "G:\1kemono-dl-2021.11.03\src\api.py", line 284, in extract_link_info info['username'] = get_username(info) File "G:\1kemono-dl-2021.11.03\src\api.py", line 272, in get_username response = session.get(url, timeout=TIMEOUT) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\sessions.py", line 555, in get return self.request('GET', url, kwargs) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\sessions.py", line 542, in request resp = self.send(prep, send_kwargs) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\sessions.py", line 655, in send r = adapter.send(request, **kwargs) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\adapters.py", line 514, in send raise SSLError(e, request=request) requests.exceptions.SSLError: HTTPSConnectionPool(host='kemono.party', port=443): Max retries exceeded with url: /api/creators/ (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1129)')))

AlphaSlayer1964 commented 2 years ago

Next time please post an issue using the bug report template. So what vpn are you using? Maybe kemono.party is blocking that vpn? Does the site work though your browser with the vpn? I have tried with my vpn PIA and got no issues. Also do you get this 443 error on all downloads or only some?

ghost commented 2 years ago

Next time please post an issue using the bug report template. So what vpn are you using? Maybe kemono.party is blocking that vpn? Does the site work though your browser with the vpn? I have tried with my vpn PIA and got no issues. Also do you get this 443 error on all downloads or only some?

Sorry, my mistake about report.

1.The VPN I use is v2rayN https://github.com/2dust/v2rayN. 2.Buy the url https://www.projectswinter.com/subscription/ba2e552b-52de-49a2-8d8f-47cf02c3314c/v2rayng to link. And I try at least five service providers not only this but also they do not work. If you like, you can download v2ray and fill in the URL to link to test. 3.this 433 error on all downloads when I using vpn. It can download normally without vpn but very slow.

I don't know much about network knowledge so maybe I Can't describe the problem accurately. And I appreciate your reply.

AlphaSlayer1964 commented 2 years ago

If you use the browser with the vpn can you download files?

AlphaSlayer1964 commented 2 years ago

Did you get it working?