Close merged task card: feature-svc-autorecover (PR #396/#400/#401) #402

Merged
weichen merged 1 commits from feature/card-close-20261011-222438Z into main 2026-10-11 22:27:21 +00:00
@@ -1,6 +1,6 @@
# feature/svc-autorecover 任务卡
任务主记录:https://git-home.u1680832.nyat.app:30319/weichen/Agent-System-Dev/pulls/396;状态:已完成(已合入 main);owner:weichen
任务主记录:https://git-home.u1680832.nyat.app:30319/weichen/Agent-System-Dev/pulls/396;状态:已完成(回填);owner:weichen
## 基线与授权
@@ -68,7 +68,7 @@
| 时间(UTC) | 命令 | 被测HEAD | exit | 来源 | sha256(16) |
|---|---|---|---|---|---|
## 结果与验证(完成后填写)
## 结果与验证
- 结果:svc 自恢复能力落地:autostart 期望态(svc.env)+ `svc.sh recover`(postgres 优先、逐服务 .start.lock、recover 事件)+ `svc.sh watchdog`(systemd 用户 timer 每分钟 recover,cron 降级指引);start/stop/restart/deploy/update 全程持生命周期锁;修复锁 fd 继承与 exec 重定向吞 stderr 两个实测缺陷;端口守卫增加无 ss 环境的 /dev/tcp 兜底。
- 验证:PASS —— tests/test_svc_recover.py 10/10(本地,含 SIGKILL→recover 拉回、stop 不复活、锁占用跳过、端口被抢 fail 事件);make test-governance 146/146(本地 SELF,sync 后重跑已入证据表);CI(GATE)PR HEAD e0b49d1 test=success test-pg=success(test-pg 首跑 TestToolCallDeltaBeforeExecution 抖动,rerun 后绿);本机 watchdog 落地与 kill -9 实测见收尾后 runtime/dev/history.jsonl 的 recover 事件。
@@ -396,3 +396,9 @@
}
```
| 同步前验收 | 77391479a0645f06b631bc64ac9e55554f7e4f4e | c08cf35abaf651e8373abfc51ffaba65abc546d2 | 2026-10-11T22:19:56Z |
## 闭合记录(card-autoclose 回填)
- 依据:merge d99482fcaab1fdbfae577d09a8ab92c7bd9d262b(PR #401)已包含于 origin/main,分支成果已落盘;本段为合入后回填。
- 合并主题:Merge pull request 'Keep recovered services alive when the watchdog oneshot exits (KillMode=process)' (#401) from feature/svc-autorecover into main
- 归档:随闭合移入 .task/archive/;任务执行期的过程证据见原任务记录与 PR。