Repository navigation
fix(ci): 修复 Windows 路径身份与 macOS 原生回归环境 - #4
Merged
Merged
Conversation
added 3 commits
October 21, 2026 11:17
…ntity The first native Windows CI race run failed service startup because the OS reported a short 8.3 image path while LaunchRecord stored its resolved long path. Resolve both absolute paths in the shared comparison used by startup, status and process ownership checks. Missing paths remain unknown and a separate hard-link path does not become the same installation. PID creation stamps and authenticated instance checks are preserved. Validation: the real Windows short-path child test failed against the old code with service executable identity mismatch, then passed after the fix. All four affected Windows package suites (routercontrol, routerservice, routeracceptance and cmd/wefto) passed; native vet and gofmt/diff checks passed. The complete three-platform hosted gate will run after this push. The original team main run passed Linux; Windows failed as above and macOS is still running. Signed-off-by: yzxu11 <[email protected]>
The macOS diagnostic run 39538246748 showed protected layouts rejecting the system /var symlink. Resolve the runner-owned temporary root once and pass its physical path to Node and Go tests. Keep the product path protections intact. actionlint 1.7.12 and git diff --check passed; native hosted validation follows this push. Signed-off-by: yzxu11 <[email protected]>
…state macOS has no external PID identity backend. Its native diagnostic correctly rejected cross-process control, while the common cleanup test expected a successful identity lookup. Exercise explicit refusal and an unchanged unknown instance record on unsupported platforms. Keep the real child cleanup cases on Windows and Linux. Windows cleanup regression and formatting/diff checks passed; the macOS diagnostic provides the before-fix failure and will validate the new branch. Signed-off-by: yzxu11 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
首次团队主干 Actions 暴露了原生平台的路径差异。此 PR 修复 Windows 服务启动身份校验,并校正 macOS 回归环境与平台能力预期。
LaunchRecord已存储长路径。共享比较处解析两侧的现存绝对路径;保留 PID 创建时间、实例认证、未知路径拒绝和不同硬链接安装路径的区分。新增真实短路径子进程启动回归。TMPDIR/TMP/TEMP,避免/var→/private/var别名触发现有安全路径保护。产品的路径保护保持原有边界。验证记录:
/var路径保护和不支持外部 PID 控制的测试预期错误。修正后的诊断和三平台完整运行正在验证。另有未解决的 Windows 共享包问题:
internal/filememo/TestReadWhileReplaced在原生 race 下出现 961 次临时文件缺失,导致完整门禁失败。steady.Stat/ReadThere的缺失重试窗口和filememo.statFile的gone标记可能参与触发,尚需受控时序复现;本机普通测试通过不能证明它已解决。完整日志和 summary 保存在第一轮修复分支运行的 Windows artifact 中。团队仓库关闭了 Issues(创建失败,GitHub 返回 410),因此先在此说明中保留该问题、失败输出和运行链接。没有删除、跳过或忽略这个检查,也没有将该问题标为已解决。最终托管结果将在完成后更新。
Windows shared-file regression follow-up
原生 Windows 2025 x64、Go 1.26.8 的完整产品回归在共享包
internal/filememo出现并发替换读取失败:a640225d336d59bb206db381cbae776d71e5b533(PR 合并候选由 Actions checkout)go test -race -count=1 -p 1 -timeout 45m ./internal/filememo。TestReadWhileReplaced运行 5.01 秒,统计到 961 次缺失读取;日志包含open .../logins.json: The system cannot find the file specified和GetFileAttributesEx ...。cmd/wefto、routerservice、routeracceptance、routercontrol均通过 race。前一轮此包通过;本机普通测试单次通过,均不能证明这个并发问题已解决。现有测试启动两个 goroutine 持续写临时文件并替换目标文件,同时调用
filememo.Read。代码检查发现steady.Stat/ReadThere对不存在状态仅进行 15 次约 1ms 的等待;filememo.statFile在一次缺失后会把路径记入gone,后续 stat 直接使用os.Stat。这可能放大持续替换期间的缺失窗口;是否由重试窗口被连续替换占满、Windows 文件系统调度或其他条件触发,仍需确定性注入和原生 race 重复验证。第二次失败:候选 68c86656 的 Windows job。同一测试运行 5.00 秒,统计到 16883 次缺失读取;
steady.ReadThere的 open 和后续 stat 均返回文件不存在。本次internal/filememo和internal/steady相对团队主干没有改动,失败发生在 race 阶段,后续 vet/Chromium/WebKit 被门禁阻断。Windows 完整回归当前仍失败。后续应保留完整正文读取、真正删除/权限错误的失败行为,并用受控的替换/读取时序复现。不要用忽略失败、返回空账户或仅重复 CI 得到一次绿色来关闭此问题。完整失败日志与 summary 在两次运行的 Windows artifacts 中。