Skip to content

feat(agents): configure explicit automatic resume arguments - #457

Open
WilliamWang1721 wants to merge 33 commits into
Kuddev:mainfrom
WilliamWang1721:codex/issue-323-agent-resume-args
Open

WilliamWang1721 wants to merge 33 commits into
Kuddev:mainfrom
WilliamWang1721:codex/issue-323-agent-resume-args

Conversation

@WilliamWang1721

@WilliamWang1721 WilliamWang1721 commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

Result / 用户结果

Closes #323. The GPUI Agent page now saves explicit per-Agent automatic-resume arguments as a JSON array, for example ["--yolo"] for Codex. Missing/empty configuration and [] keep the default command; [""] passes an explicit empty argument. No permission flag is enabled automatically and command history is never replayed.

Design / 设计边界

  • Shared settings own eleven additive agent_resume_args_<source> keys and reset behavior. The application parses literal JSON arrays; platform/agent_resume adapts native argv using existing shell quoting and Windows encoding. No dependency is added.
  • Cold recovery, resolved Pi session files, retry and the Codex recovery chooser use cached settings. Saved conversation identity, cwd and shell-ready submission retain their existing authority.
  • Invalid data fails recovery while preserving its target; CMD rejects double quotes, % and !. Manual palette resume, forks, runtime Agent start and legacy shell UI retain their existing scope.
  • Decision.

Evidence / 验证依据

Current source head: 7b4004409c2835a238f1c2c4a925ac0509f12146, based on upstream 9dd3d6491bfaaf902a4a3a248c02f36a47abae2d.

  • Current upstream native/lint run: lint passed; all five native platforms are in progress. Current architecture/settings/i18n contracts and PR size passed.
  • Fork native UI evidence is running. Workflow head b8ffd92a checks out the exact source head above. It exercises real input, keyboard Save, success/error feedback and clearing; it is not upstream CI.
  • Independent fork Windows argv reproduction demonstrated the prior PowerShell 5 embedded-quote/argument-boundary defect. The implementation now reuses the Windows native encoder for this binder. The current source includes a real Rust argv receiver invoked by PowerShell 5.1 and pwsh, covering quotes, backslashes, literal metacharacters and empty arguments; final-head outcomes remain pending.
  • Regression coverage includes settings round-trip/reset, rendered Save/reopen/invalid/clear, and cold recovery through echo/CommandStart/CommandDone/prompt events before retry and chooser submission. The real settings-writing fixture joins the existing nextest serial group and its asserted registry.

At least two author self-reviews completed, with changed diffs re-reviewed after repairs. All execution, formatting, architecture and builds run in GitHub Actions; no local automated tests/builds were run. Earlier-head passes are not claimed for this head. Native DPI/long-language and real provider CLI acceptance remain pending.

AI-assisted implementation and author self-reviews: GPT-6.1 SOL, reasoning effort high. Independent review supplied the linked native argv reproduction; its model/effort was not confirmed in this chat.

Required Review / 必须确认

  • CONTRIBUTING, architecture and project constraints followed; responsibilities preserved.
  • Additive defaults and typed English/Chinese messages; other locales use existing English fallback.
  • No raised budgets, removed gates or new dependencies.
  • All current-head native checks and UI evidence pass.
  • Maintainer review and applicable native acceptance.

@Cec1c

Cec1c commented Oct 10, 2026

Copy link
Copy Markdown
Contributor

我想知道这个分支近期还有打算继续进行吗?我日常使用还比较需要这个功能,如果近期没有打算我就自己动手了
I'd like to know if there are any plans to continue working on this branch in the near future. I actually need this feature for my daily use, so if there are no plans soon, I'll just do it myself.

@WilliamWang1721

Copy link
Copy Markdown
Contributor Author

@Cec1c 本 PR 仍然在持续跟进,只要把这个修复了就可以 mark 成 open,但是遗憾的是 owner 对于 PR 的审核速度,这将决定了这个 PR 何时能够成功 merge。由于 owner 并没有开启为其他的贡献者的维护者权限,也没有开启相互 review 权限,因此只能等待,预计这个 PR 剩余的冲突将会在今天晚上完成。

@WilliamWang1721
WilliamWang1721 marked this pull request as ready for review October 10, 2026 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] 支持自定义 Agent 会话恢复命令与附加参数

2 participants