feat: 工具链就绪(bleak/pillow/pytest/capstone/androguard) + Web协议提取报告

This commit is contained in:
agent committed 2026-07-24 09:23:28 +00:00
1 parent 30571dc0a5
commit cb7eee312f
11 files changed
+8006

No files matched your search

+29
View File
@@ -0,0 +1,29 @@
#!/usr/bin/env python3
"""环境自检:验证分析/CLI 依赖可用,打印版本表。退出码 0=全部通过。"""
import importlib
import shutil
import sys
DEPS = ["bleak", "PIL", "pytest", "capstone", "androguard"]
def main() -> int:
ok = True
for mod in DEPS:
try:
m = importlib.import_module(mod)
ver = getattr(m, "__version__", "?")
print(f"OK {mod:<12} {ver}")
except ImportError as e:
ok = False
print(f"FAIL {mod:<12} {e}")
for tool in ["git"]:
path = shutil.which(tool)
print(f"{'OK ' if path else 'FAIL'} {tool:<12} {path or 'missing'}")
ok = ok and bool(path)
print("ENV:", "PASS" if ok else "FAIL")
return 0 if ok else 1
if __name__ == "__main__":
sys.exit(main())