MCPcopy Create free account
hub / github.com/IBM/mcp-cli / check_python_packages

Function check_python_packages

diagnostics/mcp_cli_diagnostics.py:14–41  ·  view source on GitHub ↗

Check required Python packages.

()

Source from the content-addressed store, hash-verified

12
13
14def check_python_packages():
15 """Check required Python packages."""
16 print("1. Python Package Dependencies")
17 print("-" * 32)
18
19 required_packages = [
20 "mcp_cli",
21 "chuk_tool_processor",
22 "chuk_mcp",
23 "typer",
24 "rich",
25 "anyio",
26 ]
27
28 missing_packages = []
29
30 for package in required_packages:
31 try:
32 module = importlib.import_module(package.replace("-", "_"))
33 version = getattr(module, "__version__", "unknown")
34 location = getattr(module, "__file__", "unknown")
35 print(f" ✅ {package}: {version}")
36 print(f" Location: {location}")
37 except ImportError:
38 print(f" ❌ {package}: Not installed")
39 missing_packages.append(package)
40
41 return len(missing_packages) == 0
42
43
44def check_mcp_cli_installation():

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected