Repository navigation
test(desktop): qualify the supervisor against a real isolated Core - #6727
Conversation
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
loopx-agent
left a comment
There was a problem hiding this comment.
Reviewer: model_agent; gpt-6.1-sol; OpenAI; runtime_reported; reasoning_effort=max
Request changes conclusion (author-owned PR; GitHub blocks formal self-review)
精确审查 head:6507f1bad96ce1d00c282cc845916f968650bbf8。真实 backend 验证有价值,当前只剩一条 P2:新合成检查配方必须显式关闭使用遥测。
动机
维护者验证 Desktop 启动与恢复时,需要确认原生服务管理器确实能够启动安装后的 Core,而不只是让合成监听器返回正确标记。
原来已有模拟生命周期测试,但缺少真实安装、两项服务身份和空数据目录一起工作的验证;新版提供可运行的安装与两次服务重开检查,同时仍有一处合成测试遥测隔离遗漏。
本轮独立运行确认真实安装、Status/Chat 身份、零 Goal/Session、错误身份拒绝和监听器清理均通过;文档却未显式关闭合成使用遥测,不能完整满足既有验证边界。
本次不验收自动版本选择、正式 App 窗口重开、签名替换、渲染 UI、跨平台持续运行或模型效果,也不执行合并和真实宿主升级。
剩余缺口是为这组 opt-in 合成检查显式关闭并传递使用遥测开关;更广的启动、更新和正式窗口资格继续由现有父级 startup/recovery 工作保留。
接受依据固定在修改前 d4487a7c0a332365fc80ee3ca43d421bdf510d42:Desktop README 的 Runtime Model 与 Validation,以及 docs/development/testing-and-quality.md 的 Refactor Real-Path Gate、Synthetic Runs Must Not Report Adoption。后者明确要求合成 installer/发布资格 profile 自行设置 LOOPX_USAGE_PING=0,并验证真实 child CLI 与 typed sender 的零 HTTP。roadmap S4/S5/S12 提供归属,不把一个后台测试扩大成整个父级目标已经完成。
改动思路
真实后台验证复用既有 native installer、ServiceSet、端口与清理 owner;拆出一个局部测试文件已足够,不需要新测试框架或通用控制面。
本 PR 交付安装后 Core 与生产服务管理器的后台资格;补齐合成遥测关闭后可独立验收,自动选择、签名更新与正式 App 窗口仍由既有父级工作保留。
实际链路是已校验 archive → 原 install_snapshot → 普通安装的 Core → 原生 ServiceSet 的两项私有服务 → 真实 HTTP 读回 → stop/重开/身份拒绝。没有新 Goal、状态机、执行 provider 或默认配置。普通产品路径没有多一轮用户配置或确认;这是维护者主动运行的 QA。无改动会留下真实安装与模拟器之间的缺口,仅增加模拟断言也不足,因此这122行组合测试与已有 installer 的搭配是合理的完整增量。
| 路径 | 实际观察 | 资格边界 |
|---|---|---|
| 正常安装与启动 | 精确身份、空状态、Chat HTML、两次服务重开通过 | 后台协议和进程生命周期 |
| 错 frozen identity/改错数据路由 | 独立 oracle 均拒绝,恢复原 head 后通过 | 不把匹配 header 或空数组当作全部隔离 |
| 新配方缺少遥测关闭 | 合成机器 profile 的真实 CLI/typed sender 发出3个本地请求,显式关闭后0个 | 不上传外部 collector,不测试真实账户 |
服务重开不是 native 窗口重开;HTTP document 不是渲染 UI。PR 与 README 对这些限制说明准确,未借 #6680 的旧结论替代本次准确 head 验证。
具体改动
完整3文件,+154/-0。services.rs 只增加4行 cfg(all(test, unix)) 接线;普通 release 不包含模块。新文件是一个122行 ignored test,包含 bounded HTTP body 和 stopped-probe 两个局部 helper。README 增加28行可执行步骤和边界,没有修改首屏、导航、CSS、展示图片或前端业务,无需借本次后台测试补造截图。
关键代码讲解
real_private_runtime_serves_and_rejects_stale_identity(新测试文件37行)从实际安装读取 identity,但自己创建新的 registry/data tempdir,不信任调用者传入的空 registry。它用正确 shell quoting 生成显式 local launch pin,调用原生 ServiceSet::start,逐一核对 Status/Chat identity、status 的精确 registry 与零 Goal、session 空数组和 Chat doctype,再 stop 并重开一次。最后把预期 source revision 改成错误值,要求失败后两个 endpoint 都不可用。
response_body 与 assert_stopped(5/26行)使用5秒读超时、1MiB上限和 HTTP200 条件,并复用已有 probe。ServiceSet::collect/stop/Drop(原文件147行起)仍是清理 owner;既有单元测试还覆盖成功 peer 在另一项失败后被清理。新错误身份用例本身没有单独证明“恰好一个真实 peer 成功、另一个失败”的全部矩阵,不应扩大解释那条代码注释,但不需要为此另造框架。
[P2] 新 README 的362–367行没有设置合成遥测关闭开关。 LOOPX_REGISTRY、LOOPX_RUNTIME_ROOT 隔离的是 backend 数据;既有 usage_ping.state_path() 刻意按机器默认目录选择统计状态,不随 Goal root 改变。原 installer 会多次调用实际 doctor --installation-only。因此在使用统计可发送的机器 profile 中,这些 QA 调用仍可能成为安装、诊断与 profile 统计,违反上述既有合成运行约束。
独立反例使用本准确 head 正常安装的 Core,运行实际 CLI main、Python bridge 和原 typed sender,只把机器文件坐标放进可丢弃 fixture,没有改 consent、发送规则或 HTTP 输出。同样三次安装检查都成功:不关闭时第一调用显示 notice,后续共收到3个真实本地请求(ping、diagnostics、installation);加 LOOPX_USAGE_PING=0 后三个调用仍成功,0请求且不创建机器状态。collector 只在 loopback,无外部上报,没有借用真实安装 ID 或 Goal 内容。
最小修复是在这组命令执行任一 installer/CLI 前显式 export 该开关,并确保两项 opt-in profile 的子进程继承它;以同类隔离真实 child/sender 负例确认零请求。不要把产品遥测默认改掉或关闭用户真实设置。
对主干的风险
我从准确提交正常生成 archive,source 为 6507f1bad96ce1d00c282cc845916f968650bbf8、Core版本 2.0.0a1,与作者使用的 base archive 资格分开记录。普通 private installer 与新服务检查均实际通过:两个不同私有 origin、两轮成功、0 Goal/Session、精确 registry、错误身份拒绝和自有监听不可用。默认 CLI owner 文件保持原字节。普通 cargo test --locked --lib 为 124 passed / 5 ignored;两项与本 PR 相关的 ignored checks 另行明确执行通过,其余签名/文件系统检查未冒称完成。fmt、clippy all-targets -D warnings 和正常 release 构建通过。native premerge 4 direct + 17 selected 全部通过、0 hold;完整语义漂移检查通过。advisory 不支持 Rust 的候选载体,已人工确认没有新共享状态词汇,未把零条提示当作语义证明。
为检查新 oracle,我把同一新测试仅接线到不可变 base 的可丢弃导出,生产 owner 保持原字节;同一实际 Core 下 base harness 和原 head 都通过。受控副本移除 identity fence 后在“错误 artifact 必须拒绝”处失败;把 registry 与 runtime-root 一起指到另一个自有空目录后在“精确 registry”处失败,恢复原 head 再次通过。早期导出缺少五个 include_str 资源导致编译失败,补齐同 base 文件后才跑语义反例;第一次仅改 registry 的变异对 --global-registry 无效,也完整保留,没有计为检测成功。原仓库代码未作临时改动。
最初直接跑整组配方的本地收集观察在这台机器上为0请求,但它没有覆盖独立机器统计目录,不能证明其它 profile 安全;后续采用上面的隔离机器坐标和真实 sender 反例。这个范围区别不隐藏原观察,也不把 fixture 修复说成产品修复。Vite 的既有大 chunk 提示保留,未改预算。没有读取、轮询或等待 CI;没有替换正式 App、运行模型、杀共享监听器或据此宣称持续/跨 OS 合格。当前 main 的 native installer、endpoint 与 Cargo.lock owner 未改;其它 Core 工作项变化不被本次静态兼容检查冒领为整树资格。
我的整体评价
结论是 REQUEST_CHANGES:后台资格增量、真实正反例和 placement 都成立,运行时行为也保持原边界;需要先补齐新合成 profile 的遥测关闭义务,再针对新 head 复评。long_horizon 的服务所有权与恢复保持,父级持续工作不关闭;维护者 QA 的机器统计副作用必须修复,不能由124项测试或普通 premerge 的绿色结果代替。未来简化检查认为局部真实测试文件和既有 owner 已足够,没有必要追加通用 harness、迁移或新的状态声明。此次不合并、不继承历史批准,也不因作者提供的 CQR/测试声明而跳过独立验证。
English verdict: REQUEST_CHANGES — 6507f1bad96ce1d00c282cc845916f968650bbf8 adds useful real installed-Core supervisor coverage. Independent native tests (124 passed, relevant opt-ins run), release/static checks, base parity and effective identity/route mutations pass. The new synthetic recipe omits LOOPX_USAGE_PING=0: an isolated actual CLI/typed sender emits3 local requests without it and0 with it. Propagate the existing opt-out and verify zero HTTP; this does not qualify an installed App window, updater or sustained operation.
…tion Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
loopx-agent
left a comment
There was a problem hiding this comment.
Approval conclusion (author-owned PR; GitHub blocks formal self-approval)
Reviewer: model_agent; gpt-6.1-sol; OpenAI; runtime_reported; reasoning_effort=max.
审查 head:a1303b8197a36e0f26288b7e8833b7df8ba8d9be。审查整个 d4487a7c0a332365fc80ee3ca43d421bdf510d42...a1303b8197a36e0f26288b7e8833b7df8ba8d9be,本轮结论不继承旧批准。
动机
桌面维护者需要验证安装后的真实 Core 能否被原有服务监督器启动,并避免把合成检查记成用户采用。
普通测试通过时,真实安装产物仍可能与服务身份或独立数据路由不匹配。新增检查用临时数据启动实际 Core、重开服务并读回身份;这次修订还在两个真实检查入口强制要求先关闭采用统计。
本轮真实安装、两轮服务重开、零 Goal/零会话读回、错误冻结身份拒绝和自有监听清理均通过;未关闭统计的两次调用在读取测试路径或启动 Core 前拒绝执行。
此 PR 交付真实后端的选择性验证,不改变产品运行时;窗口渲染、签名升级、真实模型和完整 Goal 恢复需要另行验收。
默认忽略的检查仍需维护者显式运行;通过这些检查不能替代原生窗口或完整用户任务的验收。
改动思路
真实服务检查复用 SelectedRuntime、ServiceSet、既有安装器和 Core 路由,不另建身份、数据或服务状态 owner。当前 PR 边界是仅测试编译的真实后端检查、两个合成入口保护以及对应的操作说明。
不改 ServiceSet、Core 身份判定或产品遥测默认值。真实安装轮与实际 HTTP 服务轮各有用途:前者核对独立安装和默认命令归属,后者核对实际选择身份、全局注册表路由、服务重开与清理。只增加测试内两个小型读取/清理辅助函数;普通构建不包含此测试模块,普通测试也不会自动运行有安装副作用的用例。维护者已有本次测试意图,按说明一次准备独立环境即可,不增加用户操作轮次。
具体改动
验收依据是改动前的 apps/desktop/loopx-control-plane/README.md,固定版本 d4487a7c0a332365fc80ee3ca43d421bdf510d42。合成统计要求同时按该版本 docs/development/testing-and-quality.md 的原有策略判断;新 README 不能自证合规。
- Runtime Model:Both status and Chat must expose the selected artifact identity; the supervisor cleans up only the groups it owns. 本轮为 implemented;
services_real_runtime_tests and production SelectedRuntime/ServiceSet,证据:Real two-reopen test, wrong frozen-identity refusal and stopped endpoint assertions. - Validation:Keep standard validation and explicitly opt in to real artifact qualification; backend readback must not certify an untested native journey. 本轮为 implemented;
README real-Core recipe and both ignored Rust entrypoints,证据:124 ordinary tests plus explicitly run installer/service checks; README preserves backend/window distinction. - Synthetic Runs Must Not Report Adoption:Synthetic native wrappers/installers/service probes disable usage collection in every child before bootstrapping; isolated registry alone is insufficient. 本轮为 implemented;
Both Rust first assertions and README environment/commands; existing usage sender owner unchanged,证据:Both guard refusals and six existing real-CLI/typed-sender zero-collector cases pass.
关键代码讲解
real_private_runtime_serves_and_rejects_stale_identity:First require telemetry disabled, own fresh data, shell-quote a CLI pin, run the production ServiceSet twice and then challenge its frozen identity. Actual backend identity/registry/empty state/HTML and cleanup assertions determine the result.assert_stopped:Probe only the endpoint pair allocated to this disposable ServiceSet and require each unavailable after stop. Reject a leaked owned listener without targeting active/shared services.real_private_installer_keeps_the_default_cli_owner:Require LOOPX_USAGE_PING=0 before reading bundle/root and then exercise the existing private installer. Default CLI byte preservation, installed source/package identity and wrong-metadata refusal stay required.
全 diff 为四个文件:README 把关闭统计放在构建和两个真实调用之前,并区分后端/窗口验收;bundled_runtime.rs 的保护位于原有 ignored 测试开头;services.rs 只加入 Unix 测试模块声明;新模块实际启动已安装 Core,独立创建数据目录并为 CLI 的 global-registry 路由提供经过 shell 引号处理的参数。它读回零 Goal、零会话、真实 HTML,重开两次,再用错误冻结身份要求拒绝并清理监听。此前6507头的统计问题已按当前完整 diff 重新验证,未沿用旧通过结论。
对主干的风险
这次统计保护不是“换一个空注册表就安全”的假设。两个入口在 LOOPX_USAGE_PING=1 且路径未准备时均首先触发指定断言,证明不会先读取测试产物或启动 Core。另运行六个已有真实 CLI/类型化发送器统计用例,独立本地收集器没有收到请求;产品统计默认行为未改。错误身份对真实服务的拒绝和两路监听关闭也已实际执行,普通测试或模拟响应没有替代这些观察。
124项普通 Rust 测试通过,五个默认 ignored 用例保留各自显式资格;其中本 PR 涉及的真实安装和真实服务检查已另外显式运行并通过。格式、all-target clippy、release 构建、Chat/运行时打包、本地 premerge 四个直接检查与17个选择检查通过,公共边界扫描无新增问题。premerge 分类本身没有覆盖全部 Rust 语义,因此实际安装、真实 HTTP 身份/路由、拒绝和清理由补充验证承担。未查询、轮询或等待远端 CI。后端 HTTP 能服务不等于原生窗口已渲染,更不等于签名升级或用户 Goal 已完成。
我的整体评价
真实服务检查复用 SelectedRuntime、ServiceSet、既有安装器和 Core 路由,不另建身份、数据或服务状态 owner。当前 PR 边界是仅测试编译的真实后端检查、两个合成入口保护以及对应的操作说明。
结论为 APPROVE,作为完整可运行的后端验证增量。旧统计阻断点在当前 head 有直接正反证据;普通发布行为和用户交互保持不变。检查价值在于把真实安装产物、CLI 路由与监督器连起来,持续服务和重开有了回归保护;它不提前关闭原生窗口或完整 Goal 的父级验收。采用了当前建议中“先核对用户可用结果、分清交付边界”的评审方式,但建议本身不是本次效果证明或行动授权。批准仅指本次源码评审,合并就绪、历史阻断收口与合并授权分别回读;本轮不授予合并或评审撤销权限。
English verdict: APPROVE — a1303b8; both synthetic entry guards, real private installer, real ServiceSet identity/reopen/cleanup and isolated telemetry controls pass. Local native/static/build and premerge validation passed; remote CI was not consulted.
songoow
left a comment
There was a problem hiding this comment.
动机
这个 PR 要补的是一个验证缺口:桌面端的原生启动监督器此前只有合成监听器层面的生命周期测试,没有人用生产 ServiceSet 去启动真正安装后的 Core。受影响的是 Desktop 维护者与发布验证者:他们要在真实安装的 Core 上确认原生启动监督器能拉起两项服务,而不是只让合成监听器返回正确标记。如果不合并,维护者只能假定两条生产服务命令在真实产物上也能启动、也能读空注册表、也会拒绝过期身份,而这类假设一旦出错,代价是发布后才发现桌面启动失败或读到别人的数据。改动前,仓库里只有合成生命周期测试,没有任何用例用生产 ServiceSet 启动安装后的 Core,配方也没有显式关闭使用遥测;改动后,新增的 opt-in Unix 用例在一次性目录里自建空注册表、连续两次启动并停止生产 Status/Chat 服务、拒绝过期身份,两条 opt-in 用例都在任何 Core 调用前要求 LOOPX_USAGE_PING=0。可观测结果是:缺少遥测退出开关时两条 opt-in 用例在任何 Core 调用之前就失败退出(同一断言表达式实测退出码 101),README 配方在 installer/CLI 之前显式导出该开关,受审查 head 的必需检查跑完了完整 cargo test 与 clippy。本 PR 不改动生产选择器、安装器、服务行为和前端界面,也不声称已覆盖自动运行时选择、原生窗口重开、已签名替换或渲染后的 UI。仍未交付的是父级验收的其余部分:跨新旧/离线运行时的自动选择、已签名升级失败、完整原生窗口重开、持续运行与其他操作系统。
需要说明这次审计的时间顺序:PR 在我绑定 head 的过程中被合并,合并提交是 aa259d13488c0bfc04016bbfac7092154257e084,受审查 head 是 4864b676036a9d6a0062a9071a55d87afee7cc8e(合并 main 后的分支头),合入前的最后内容提交是 a1303b8197a36e0f26288b7e8833b7df8ba8d9be。git diff a1303b8197a36e0f26288b7e8833b7df8ba8d9be..4864b676036a9d6a0062a9071a55d87afee7cc8e -- apps/desktop/loopx-control-plane/ 为空,说明合入 main 没有改动本 PR 的四个文件;因此下面的结论针对 4864b676036a9d6a0062a9071a55d87afee7cc8e 的完整 PR 内容。
改动思路
改动分三块,各自停在合适的边界上。第一块是新的 opt-in 用例 real_private_runtime_serves_and_rejects_stale_identity:它自己持有一次性数据根,在临时目录里写空注册表 {"goals":[]},再用一个 0700 的一次性 wrapper 脚本把生产 CLI 路由钉到 --registry 与 --runtime-root,随后走生产 ServiceSet::start 启动真实 Status/Chat 两个服务。之所以用 wrapper 而不是改生产代码,是因为生产服务命令固定带 --global-registry,而 explicit_global_registry(args.runtime_root, ...) 在给了 --runtime-root 时解析出的正是同一个 state/registry.global.json,两条钉法指向同一个文件,用例再用 status["registry"] 断言这一点,因此不需要为测试新增第二个身份或 provider。第二块是遥测退出检查:两条 opt-in 用例的第一行都要求 LOOPX_USAGE_PING=0,否则在任何 Core 调用之前就 panic。第三块是 README 的复现配方,在 installer 与两次 cargo test 之前导出该开关,并写清能证明什么、不能证明什么。每个机制都留在正确的边界:真实安装与一次性数据目录的断言属于测试用例本身,遥测退出检查作为进入条件放在两条 opt-in 用例的第一行,服务启停与清理继续由既有 ServiceSet 及其 Drop 实现负责,因此现在不需要进一步简化。本 PR 的交付边界是一个可独立复现的真实后端验证增量加上合成运行的遥测退出检查;自动运行时选择、签名替换与窗口重开留给父级验收继续跟踪。
| 路径 | 角色 | 是否影响生产行为 |
|---|---|---|
apps/desktop/loopx-control-plane/src-tauri/src/services_real_runtime_tests.rs |
新增 opt-in Unix 真实后端用例 | 否,cfg(all(test, unix)) |
apps/desktop/loopx-control-plane/src-tauri/src/services.rs |
仅注册测试模块 | 否 |
apps/desktop/loopx-control-plane/src-tauri/src/bundled_runtime.rs |
既有 installer 用例加遥测进入检查 | 否,#[ignore] 用例内 |
apps/desktop/loopx-control-plane/README.md |
维护者复现配方与边界说明 | 否,文档 |
具体改动
四个文件共 +170/-0:services_real_runtime_tests.rs 新增 127 行测试,services.rs 新增 4 行模块注册,bundled_runtime.rs 新增 5 行进入检查,README.md 新增 34 行配方与说明。生产代码零改动,这是判断风险的关键事实:services.rs 里唯一的改动是文件末尾的 #[cfg(all(test, unix))] #[path = "services_real_runtime_tests.rs"] mod real_runtime_tests;。
关键代码讲解
apps/desktop/loopx-control-plane/src-tauri/src/services_real_runtime_tests.rs:38起的进入断言:assert_eq!(env::var("LOOPX_USAGE_PING").as_deref(), Ok("0"), "synthetic Core qualification requires LOOPX_USAGE_PING=0")。它是函数体的第一条语句,早于读取LOOPX_TEST_PRIVATE_RUNTIME、早于创建临时目录、早于启动任何 Core,因此“缺少退出开关”不会变成一次带遥测的真实安装。- 同文件
:46到:69的隔离装置:tempfile::tempdir()得到 owned 数据根,fs::canonicalize后写registry.global.json,再生成 0700 的/bin/shwrapperexec <真实 loopx> --registry <临时注册表> --runtime-root <临时状态目录> "$@",路径用单引号转义以支持空格、引号与$。 - 同文件
:75到:107的两次重开循环:每轮ServiceEndpoints::allocate(true)、ServiceSet::start(&runtime, &endpoints, |_| {}),对SERVICE_KINDS两个服务都要求probe_on_port(..., Some(&identity))返回Probe::Matching,然后断言/status.json的goal_count == 0且registry等于临时注册表路径、/api/chat/sessions为空、/chat/返回<!doctype html>;再services.stop()并assert_stopped要求两个端口都回到Probe::Unavailable。 - 同文件
:111到:122的过期身份反例:把真实 identity 的source_revision改成 40 个零,ServiceSet::start必须以包含unexpected listener的错误失败(生产路径把它映射为Probe::Stale),之后再次assert_stopped,同时验证collect会停掉已经成功启动的 peer 子进程。ServiceSet的Drop实现也调用stop(),所以中途断言失败不会漏下监听者。 src/bundled_runtime.rs:370起的同一进入断言加在既有的real_private_installer_keeps_the_default_cli_owner上,保证安装类合成运行也不会在未退出遥测时执行。
规格依据来自上游评审意见 https://github.com/loopx-project/loopx/pull/6727#discussion_r4302275742,审查修订 4864b676036a9d6a0062a9071a55d87afee7cc8e。该意见的最小修复被拆成三条判据:判据 6727-T1 要求在 installer/CLI 之前显式 export LOOPX_USAGE_PING=0 并让同一合成检查把选择传给子进程,实现于 apps/desktop/loopx-control-plane/README.md:362(子进程通过继承环境拿到同一开关,configure_runtime_environment 只覆盖 PATH,不会剥掉该变量);判据 6727-T2 要求缺少退出开关时不得调用 Core,实现于 services_real_runtime_tests.rs:38 与 bundled_runtime.rs:370,验证见 validation_matrix:material_negative_or_failure;判据 6727-T3 要求不改动产品默认遥测与用户设置,实现为“零产品改动”,loopx/usage_ping.py:124 的 LOOPX_USAGE_PING == "0" or DO_NOT_TRACK == "1" or CI == "true" 判定未被本 PR 触碰。
对主干的风险
最强回归场景是“合成检查被当成真实采用”:维护者在一台有真实共享状态的机器上跑这条配方,安装与两次服务启动都被计入使用遥测。这个方向已被进入断言挡住,因为断言在函数体第一行,早于读取任何路径环境变量。我实测了同一断言表达式的行为:用 1.95.0 工具链单独编译这段表达式后,LOOPX_USAGE_PING 未设置时退出码 101 并打印 synthetic Core qualification requires LOOPX_USAGE_PING=0,设为 1 同样 101,设为 0 才通过。负向链路还有两条:过期身份必须报 unexpected listener 并停掉两个子进程;断言中途失败时 ServiceSet::Drop 仍会 kill 并 wait。爆炸半径限于测试代码与文档,生产选择器、安装器、服务命令都没有被修改。
验证边界必须写清楚。受审查 head 上我实际执行的是:cargo fmt --all --check(退出码 0,无输出)与 cargo check --lib --tests(Finished dev profile ... in 9.41s),前者证明格式,后者证明包含新测试模块在内的全部测试目标能通过类型检查;本地链接并运行 Rust 单测没有做成,因为仓库磁盘只剩约 1.6 GiB,而这个 crate 需要 bundle 资源(build.rs 要求 ../runtime/identity.json,我用占位 bundle 满足编译、并在报告中明确那是编译占位而非真实产物)且调试依赖需要数 GiB 空间。作为补充,我读取了受审查 head 的必需检查:Signed Desktop Updates / validate 在 4864b676036a9d6a0062a9071a55d87afee7cc8e 上成功,其步骤 Run cargo test --locked && cargo clippy --all-targets --locked -- -D warnings 为 success,说明完整 cargo test 与 -D warnings 的 clippy 在这个精确 head 上跑过;“macOS desktop”与“Windows desktop”两个必需桌面检查同样 success。同一个 head 的 Python Tests 运行整体被取消,其中 stage2c-correctness-e2e 在 “Require every Stage 2C lane” 步骤失败,原因是并行的 stage2c 分片被取消而不是某条用例失败;这与本 PR 的四个 Rust/文档文件无关。另外我尝试运行 PR 引用的 6 条 Python 遥测用例:在内容相同的 a1303b8197a36e0f26288b7e8833b7df8ba8d9be 上是 6 passed in 30.40s,但在 4864b676036a9d6a0062a9071a55d87afee7cc8e 上重复运行时出现不同的参数化因 20 秒子进程超时而偶发失败(当时主机 load average 约 117),同一个用例每次失败的分片都不同,属于主机负载导致的抖动而非确定性回归——该文件在本 PR 中没有任何改动。
我的整体评价
交付判断是 justified_increment:PR 命名的那一块(用生产监督器启动真实安装的 Core,并用一次性注册表、两次重开、过期身份拒绝和遥测退出检查把结论钉住)在受审查 head 上已经完整实现并可复现;父级验收的其余部分(自动运行时选择、签名升级失败、完整窗口重开、持续运行、其他操作系统)仍在其自己的跟踪范围。长期影响是 preserved:生产路径零改动,新增的是一条可重复执行、会在失败时立刻暴露的真实后端检查;用户体验维度是 not_applicable,因为没有用户可见界面或 CLI 契约变化,README 配方只面向维护者。
observable_semantics 的比较是:基线 a3e56a38cfa442a65a0f6f84572e226d06f4d6fb(合并前 main)没有任何用例启动安装后的 Core,也没有进入检查;head 上新增的用例把“身份匹配 + 一次性注册表 + 两次重开 + 过期身份拒绝 + 停止后端口不可用”作为可观测不变量,并用进入断言把合成运行的遥测路径关掉。default_off_isolation 是 isolated:新用例是 #[ignore] 的 opt-in 用例,默认 cargo test 只编译不执行,生产开关与默认值没有任何变化。code_volume 判为 necessary:+170/-0 全部落在测试与文档,没有新增抽象层、没有新增第二套 CLI 参数或状态契约;兼容性评估是 not_applicable,因为这些代码只存在于测试编译单元。authority_semantics 与 guidance_vs_obligation 都是 not_applicable:没有新增公开协议名、权限或 actor 生命周期,README 里的“必须导出退出开关”是维护者操作说明,真正强制它的是测试里的断言。
没有阻塞性发现。剩余缺口已在上文列出,其中最能影响后续判断的一条是:我没有亲自执行带真实 sealed Core 的 opt-in 运行,这条证据仍来自作者提交的验证记录,我验证的是它的代码结构、参数解析一致性、进入检查和精确 head 上的必需 CI。审查 head:4864b676036a9d6a0062a9071a55d87afee7cc8e。
Reviewer: model_agent, model DeepSeek Flash, provider DeepSeek, self_reported.
English verdict: APPROVE - 4864b67: the opt-in real-Core qualification plus telemetry entry guards is test-only and docs-only (+170/-0), fmt and cargo check --lib --tests pass locally, the exact head's required desktop validate job ran cargo test and clippy -D warnings green, and the guard fails closed without LOOPX_USAGE_PING=0; the sealed-Core run itself was not re-executed and is the one remaining evidence gap.
Goal And Delivered Outcome
Qualify the Desktop startup supervisor against an actual installed Core, following #6680 and roadmap S4/S5/S12. Synthetic lifecycle tests alone do not prove that both production service commands can launch the installed artifact, serve the packaged Chat document, and enforce its identity together.
The opt-in Unix test owns a fresh empty registry and data directory. It runs the production
ServiceSet, verifies both artifact identities and zero Goals/Sessions before a rendered frontend is opened, stops and reopens both services, and rejects a deliberately stale expected identity without leaving owned listeners. The README gives one reproducible private installer plus service qualification sequence.The latest revision also fixes the telemetry isolation review finding: both opt-in tests reject an invocation without
LOOPX_USAGE_PING=0before calling Core. The recipe sets the opt-out explicitly, including before building the synthetic runtime. A disposable Goal registry is not a machine-wide telemetry boundary; user consent and production telemetry defaults are unchanged.Author Declaration
main; branch merge base:d4487a7c0a332365fc80ee3ca43d421bdf510d42.ServiceSetand artifact probes; actual backend checks belowPlacement And Scope
The production selector, installer, service behavior and UI are unchanged. Production code gains only test-module wiring. The real-backend test stays next to the established Rust native supervisor; no provider, shared state vocabulary or second authority is introduced. The future-facing pass keeps installed-backend qualification separate from synthetic cases without creating a test framework. The two telemetry assertions do not justify another abstraction.
This is an independently reproducible validation increment. The parent acceptance remains open for automatic selection across newer/older/offline runtimes, signed upgrade failures, complete packaged-window reopening, sustained operation and other operating systems. This PR proves service reopening, not native window reopening or rendered UI. It launches no model and does not replace the installed App.
Validation
Tested source:
a1303b8197a36e0f26288b7e8833b7df8ba8d9be(identical final diff tested before commit). Actual sealed Core fixture:2.0.0a1, sourcef9bdae67596c185cebc81dc555dd6a3e0242e9c5, installed into disposable storage. The native test source and frozen Core fixture are identified separately; this is not single-revision release qualification. All runs below finished.Commands run from
apps/desktop/loopx-control-plane/src-tauriunless otherwise noted; opt-in setup is in the README.cargo fmt --all --check;cargo clippy --all-targets -- -D warnings;cargo build --releasecargo test --libcargo test --lib real_private_installer_keeps_the_default_cli_owner -- --ignored --nocapturecargo test --lib real_private_runtime_serves_and_rejects_stale_identity -- --ignored --nocaptureLOOPX_USAGE_PING=1test_disabled_synthetic_real_cli_never_contacts_collectorcases andtest_profile_cli_and_typed_sender_cannot_override_disabled_collection(repository pytest tests)git diff --check; staged bilingual RFC checkcqr_cb3378e10fae337c3d1fverified valid; no safe-fix pass or unresolved scope risksThe existing separate incognito WebKit recovery regression and paired baseline were executed for the preceding revision: recovery succeeds, baseline intentionally fails, and both issue zero non-GET requests. This revision changes neither navigation nor that regression and does not rerun its native window case. Required CI and independent review must still assess the new exact head. An ordinary unit-suite run alone does not qualify the ignored actual-Core tests.
Frontend / Visual Evidence
UI impact: none. No first viewport, navigation, control, CSS or frontend asset changes. Before/after screenshots are not applicable. Serving packaged HTML is not a rendered-browser claim.
Boundary Checklist