Summary
agent-reach doctor --json reports v2ex as unreachable with an SSL error, but the V2EX API is fully reachable via curl. The SSL failure is in agent-reach's bundled Python urllib, not in the network.
Environment
- agent-reach v1.5.0 (Windows 11)
- China network, no proxy
What doctor reports
status: warn
name: "V2EX 节点、主题与回复"
message: "V2EX API 连接失败(可能需要代理):<urlopen error [SSL: UNEXPECTED_EOF_WHILE_READING] EOF occurred in violation of protocol (_ssl.c:1010)>"
active_backend: null
What's actually true
curl reaches the same endpoint successfully (HTTP 200 in ~2.5s, no proxy):
$ curl -sS -m 8 -o /dev/null -w "http_code=%{http_code} time=%{time_total}s\n" \
"https://www.v2ex.com/api/topics/hot.json" -H "User-Agent: agent-reach/1.0"
http_code=200 time=2.519745s
Likely root cause
The check uses Python's urllib (the _ssl.c reference in the error confirms this), which hits SSL: UNEXPECTED_EOF_WHILE_READING. curl uses a different TLS stack and succeeds. This is a false negative from the Python SSL environment bundled in the agent-reach executable, not a real connectivity problem. This also contributes to the ~32s doctor runtime (the failing check times out slowly).
Suggested fix
- Use a more robust HTTP client / TLS config for the connectivity check (e.g.
requests with proper cert handling, or shell out to curl).
- Or catch
SSL: UNEXPECTED_EOF_WHILE_READING specifically and retry / fall back instead of reporting the channel as down.
Workaround
Ignore the warn — v2ex is reachable. Use curl directly for V2EX API calls.
Related
Summary
agent-reach doctor --jsonreports v2ex as unreachable with an SSL error, but the V2EX API is fully reachable viacurl. The SSL failure is in agent-reach's bundled Pythonurllib, not in the network.Environment
What doctor reports
What's actually true
curlreaches the same endpoint successfully (HTTP 200 in ~2.5s, no proxy):Likely root cause
The check uses Python's
urllib(the_ssl.creference in the error confirms this), which hitsSSL: UNEXPECTED_EOF_WHILE_READING.curluses a different TLS stack and succeeds. This is a false negative from the Python SSL environment bundled in the agent-reach executable, not a real connectivity problem. This also contributes to the ~32sdoctorruntime (the failing check times out slowly).Suggested fix
requestswith proper cert handling, or shell out tocurl).SSL: UNEXPECTED_EOF_WHILE_READINGspecifically and retry / fall back instead of reporting the channel as down.Workaround
Ignore the
warn— v2ex is reachable. Usecurldirectly for V2EX API calls.Related