Wait for the kept ports to free before the live-prototype server restarts
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
调研方向
Start with cmd_restart in plugins/planning/shared/share.py (around lines 675-689), where stop_server is followed immediately by start_server on the kept ports, then read bridge.port_free and the ensure-running check near lines 566-577 for the existing pattern. Reproduce by running test_a_restart_keeps_a_running_live_prototype in plugins/planning/shared/tests/test_share.py repeatedly. Done means restart waits on a bounded timeout for both ports to free, refuses with a message naming a still-busy port, and two new tests cover the wait and the refusal.
由索引模型根据 Issue 内容生成。
描述
Problem
plugins/planning/shared/tests/test_share.py::TestLives::test_a_restart_keeps_a_running_live_prototype failed in CI with the server did not start: cannot start: [Errno 98] Address already in use (test_share.py:1388), in Test Python (0), job 137962517716. It passes locally (113 passed). The failing PR's diff does not touch the planning plugin.
cmd_restart (plugins/planning/shared/share.py:675-689) calls stop_server(d, s) and then, straight away, start_server(d, ports.get("guest", 0), ports.get("control", s["port"])) on the same ports. If the stopped server has not released its sockets yet, the bind fails. ensure-running (share.py:566-577) checks bridge.port_free before reusing a port. Restart cannot move to a new port the same way, because a named tunnel's ingress rule points at the guest port.
Done when
- After
stop_server,cmd_restartwaits until both kept ports are free (bridge.port_free), with a bounded timeout. If a port is still busy after the timeout, it refuses with a clear message naming the port. - A test holds the old port open briefly after stop and shows that restart waits and then binds the same ports, and a second test shows the refusal when the port stays busy.
-
test_a_restart_keeps_a_running_live_prototypepasses 20 consecutive runs locally (python3 -m pytest -q -k test_a_restart_keeps_a_running_live_prototype --count=20or a loop).
- 主要语言
- Shell
- 星标
- 22
- 派生
- 2
- 平均合并
- 2 小时
- 30 天内合并 PR
- 960
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
melodic-software/claude-code-plugins 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 74/100
melodic-software/claude-code-plugins#19225 · 2 条评论 ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 65/100
melodic-software/claude-code-plugins#17779 · 2 条评论 ·
维护者通常 1 天内回复
-
recurring
难度 4/5 3-5 天 新手友好度 25/100
melodic-software/claude-code-plugins#19274 ·
维护者通常 1 天内回复
-
难度 4/5 3-5 天 新手友好度 25/100
melodic-software/claude-code-plugins#19270 ·
维护者通常 1 天内回复
-
难度 3/5 1-2 天 新手友好度 53/100
melodic-software/claude-code-plugins#19269 ·
维护者通常 1 天内回复
查看 melodic-software/claude-code-plugins 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
nais/attest-sign#139 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
community-scripts/core#303 ·
维护者通常 1 天内回复
-
severity: low
难度 1/5 1 小时以内 新手友好度 72/100
luainkernel/lunatik#2727 ·
维护者通常 1 天内回复
-
[quality] release publish.mjs integrity guards have no unit test可能已有人在做 @robarnold 今天认领。 未关闭agent/quality stage/040-covered-by-pr testing
难度 2/5 1-3 小时 新手友好度 75/100
marinatedconcrete/config#1155 ·
维护者通常 1 天内回复
-
bug report-to-upstream
难度 1/5 1 小时以内 新手友好度 75/100
flatpark/flatpark#1585 · 1 条评论 ·
维护者通常 1 天内回复