You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "sunheyi6 (via GitHub)" <gi...@apache.org> on 2026/09/03 14:31:06 UTC
[PR] feat(computer-use): add guarded Windows maka.cu/2 integration [maka]
sunheyi6 opened a new pull request, #4668:
URL: https://github.com/apache/maka/pull/4668
## Summary
This replacement is rebuilt from the current `apache/main` after #4497 and supersedes the oversized integration attempt in #4595.
- Reuse the existing `MakaCuService` and shared `maka.cu/2` backend on Windows; no second protocol or duplicate Windows service.
- Select the `windowsCu` artifact from the Desktop manifest and verify the complete helper directory by file set, size, and SHA-256 before spawning it.
- Package the helper only when the native release artifact exists.
- Add `prepare-windows` to record the exact artifact digest and provenance. `distributionReady` cannot be enabled by a command-line flag; it remains false until the exact artifact has CI provenance, Authenticode signing, clean-machine validation, and packaged conversation E2E evidence.
- Keep the product diff focused: no generated browser JSON, raw outputs, experiments, or compatibility-input subsystem from the previous attempt.
## Validation
- `npm run build --workspace @maka/computer-use` — passed
- `node --test scripts/prepare-windows-cu-helper.test.mjs` — 4 passed
- Explicit Windows manifest/digest selection check — passed
- Desktop full typecheck remains blocked by unrelated existing main-branch type errors; no diagnostics reference the changed host or selector files.
## Release boundary
This PR does not claim clean-machine or packaged real-conversation acceptance. The existing #4595 remains open for comparison; it is not modified or closed by this PR.
<details>
<summary>中文翻译</summary>
## 摘要
本 replacement 基于包含 #4497 的最新 `apache/main` 重建,用于替代 #4595 中体量过大的集成尝试。
- Windows 复用现有 `MakaCuService` 和共享的 `maka.cu/2` 后端,不新增第二套协议或重复的 Windows service。
- Desktop 从 manifest 选择 `windowsCu` artifact,并在启动前按文件集合、大小和 SHA-256 校验整个 helper 目录。
- 只有在 native release artifact 存在时才打包 helper。
- 增加 `prepare-windows`,记录 exact artifact digest 和 provenance。`distributionReady` 不能通过命令行参数开启;在 exact artifact 具备 CI provenance、Authenticode 签名、clean-machine 验证及 packaged conversation E2E 证据前,始终保持 false。
- 保持 product diff 聚焦:不带回上一版中的 generated browser JSON、raw outputs、experiments 或兼容输入子系统。
## 验证
- `npm run build --workspace @maka/computer-use` —— 通过
- `node --test scripts/prepare-windows-cu-helper.test.mjs` —— 4 个通过
- Windows manifest/digest 选择专项检查 —— 通过
- Desktop 全量 typecheck 仍被主线已有的无关类型错误阻断;本次修改的 host 和 selector 文件没有诊断。
## 发布边界
本 PR 不声称已经完成 clean-machine 或 packaged real-conversation 验收。现有 #4595 保留用于对比,本 PR 不修改也不关闭它。
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org
Re: [PR] feat(computer-use): add guarded Windows maka.cu/2 integration [maka]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #4668:
URL: https://github.com/apache/maka/pull/4668#issuecomment-6137965496
<!-- maka-lifecycle:stale-close -->
This pull request has been closed because it received no new commits during the 7-day grace period. This is not a judgement on the merit of the change; it only keeps the review queue aligned with work that is actively in flight.
The branch and review history are preserved. Push a new commit and reopen the pull request whenever the work is ready to continue.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org
Re: [PR] feat(computer-use): add guarded Windows maka.cu/2 integration [maka]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #4668:
URL: https://github.com/apache/maka/pull/4668#issuecomment-6008973467
<!-- maka-lifecycle:stale-warning -->
This pull request has had no new commits for 30 days and has been marked stale. It will be closed in 7 days unless a new commit is pushed.
Comments do not reset this timer: only a new commit does. If the pull request is intentionally long-lived, a maintainer can apply the `pinned` label.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org
Re: [PR] feat(computer-use): add guarded Windows maka.cu/2 integration [maka]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed pull request #4668: feat(computer-use): add guarded Windows maka.cu/2 integration
URL: https://github.com/apache/maka/pull/4668
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org
Re: [PR] feat(computer-use): add guarded Windows maka.cu/2 integration [maka]
Posted by "sunheyi6 (via GitHub)" <gi...@apache.org>.
sunheyi6 commented on PR #4668:
URL: https://github.com/apache/maka/pull/4668#issuecomment-5534339482
@M4n5ter @hqhq1025 cc
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org
Re: [PR] feat(computer-use): add guarded Windows maka.cu/2 integration [maka]
Posted by "sunheyi6 (via GitHub)" <gi...@apache.org>.
sunheyi6 commented on PR #4668:
URL: https://github.com/apache/maka/pull/4668#issuecomment-5537816148
Codex-assisted scope review, posted on behalf of @sunheyi6. The intended Windows product contract is now **background-only desktop automation**: it must not take over the user's active window, keyboard, mouse, or clipboard. Browser workflows are explicitly routed to Browser Use/OpenCLI because that layer can use browser-native page/DOM/accessibility state, tabs, navigation, and commands with stronger targeting and verification. Reimplementing browser control here would duplicate the browser stack and pressure the desktop executor to add coordinate, global-keyboard, or foreground fallbacks that violate the non-interference guarantee. This is an ownership boundary, not a loss of browser capability. The full design update is tracked in #3785.
This PR remains a useful guarded host/packaging scaffold while `windowsCu.distributionReady` is `false`. Before enabling distribution, the host/release side should enforce the following gates rather than relying on declared provenance alone:
- when Windows distribution is enabled, a missing helper must fail packaging instead of being silently omitted;
- verify the exact packaged helper file set, sizes, and SHA-256 digests;
- perform real Authenticode verification for the exact artifact;
- require a locked build with an explicit Windows target and either a genuinely self-contained binary or a verified set of shipped runtime dependencies;
- require clean-machine packaged conversation E2E evidence for the background-only contract;
- keep `distributionReady: false` until those checks are implemented and passing.
The E2E release gate must keep a user typing in a foreground app while Maka manipulates a different background desktop app, and verify that foreground HWND/PID, pointer position, clipboard, and user keystroke destination remain unchanged. A typed refusal is acceptable; silent foreground/global-input fallback is not.
No second host service, browser path, foreground compatibility mode, or duplicate public protocol is needed in this PR. The minimal integration is the existing shared service plus the qualified Windows helper.
<details>
<summary>中文说明</summary>
这是一条由 Codex 协助、代表 @sunheyi6 发布的范围审查说明。Windows 的产品合同现明确为**只做后台桌面自动化**:不能抢占用户当前窗口、键盘、鼠标或剪贴板。浏览器工作流明确路由给 Browser Use/OpenCLI,因为它可以直接使用页面/DOM/无障碍状态、标签页、导航和浏览器命令,定位与结果验证都更可靠。如果这里再实现浏览器控制,不但重复建设,还会迫使桌面执行器加入坐标点击、全局键盘或抢前台 fallback,破坏不干扰保证。这是职责边界,不是丢失浏览器能力。完整设计更新记录在 #3785。
只要 `windowsCu.distributionReady` 仍为 `false`,本 PR 可以作为有保护的 Host/打包脚手架保留。在允许分发前,Host/发布侧必须实际执行以下门禁,不能只相信 provenance 中声明的字段:
- 开启 Windows 分发时,helper 缺失必须导致打包失败,不能静默跳过;
- 校验安装包内准确的 helper 文件集合、大小和 SHA-256;
- 对确切产物执行真实 Authenticode 验证;
- 使用锁定依赖和明确 Windows target 构建,并保证二进制确实自包含,或随包携带且验证全部运行时依赖;
- 在干净机器上通过满足严格后台合同的真实安装包会话 E2E;
- 在这些检查尚未实现并通过前,保持 `distributionReady: false`。
发布 E2E 必须让用户持续在前台应用打字,同时 Maka 操作另一个后台桌面应用,并验证前台 HWND/PID、鼠标位置、剪贴板和用户按键去向都不变。明确拒绝是可接受结果;静默降级到前台/全局输入不可接受。
本 PR 不需要增加第二套 Host Service、浏览器路径、前台兼容模式或重复的公开协议。最小集成就是现有共享 Service 加上通过资格验证的 Windows helper。
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org
Re: [PR] feat(computer-use): add guarded Windows maka.cu/2 integration [maka]
Posted by "sunheyi6 (via GitHub)" <gi...@apache.org>.
sunheyi6 commented on PR #4668:
URL: https://github.com/apache/maka/pull/4668#issuecomment-5550256004
Pushed 40784e654 (schema compatibility), 754a41d39 (unknown outcomes and snapshot lifecycle), and 90aa98ce4 (turn-scoped tool guidance). Companion executor fix: https://github.com/maka-agent/maka-cu/pull/8, commit f8e9fde. The general Electron user-command environment fix is intentionally excluded from this PR and pushed separately to sunheyi6/maka-agent:codex/fix-user-command-electron-env; that branch does not yet have a new PR.
### Why the strict-background policy changed
The previous Windows executor refused a target merely because the user brought its window to the foreground to watch the result. The product contract now prohibits actively disturbing focus and input, rather than requiring the target to remain in the background. Semantic UIA actions can run on an already-foreground window.
Process/window/element identity checks and desktop-state monitoring remain. There is no new activation, focus-stealing, physical-pointer movement, global keyboard injection or fallback path. Uncertain actions remain `unknown`; subsequent observation confirms application effects without promoting helper verification.
### Validation and release scope
A local full-permission Maka conversation created a SunCode conversation, entered and sent the requested greeting, and read the response while SunCode was foreground and visible. The helper actions remained `unknown`, while fresh observations confirmed the completed workflow. Windows MSVC tests: 17 passed; runtime/protocol tests: 106 passed. Windows backend mock tests were blocked by `spawn EFTYPE`.
This is product source repair, not a test-only policy bypass. Local executables, profiles, logs and temporary artifact hashes were not pushed. Formal artifact pinning, automatic permission admission, packaged/clean-machine E2E and broader concurrent-user/application coverage remain unqualified; `distributionReady` remains false.
<details>
<summary>中文翻译</summary>
已推送 40784e654(参数兼容)、754a41d39(未知结果与观察生命周期)和 90aa98ce4(轮次工具提示)。配套原生执行器修复位于 maka-cu PR #8 的 f8e9fde。通用 Electron 用户命令环境修复刻意不放入本 PR,单独推送至 sunheyi6/maka-agent 的 codex/fix-user-command-electron-env 分支,目前尚未新建该分支的 PR。
### 为什么调整严格后台策略
原 Windows 执行器仅因用户将目标窗口置前查看操作效果,就拒绝操作。本次将产品约束从“目标必须保持后台”调整为“执行器不得主动干扰焦点与输入”,允许对已经处于前台的窗口执行 UIA 语义操作。
保留进程、窗口和元素身份校验及桌面状态监测,不新增窗口激活、抢焦点、物理鼠标移动、全局键盘注入或回退路径。不确定的动作仍返回 unknown,通过后续观察确认应用效果,不将 helper 验证升级为成功。
### 验证及发布范围
本地完全权限 Maka 对话在 SunCode 前台可见时完成新建对话、输入发送指定问候语和读取回复。helper 动作保持 unknown,由新的观察确认流程已完成。Windows MSVC 测试 17 项通过,runtime/protocol 测试 106 项通过;Windows backend 模拟测试受 spawn EFTYPE 阻塞。
这是产品源码修复,不是测试专用的策略绕过。本地执行器、测试配置、日志及临时制品哈希均未推送。正式制品绑定、自动权限准入、打包和干净机器 E2E,以及更广泛的并发用户和应用覆盖仍未完成验证;distributionReady 保持 false。
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org