ITADN

Download fails on AnimePahe due to SSL certificate verification error (uwucdn.top)

#111Closedhawking345 创建于 2025-11-07
H
hawking345commented
When downloading some anime from AnimePahe, I found that it gets stuck right before starting the download. It just shows a "?" for speed and time left. I installed Senpwai using pipx on Arch Linux, but I also tried running it on Linux Mint, and I got the same error. Here is my log from senpcli: ``` No anime found with the title "jojo" Here are the results: 1: JoJo's Bizarre Adventure (2012) 2: JoJo's Bizarre Adventure: Stardust Crusaders 3: JoJo's Bizarre Adventure: Stardust Crusaders - Battle in Egypt 4: JoJo's Bizarre Adventure: Diamond Is Unbreakable 5: JoJo's Bizarre Adventure: Golden Wind 6: JoJo's Bizarre Adventure 7: JoJo's Bizarre Adventure (OVA) 8: JoJo's Bizarre Adventure: Stone Ocean Pick one of the results by entering its number > 1 Downloading to: /home/hawking/hdd/media/anime/JoJo's Bizarre Adventure (2012) Total download size: 257 MB Downloading JoJo's Bizarre Adventure (2012): 0%| | 0.00/1.00 [00:00<?, ?eps/s]Traceback (most recent call last): File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/connectionpool.py", line 464, in _make_request self._validate_conn(conn) ~~~~~~~~~~~~~~~~~~~^^^^^^ File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/connectionpool.py", line 1093, in _validate_conn conn.connect() ~~~~~~~~~~~~^^ File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/connection.py", line 790, in connect sock_and_verified = _ssl_wrap_socket_and_match_hostname( sock=sock, ...<14 lines>... assert_fingerprint=self.assert_fingerprint, ) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/connection.py", line 969, in _ssl_wrap_socket_and_match_hostname ssl_sock = ssl_wrap_socket( sock=sock, ...<8 lines>... tls_in_tls=tls_in_tls, ) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/util/ssl_.py", line 480, in ssl_wrap_socket ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_in_tls, server_hostname) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/util/ssl_.py", line 524, in _ssl_wrap_socket_impl return ssl_context.wrap_socket(sock, server_hostname=server_hostname) ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.13/ssl.py", line 455, in wrap_socket return self.sslsocket_class._create( ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^ sock=sock, ^^^^^^^^^^ ...<5 lines>... session=session ^^^^^^^^^^^^^^^ ) ^ File "/usr/lib/python3.13/ssl.py", line 1076, in _create self.do_handshake() ~~~~~~~~~~~~~~~~~^^ File "/usr/lib/python3.13/ssl.py", line 1372, in do_handshake self._sslobj.do_handshake() ~~~~~~~~~~~~~~~~~~~~~~~~~^^ ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1032) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/connectionpool.py", line 787, in urlopen response = self._make_request( conn, ...<10 lines>... **response_kw, ) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/connectionpool.py", line 488, in _make_request raise new_e urllib3.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1032) The above exception was the direct cause of the following exception: Traceback (most recent call last): File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/requests/adapters.py", line 644, in send resp = conn.urlopen( method=request.method, ...<9 lines>... chunked=chunked, ) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/connectionpool.py", line 841, in urlopen retries = retries.increment( method, url, error=new_e, _pool=self, _stacktrace=sys.exc_info()[2] ) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/urllib3/util/retry.py", line 519, in increment raise MaxRetryError(_pool, url, reason) from reason # type: ignore[arg-type] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='vault-01.uwucdn.top', port=443): Max retries exceeded with url: /mp4/01/05/6f2e0274e27de929e871a00268cd107522c6aa6a53425524186ddc236ba1b914?file=AnimePahe_JoJo_no_Kimyou_na_Bouken_TV_-_09_BD_1080p_Some-Stuffs.mp4 (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1032)'))) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/senpwai/common/scraper.py", line 232, in network_error_retry_wrapper return callback() File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/senpwai/common/scraper.py", line 160, in callback return requests.get( ~~~~~~~~~~~~^ url, ^^^^ ...<5 lines>... #verify=verify_ssl, ^^^^^^^^^^^^^^^^^^^ ) ^ File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/requests/api.py", line 73, inget return request("get", url, params=params, **kwargs) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/requests/api.py", line 59, inrequest return session.request(method=method, url=url, **kwargs) ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/requests/sessions.py", line 589, in request resp = self.send(prep, **send_kwargs) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/requests/sessions.py", line 703, in send r = adapter.send(request, **kwargs) File "/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/requests/adapters.py", line 675, in send raise SSLError(e, request=request) requests.exceptions.SSLError: HTTPSConnectionPool(host='vault-01.uwucdn.top', port=443): Max retries exceeded with url: /mp4/01/05/6f2e0274e27de929e871a00268cd107522c6aa6a53425524186ddc236ba1b914?file=AnimePahe_JoJo_no_Kimyou_na_Bouken_TV_-_09_BD_1080p_Some-Stuffs.mp4 (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1032)'))) ``` Steps to reproduce: 1. Install Senpwai with pipx on Arch Linux or Linux Mint. 2. Run senpcli with an anime that does not work (for example: JoJo's Bizarre Adventure (2012) or Neon Genesis Evangelion). I found that anime that do work are usually newer releases. 3. The download does not start, and the error is visible in the log. I also found a workaround that requires skipping SSL verification for the "uwucdn.top" domain. To fix the error, I edited `/home/hawking/.local/share/pipx/venvs/senpwai/lib/python3.13/site-packages/senpwai/common/scraper.py` and modified line 156 from: ``` def callback(): return requests.get( url, headers=headers, stream=stream, cookies=cookies, allow_redirects=allow_redirects, timeout=timeout, ) ``` to: ``` def callback(): verify_ssl = False if "uwucdn.top" in url else True return requests.get( url, headers=headers, stream=stream, cookies=cookies, allow_redirects=allow_redirects, timeout=timeout, verify=verify_ssl, ) ``` My System: Pipx version: python-pipx 1.8.0-1 Python version: python 3.13.7 Senpwai version: senpwai 2.1.17 Distro: Arch Linux x86_64 Kernel: Linux 6.17.6-arch1-1 CPU: Intel(R) Core(TM) i5-10400 (12) @ 4.30 GHz GPU: AMD Radeon RX 6700 XT Edit: It randomly started working for me again so I closed the issue.
关闭于 2025-12-04 0 条评论