Files
Nexus/docs/changelog/2026-06-13-ssh-watch-probe-quote-fix.md
2026-07-08 22:31:31 +08:00

640 B
Raw Permalink Blame History

修复 SSH 监测探针脚本语法错误

日期2026-06-13

变更摘要

修复 SSH_WATCH_METRICS_CMD.strip('"') 破坏 bash 双引号包裹导致探针全部 ssh_probe_failed、实时监测不可用的问题。

动机

硬件详情上线后监测插槽无数据;根因为嵌入脚本的 " 提前结束 python3 -c "..." 字符串。

涉及文件

  • server/infrastructure/ssh/remote_probe.py — 改用 strip(chr(34))
  • tests/test_watch_metrics.py — 本地执行探针脚本回归

验证

.venv/bin/pytest tests/test_watch_metrics.py::test_ssh_watch_metrics_cmd_runs_locally -q