13 Commits

Author SHA1 Message Date
guyong
f9988cf127 fix(browser): preserve normal macOS Chrome quit
Signed-off-by: guyong <guyong@xd.com>
2026-11-04 20:46:17 +08:00
Dash
f4be3f8bd0 perf(browser): 消除固定 DOM 读取的交互等待并保留生命周期检查
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
2026-10-27 20:49:33 +13:00
Dash
a7976a999c fix(browser): 保留输入预检修复额度及有效配方状态
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
2026-10-23 01:45:46 +13:00
Dash
4cd49ac274 feat(browser): 优化操作观察并支持配方按使用校验与修复
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
2026-10-23 01:45:45 +13:00
Dash
9750d5567d fix(browser): 通过 CDP 正常关闭 Windows 浏览器
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
2026-10-19 20:28:05 +13:00
Dash
a5488d8c91 fix(browser): 保留重启登录状态并等待浏览器正常退出
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
2026-10-19 13:42:38 +13:00
Arthur
37385a2b1a fix(browser): keep agent-read pages in background (#5834)
* fix(browser): keep agent-read pages in background

Signed-off-by: Arthur <266606080+arthur-tech-learn@users.noreply.github.com>

* fix(browser): cover background tab edge cases

Signed-off-by: Arthur <266606080+arthur-tech-learn@users.noreply.github.com>

* fix(browser): preserve navigation policy for background targets

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>

---------

Signed-off-by: Arthur <266606080+arthur-tech-learn@users.noreply.github.com>
Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
Co-authored-by: Arthur <266606080+arthur-tech-learn@users.noreply.github.com>
Co-authored-by: Dash <125997726+dashhuang@users.noreply.github.com>
2026-10-12 21:27:51 +08:00
Yecheng Fu
53363c7296 feat(browser): add per-start (unauthenticated) proxy server support
Launch Chrome with a caller-selected proxy, a PAC allowlist floor (including
PAC dnsResolve for WSS/pre-attach), and a lifetime CDP request gate. Authenticated
proxies are rejected at parse time.

The CDP guard identity follows the live managed profile: Cindy-real and a
relocated CDP port are used for Fetch, liveness, and adopted-close instead of
the isolated 18800/Cindy defaults.

Signed-off-by: Yecheng Fu <yechengfu1987@gmail.com>
2026-09-09 08:12:52 +08:00
Dash
f1dd63ec52 feat(desktop): 使用系统浏览器登录态,并拆分链接打开方式 (#3596)
* feat(desktop): 使用系统浏览器登录态,并拆分链接打开方式

设置「自动操作」增加默认关闭的「使用我的浏览器登录态」:同意后把系统
Chrome / Edge / Brave 当前 profile 的 Cookies 与已存密码拷到独立的
Cindy-real,关掉开关即删除拷贝,隔离身份 Cindy 不动。链接打开拆成外部
网页与内部网页两套偏好。已有磁盘权限时不再弹完全磁盘访问引导;打开
Agent 专用浏览器不再因冷启动多开一个页签。

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>

* fix(desktop): 登录态拷贝改为原子替换,关掉开关才落盘

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>

* fix(desktop): 切换登录态前必须停掉托管浏览器

stop 失败或无法确认时不再 persist 开关,避免 POSIX 上 unlink 后仍被打开的 Cookie 句柄留着。
Main 改为静态引入 node:sqlite backup;config-dir 子路径刷新 runtime 根,避免 inbound media 冻在 ~/.xdt-maker。
userDataDirFor 按目标 OS 拼路径,修 Windows CI。

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>

* fix(desktop): 隐式启动也先拷登录态,并确认浏览器已停

open/tabs 会绕过 /start 冷启动空 Cindy-real;同意使用登录态时
这些动作走同一扇快照门。停浏览器除 ok 外还要 data.stopped。
macOS 源探测补上 ~/Applications。

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>

* fix(desktop): 快照清掉残留站点存储,并记住重定位后的 CDP 端口

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>

* fix(desktop): 停浏览器时不热改托管身份,源探测对齐 Snap

Stop 前不再重建缺 executablePath 的 runtime 配置,避免 vendored
runtime 当成身份变化先杀进程再返回 stopped:false。
Linux 源探测对齐稳定版路径;Snap 二进制走对应 ~/snap profile。
隔离 Cindy 固定 18800,CDP 重定位只给同意拷登录态的 Cindy-real。

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>

* fix(desktop): 迟到快照不再激活已撤销的登录态

快照完成后、启动前再读同意开关;已关则清快照并回到隔离 Cindy。
崩溃后 remembered 端口上的无 pid leftover 先停再拷;
无 marker 的 18800 占用仍只重定位。

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>

---------

Signed-off-by: Dash <125997726+dashhuang@users.noreply.github.com>
2026-08-29 18:33:02 +08:00
tiammomo
14bf09755f feat(browser): detect Chrome Beta on macOS (#2157)
Signed-off-by: tiammomo <pearfl@qq.com>
2026-08-12 23:40:55 +08:00
happy9 Zhang
01c38b67b8 chore(browser-runtime): make sync.mjs runnable on Windows (#1834)
* chore(browser-runtime): make sync.mjs runnable on Windows

The vendoring sync script assumed POSIX-only paths:
- msys GNU tar treats `C:` drive letters as remote hosts and requires
  --wildcards for glob extraction; quoted Windows paths are converted to
  /c/... and tar gets --wildcards
- path.join emits '\' on win32, so LOCAL_PATCHES keys and the leaf 'src/'
  prefix filter never matched; normalize to POSIX separators

No generated artifacts change: contentHash stays identical to the lock.

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: happy9zhang <happy9zhang@users.noreply.github.com>

* fix: only apply msys tar compatibility on Windows

Greptile P1 + Codex P2: unconditionally injecting GNU tar's --wildcards
broke macOS maintainers' BSD/libarchive tar. The whole msys compatibility
path now runs only on win32; POSIX platforms keep the upstream command
byte-for-byte.

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: happy9zhang <happy9zhang@users.noreply.github.com>

* fix: inject --wildcards only for GNU tar (bsdtar compat)

On win32 the PATH may resolve to the system bsdtar/libarchive instead of
msys GNU tar; bsdtar treats unsupported options as fatal errors, so the
unconditional --wildcards injection aborted pnpm sync:browser-runtime.
Detect the tar implementation via `tar --version` (cached) and inject
--wildcards only for GNU tar; bsdtar matches extraction paths as
shell-style patterns natively, so no flag is needed there.

Greptile P1 round 1 (Windows bsdtar) / Codex P2 (BSD tar) — covers both.

Signed-off-by: happy9zhang <happy9zhang@users.noreply.github.com>

* fix: collapse double backslashes before msys path conversion

JSON-escaped paths (double backslashes) converted per-character produced
doubled msys separators like /c//Users//foo. Collapse the double
backslashes FIRST, then convert drive letters and remaining separators
(Copilot P1 round 2).

Signed-off-by: happy9zhang <happy9zhang@users.noreply.github.com>

* fix: resolve sh via the repo's posix-shell resolver

On win32 the PATH may only contain Git\cmd (not Git\bin), so a bare `sh`
would ENOENT and abort pnpm sync:browser-runtime. Resolve the Git-bundled
sh.exe via scripts/lib/posix-shell.mjs's resolvePosixShell (where.exe
derivation + Program Files / LOCALAPPDATA standard locations; non-win32
keeps PATH behavior). Fail with a clear install-Git message when no sh is
found (codex-connector P1, round 3).

Signed-off-by: happy9zhang <happy9zhang@users.noreply.github.com>

* fix: probe tar through the same shell that executes it

On win32 the Node process PATH may resolve `tar` to System32\bsdtar while
the Git sh resolves GNU tar — probing with execFileSync('tar') could then
report non-GNU and omit --wildcards, while the actual GNU tar in the sh
environment would treat quoted member patterns literally and abort the
extraction. isGnuTar() now probes `tar --version` through the resolved sh
(the same environment that runs the tar commands), keeping detection and
execution consistent (Greptile P1 + codex-connector P1, round 4).

Signed-off-by: happy9zhang <happy9zhang@users.noreply.github.com>

* fix: use English for the sh-resolution error message

The "could not locate a usable sh" error text was the only Chinese output
in the script; align it with the rest of the output language for
maintainability and readability (Copilot P1 round 5).

Signed-off-by: happy9zhang <happy9zhang@users.noreply.github.com>

---------

Signed-off-by: happy9zhang <happy9zhang@users.noreply.github.com>
Co-authored-by: happy9zhang <happy9zhang@users.noreply.github.com>
Co-authored-by: Claude <noreply@anthropic.com>
2026-08-06 22:31:50 +08:00
Dash
14def6b770 fix(desktop): 修复外置浏览器误拦代理 fake-IP 网站 (#1270)
* fix(desktop): allow browser navigation through proxy fake IPs

Signed-off-by: Dash <dashhuang@gmail.com>

* fix(desktop): narrow browser fake-IP SSRF policy

Signed-off-by: Dash <dashhuang@gmail.com>

* docs(browser): correct SSRF policy default

Signed-off-by: Dash <dashhuang@gmail.com>

---------

Signed-off-by: Dash <dashhuang@gmail.com>
2026-08-01 09:57:31 +08:00
Lizi
bb3f71d084 chore: Cindy 首次开源提交 / initial open-source release
Cindy 是心动网络 (X.D. Network Inc.) 的跨端 AI Agent 客户端。
本次提交包含 Desktop(Electron)、Mobile(Expo)及全部共享 packages
的完整源码,以 Apache-2.0 协议开源。

This is the first public release of Cindy, X.D. Network's cross-platform
AI agent client: the Electron desktop app, the Expo mobile app, and all
shared workspace packages, licensed under Apache-2.0.

- 许可与合规:根 LICENSE(Apache-2.0)+ NOTICE;第三方组件归属声明与
  SPDX SBOM 收口在 docs/legal/notices/,由 pnpm licenses:generate 生成。
- 社区文件:README / CONTRIBUTING / CODE_OF_CONDUCT / SECURITY / SUPPORT
  中英双语;issue / PR 模板与 CI workflow 在 .github/。
- 协议层以公开 submodule 引入:github.com/makecindy/cindy-protocol。
- 提交前已通过仓库门禁:全量 pnpm test:unit 与涉及 package 的 typecheck。

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-24 08:30:44 +08:00