#989 httpx.ConnectError: [Errno 10093] getaddrinfo failed

129.150* Posted at: 7 days ago 👁15

网络连接失败:
Traceback (most recent call last):
File "httpx\_transports\default.py", line 101, in map_httpcore_exceptions
File "httpx\_transports\default.py", line 250, in handle_request
File "httpcore\_sync\connection_pool.py", line 216, in handle_request
File "httpcore\_sync\connection_pool.py", line 196, in handle_request
File "httpcore\_sync\connection.py", line 99, in handle_request
File "httpcore\_sync\connection.py", line 76, in handle_request
File "httpcore\_sync\connection.py", line 122, in _connect
File "httpcore\_backends\sync.py", line 205, in connect_tcp
File "contextlib.py", line 153, in exit
File "httpcore\_exceptions.py", line 14, in map_exceptions
httpcore.ConnectError: [Errno 10093] getaddrinfo failed

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "videotrans\util\TestSTT.py", line 18, in run
File "videotrans\recognition\__init__.py", line 204, in run
File "videotrans\recognition\_base.py", line 78, in run
File "tenacity\__init__.py", line 338, in wrapped_f
File "tenacity\__init__.py", line 477, in call
File "tenacity\__init__.py", line 378, in iter
File "tenacity\__init__.py", line 400, in
File "concurrent\futures\_base.py", line 439, in result
File "concurrent\futures\_base.py", line 391, in __get_result
File "tenacity\__init__.py", line 480, in call
File "videotrans\recognition\_deepgram.py", line 71, in _exec
File "deepgram\clients\listen\v1\rest\client.py", line 260, in transcribe_file
File "deepgram\clients\common\v1\abstract_sync_rest.py", line 123, in post
File "deepgram\clients\common\v1\abstract_sync_rest.py", line 226, in _handle_request
File "httpx\_client.py", line 824, in request
File "httpx\_client.py", line 913, in send
File "httpx\_client.py", line 941, in _send_handling_auth
File "httpx\_client.py", line 978, in _send_handling_redirects
File "httpx\_client.py", line 1013, in _send_single_request
File "httpx\_transports\default.py", line 249, in handle_request
File "contextlib.py", line 153, in exit
File "httpx\_transports\default.py", line 118, in map_httpcore_exceptions
httpx.ConnectError: [Errno 10093] getaddrinfo failed

=====
Windows-10-10.0.22631-SP0
version:v3.81
frozen:True
language:zh

1 Replies

本条内容由 gpt-5-mini 回复

问题原因很可能是网络/DNS 无法解析或 Windows 网络子系统异常,导致调用 Deepgram(或其它在线识别服务)时 getaddrinfo 失败(httpx.ConnectError: [Errno 10093] getaddrinfo failed)。请按下列步骤排查并修复:

  1. 立即判断网络连通性

    1. 在浏览器中打开任意网页确认能上网。
    2. 在命令提示符运行:ping api.deepgram.com 或 nslookup api.deepgram.com,检查是否能解析到 IP 地址并能连通。
  2. 检查软件内代理/网络设置

    1. 打开软件的语音识别/翻译设置,确认是否配置了 HTTP 代理(若使用公司/教育网请填写正确代理)。
    2. 如果你之前设置了代理,尝试先取消或改为系统代理再测试。
  3. 排查 Windows 本机网络问题(常见于 Errno 10093)

    1. 以管理员身份打开命令提示符,运行:

      • ipconfig /flushdns
      • netsh winsock reset
        然后重启电脑后再试。
  4. 检查防火墙/杀毒软件和 VPN

    1. 暂时关闭防火墙或安全软件的出站拦截,或将软件所在目录(运行的可执行文件,如 sp.exe)加入白名单。
    2. 若使用 VPN/企业网络,尝试断开 VPN 或换到家庭网络测试。
  5. 尝试切换识别渠道以验证是否为网络问题

    1. 若你只需离线测试,可切换到本地识别模型(如 faster-whisper)进行本地识别(注意首次本地模型需下载)。
  6. 收集更多信息

    1. 若以上步骤无效,请把软件根目录下 logs 目录中最新的日志文件(videotrans/logs/{年月日}.log)贴上来,或提供完整错误堆栈(你已给出,但需附带日志文件以便进一步分析)。
    2. 同时请告知是否在公司/校园网络、是否使用代理或 VPN,以及是否能在命令行成功 ping/nslookup api.deepgram.com。

如果需要进一步分析,请提供 videotrans/logs/ 目录下对应时间的完整日志文件。

Post Your Reply
Open source and free maintenance is not easy. If this project is helpful to you, please consider making a small donation to help the project continue to maintain and update.

Donate: https://ko-fi.com/jianchang512

Trending Questions