fix(apple-runner): fence prep spawns after teardown or last-waiter cancellation
维护者通常 1 天内回复
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 42/100
- Issue 类型
- 缺陷
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- node.js, typescript
- 领域
- mobile-dev, testing
调研方向
Start by reading PR #3193 and trace the runner start, preparation-spawn, teardown, and waiter-cancellation paths it changed; the issue does not name source files or tests. Then identify where the session lock is held during close and how retries are admitted. Done means the specified cancellation controls and live close-during-build route show no respawn, close completes, owned children are cleaned up, and the focused tests and affected gate pass.
由索引模型根据 Issue 内容生成。
描述
Purpose
A runner start must stop creating preparation processes after its execution host is torn down or its last interested waiter cancels. Stopping the currently registered children once is insufficient.
PR #3193 measured this during close with a cold build: close killed the first build-for-testing before obtaining the runner session lock, but the detached prewarm health retry spawned a second build while close waited for that lock. Close reached its timeout; the second build remained until daemon stop. Original evidence: https://github.com/callstack/agent-device/pull/3193#issuecomment-5981188182. This observation is at b6cdd3c49, not a fresh reproduction on main.
Required behavior
- The in-flight runner start owns whether further preparation is admitted. Device teardown closes that admission before stopping current prep children or waiting for the session lock.
- Canceling the final interested waiter closes admission for that start. Canceling one waiter must preserve work still needed by another.
- Check admission at every preparation spawn, including retries after a killed build. A check only when registering an already spawned child is too late.
- A later independent open may create a fresh start; a retired start cannot resume and publish a runner into it.
- Prefer one start-owned cancellation/admission mechanism. Reassess whether the request-owner prep filter introduced by #3193 remains necessary once the reachable callers and waiter semantics are covered.
Done when
- A control holds the runner session lock during a cold build, begins non-retained close, and attempts a retry after the first child is stopped. No second prep child is spawned; close settles without waiting for a replacement build.
- Controls cover cancellation before the first prep spawn, last-waiter cancellation, and another still-interested waiter.
- Repeat the live close-during-build route with evidence of no respawn, completed close, and cleanup. Retain the original evidence attribution.
- Focused tests and the affected gate pass; process signaling remains scoped to owned children.
Depends on #3193. This is start admission, not another host-wide timeout sweep or a shorter join timeout.
- 主要语言
- TypeScript
- 星标
- 4.9k
- 派生
- 328
- 平均合并
- 12 小时 13 分钟
- 30 天内合并 PR
- 541
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
callstack/agent-device 的其他 Issue
-
settings clear-app-state fails with ENOENT … scandir '(null)' for iOS system apps such as Settings可能已有人在做 @thymikee 于 1 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 80/100
callstack/agent-device#3305 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 68/100
callstack/agent-device#1869 ·
维护者通常 1 天内回复
-
install and reinstall from another session in the same daemon replace the app on a claimed device未关闭
难度 4/5 3-5 天 新手友好度 55/100
callstack/agent-device#3345 ·
维护者通常 1 天内回复
-
难度 4/5 3-5 天 新手友好度 48/100
callstack/agent-device#3344 ·
维护者通常 1 天内回复
-
难度 5/5 一周以上 新手友好度 35/100
callstack/agent-device#3342 · 7 条评论 ·
维护者通常 1 天内回复
查看 callstack/agent-device 的全部 Issue
相似的 Issue
-
[Docs] README: FAQ setup command, IDA in the intro, Node badge可能已有人在做 @akram1089 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 85/100
维护者通常 1 天内回复
-
[Feature]: [P3] engine-rs: the package source hash should ignore line endings and untracked files未关闭
难度 2/5 1-3 小时 新手友好度 70/100
maniator/verticopolis#880 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
-
难度 2/5 1-3 小时 新手友好度 62/100
siyuan-note/siyuan#20353 ·
维护者通常 1 天内回复
-
afk-ok area:data-quality importer size:S
难度 2/5 1-3 小时 新手友好度 82/100
enorm-labs/event-junkie#3027 ·
维护者通常 1 天内回复