fix: replace 'mcporter list' with 'mcporter config list' to prevent hangs
mcporter list probes all configured servers sequentially, which can hang indefinitely when servers are slow/offline. mcporter config list reads config without probing — sufficient for checking if a server is configured. Affected: doctor checks (4 channels) and install command (2 calls). Fixes #34
This commit is contained in:
@@ -24,7 +24,7 @@ class ExaSearchChannel(Channel):
|
||||
)
|
||||
try:
|
||||
r = subprocess.run(
|
||||
["mcporter", "list"], capture_output=True, text=True, timeout=10
|
||||
["mcporter", "config", "list"], capture_output=True, text=True, timeout=5
|
||||
)
|
||||
if "exa" in r.stdout.lower():
|
||||
return "ok", "全网语义搜索可用(免费,无需 API Key)"
|
||||
|
||||
Reference in New Issue
Block a user