Synced from monorepo
Synced from monorepo Changes: - Shell: accept target response id on rewind execute - Shell: stamp response id on chat user message chunks - Worktree: optional rebuild and stale git registration cleanup in auto-GC - Worktree: kind-aware auto-GC TTLs and config knobs - Worktree: macOS process CWD scan and Unix PID liveness for GC guards - Worktree: automatic throttled GC on startup (Linux age-based; non-Linux dead-only) - Pager: add `[ui].combine_queued_prompts` to batch queued follow-ups - Shell: stop overwriting user skills - Tools: read markdown in `skills/` directories untruncated - `/usage` shows per-session token and dollar usage in the TUI - Security: prompt on environment-dumping `ps` variants - Security: always-safe `kubectl` no longer runs arbitrary kubeconfig credential plugins without permission - Tools: make scheduler deletion durable - Shell: add relocation storage primitives - Shell: give side model calls their own conversation ids - Fix five workflow-runtime bugs (budget, pause, cancel, reconnect) - Security: peel `env -S` / `--split-string` operands in the Bash permission gate (managed deny/ask) - Pager: expose doctor in the TUI - Security: block unauthorized RCE via abused safe commands - Pager idle watcher cue: "1 subagent still running" instead of "watching · 1 subagent" - Security: block `rg --pre` arbitrary code execution in auto-mode - Voice: diagnose silent-mic failures (macOS permission) and add doctor/terminal-setup Voice section - App builder deployer: `allow_forking` and `show_built_with_grok` - Pager: stop stacking duplicate "Worked for" markers on parked turns - Shell: support `max` as a distinct reasoning effort tier - Tools: serialize background `/loop` fires on the whole work unit - Shell: add working-directory relocation state primitives - Proto: `ClientToolResult` and `ChatConfig` client-side tools - Shell: model providers - Chat: select App Builder product on the Build path - Shell: attach author identity to feedback when the deployment opts in - Doctor: fix for SSH wrap setup - Workflow authoring skills: create-workflow and import-claude-workflow docs - Add read-only grok doctor - Sandbox: apply Landlock without a controlling TTY - Pager: recover image paste over grok wrap on headless remotes - Pager: make actions screen-mode aware - Shell: resume sessions when the working directory moves - Pager: centralize terminal diagnostics - Workspace: gate inline shell file access - Pager: centralize terminal probes - Pager: edit minimal prompts in an external editor - Pager: standardize backgrounding on Ctrl+B - Shell: recap rides the parent turn's prompt cache - Tools: add scheduler lifecycle version clock Source-Revision: 0f4d7c91b8b2b408333f6de1e8a76cb8eaa71899
This commit is contained in:
parent
a881e6703f
commit
3af4d5d398
556 changed files with 56609 additions and 21892 deletions
|
|
@ -45,6 +45,7 @@ pub async fn handle(agent: &MvpAgent, args: &acp::ExtRequest) -> ExtResult {
|
|||
handle_reload_project_mcp_servers(agent, args).await
|
||||
}
|
||||
"x.ai/internal/reload_skills" => handle_reload_skills(agent),
|
||||
"x.ai/internal/reload_workflows" => handle_reload_workflows(agent),
|
||||
"x.ai/internal/reload_models" => handle_reload_models(agent),
|
||||
"x.ai/internal/reload_models_cache" => handle_reload_models_cache(agent),
|
||||
"x.ai/internal/auth_cleared" => handle_auth_cleared(agent),
|
||||
|
|
@ -373,15 +374,16 @@ async fn handle_update_mcp_servers(agent: &MvpAgent, args: &acp::ExtRequest) ->
|
|||
// internal/reload_skills
|
||||
|
||||
/// Reload skills for ALL active sessions. Called by the skills file watcher
|
||||
/// (via ACP injection from `app.rs`) when `SKILL.md` files change.
|
||||
fn handle_reload_skills(agent: &MvpAgent) -> ExtResult {
|
||||
let session_ids: Vec<acp::SessionId> = agent.sessions.borrow().keys().cloned().collect();
|
||||
for sid in &session_ids {
|
||||
if let Some(handle) = agent.sessions.borrow().get(sid).cloned() {
|
||||
let _ = handle.cmd_tx.send(SessionCommand::ReloadSkills);
|
||||
}
|
||||
}
|
||||
ExtMethodResult::success(serde_json::json!({ "reloaded": session_ids.len() }))
|
||||
let reloaded = agent.reload_skills_all_sessions();
|
||||
ExtMethodResult::success(serde_json::json!({ "reloaded": reloaded }))
|
||||
.to_ext_response()
|
||||
.map_err(|e| acp::Error::internal_error().data(e.to_string()))
|
||||
}
|
||||
|
||||
fn handle_reload_workflows(agent: &MvpAgent) -> ExtResult {
|
||||
let reloaded = agent.advertise_commands_all_sessions();
|
||||
ExtMethodResult::success(serde_json::json!({ "reloaded": reloaded }))
|
||||
.to_ext_response()
|
||||
.map_err(|e| acp::Error::internal_error().data(e.to_string()))
|
||||
}
|
||||
|
|
@ -660,6 +662,20 @@ async fn handle_plugins_reload(agent: &MvpAgent) -> ExtResult {
|
|||
async fn handle_commands_list(agent: &MvpAgent, args: &acp::ExtRequest) -> ExtResult {
|
||||
let req: crate::session::slash_commands::ListCommandsRequest = parse_params(args)?;
|
||||
|
||||
if let Some(session_id) = req.session_id.as_ref() {
|
||||
let Some(handle) = agent.session_handle_waiting_for_load(session_id).await else {
|
||||
return Err(
|
||||
acp::Error::invalid_request().data(format!("unknown session id: {}", session_id.0))
|
||||
);
|
||||
};
|
||||
let response = crate::session::slash_commands::ListCommandsResponse {
|
||||
commands: handle.list_available_commands().await,
|
||||
};
|
||||
return Ok(acp::ExtResponse::new(Arc::from(
|
||||
serde_json::value::to_raw_value(&response)?,
|
||||
)));
|
||||
}
|
||||
|
||||
let skills_config = agent.cfg.borrow().skills.clone();
|
||||
let compat = agent.cfg.borrow().compat_resolved;
|
||||
let availability = agent.command_availability();
|
||||
|
|
@ -709,6 +725,7 @@ async fn handle_commands_list(agent: &MvpAgent, args: &acp::ExtRequest) -> ExtRe
|
|||
plugin_reg.as_deref(),
|
||||
availability,
|
||||
compat,
|
||||
false,
|
||||
)
|
||||
.await;
|
||||
Ok(acp::ExtResponse::new(Arc::from(
|
||||
|
|
|
|||
Loading…
Reference in a new issue