diff --git a/desktop/src/features/agents/ui/AgentInstanceEditDialog.tsx b/desktop/src/features/agents/ui/AgentInstanceEditDialog.tsx index ec19f4ef8a..4a952e1903 100644 --- a/desktop/src/features/agents/ui/AgentInstanceEditDialog.tsx +++ b/desktop/src/features/agents/ui/AgentInstanceEditDialog.tsx @@ -726,6 +726,17 @@ export function AgentInstanceEditDialog({ autoRestartOnConfigChange, ); } + if (result.profileSyncError) { + // The local save (disk + AGENTS.md) already succeeded, but the relay + // still has the old kind:0 profile (e.g. old @mention name). Surface + // it instead of silently closing — otherwise the dialog closes as if + // the rename fully succeeded and the user never learns the relay is + // stale (#1822). Matches the create/persona flows, which already toast + // profileSyncError. + toast.warning( + `${result.agent.name} saved locally, but relay profile sync failed: ${result.profileSyncError}`, + ); + } handleOpenChange(false); onUpdated?.(result.agent); // The auto-restart policy deliberately never fires for a stopped or