Open source Grok Bot alternative, Bring your own agent and subscription: message Claude Code, Codex, Gemini CLI, Cursor, Copilot and 40+ AI agents as bots on your own computer, from iPhone, Mac, Windows, Linux or terminal. Agent-agnostic and free. Also a Muse and Dots alternative. Built in Rust.
Rust acpagent-client-protocolai-agentsai-assistantclaudeclaude-codecodexcoding-agentscursorgeminigemini-cligrok-bot-alternativeiosiphonelinuxmacosmcpopen-sourcerustself-hosted
fix: show bot conversation load errors and keep request status typed
leepokaie7409894db61
diff --git a/apps/desktop/src/renderer/store/bot-store.ts b/apps/desktop/src/renderer/store/bot-store.tsindex d78b549c..3e255560 100644--- a/apps/desktop/src/renderer/store/bot-store.ts+++ b/apps/desktop/src/renderer/store/bot-store.ts@@ -269,11 +269,7 @@ export class BotStore extends BotSync {/** The history between a bot and one peer. Never upserted: old notices would break `loadOlder`'s paging. */async botConversation(botId: string, peerId: string): Promise<Entry[]> {- try {- return await (await this.ready()).botConversation(botId, peerId)- } catch {- return []- }+ return (await this.ready()).botConversation(botId, peerId)}async save(draft: BotDraft) {diff --git a/apps/desktop/src/renderer/views/thread/BotConversation.tsx b/apps/desktop/src/renderer/views/thread/BotConversation.tsxindex 4fa9b525..96259c69 100644--- a/apps/desktop/src/renderer/views/thread/BotConversation.tsx+++ b/apps/desktop/src/renderer/views/thread/BotConversation.tsx@@ -55,15 +55,25 @@ function BotPair({ botId, peerId }: { botId: string; peerId: string }) {/** Read-only history between a bot and one peer: the live chat merged with what the host returns. */export function BotConversationView({ botId, peerId }: { botId: string; peerId: string }) {const store = useStore()- const [fetched, setFetched] = useState<Entry[]>([])+ // null while the host's history loads.+ const [fetched, setFetched] = useState<Entry[] | null>(null)+ const [error, setError] = useState<string | null>(null)const scroller = useRef<HTMLDivElement>(null)- const rows = buildBotConversation(botConversation(fetched, store.chat(botId), peerId))+ const rows = buildBotConversation(botConversation(fetched ?? [], store.chat(botId), peerId))useEffect(() => {let current = true- void store.botConversation(botId, peerId).then((entries) => {- if (current) setFetched(entries)- })+ store.botConversation(botId, peerId).then(+ (entries) => {+ if (current) setFetched(entries)+ },+ (reason: unknown) => {+ console.warn('botConversation failed', reason)+ if (!current) return+ setFetched([])+ setError(reason instanceof Error ? reason.message : String(reason))+ },+ )return () => {current = false}@@ -79,7 +89,8 @@ export function BotConversationView({ botId, peerId }: { botId: string; peerId:<ModalHeader title={<BotPair botId={botId} peerId={peerId} />} /><div className="bot-conversation-scroll" ref={scroller}><div className="bot-conversation-rows">- {rows.length === 0 ? <div style={{ ...font('footnote'), color: 'var(--tertiary)', textAlign: 'center', paddingTop: 24 }}>No messages yet.</div> : null}+ {error ? <div style={{ ...font('footnote'), color: 'var(--danger)', textAlign: 'center', paddingTop: 24 }}>{error}</div> : null}+ {!error && fetched && rows.length === 0 ? <div style={{ ...font('footnote'), color: 'var(--tertiary)', textAlign: 'center', paddingTop: 24 }}>No messages yet.</div> : null}{rows.map((row) => <ConversationRow key={row.id} row={row} />)}</div></div>diff --git a/apps/ios/Kit/Sources/CodyncUI/Store/BotStore+Actions.swift b/apps/ios/Kit/Sources/CodyncUI/Store/BotStore+Actions.swiftindex 2429e02b..98026b8c 100644--- a/apps/ios/Kit/Sources/CodyncUI/Store/BotStore+Actions.swift+++ b/apps/ios/Kit/Sources/CodyncUI/Store/BotStore+Actions.swift@@ -203,13 +203,8 @@ extension BotStore {/// The bot-to-bot notices between a chat and a peer. Never `upsert`ed: old notices in the/// mirror would break `loadOlder`, which pages from the oldest loaded `seq`.- public func botConversation(_ botId: String, peer: String) async -> [Entry] {- do {- return try await ready().botConversation(botId: botId, peerId: peer)- } catch {- log.error("botConversation failed: \(error.localizedDescription, privacy: .public)")- return []- }+ public func botConversation(_ botId: String, peer: String) async throws -> [Entry] {+ try await ready().botConversation(botId: botId, peerId: peer)}public func save(_ draft: BotDraft) async throws -> Bot {diff --git a/apps/ios/Kit/Sources/CodyncUI/Thread/BotConversation.swift b/apps/ios/Kit/Sources/CodyncUI/Thread/BotConversation.swiftindex 88738490..8421c4fd 100644--- a/apps/ios/Kit/Sources/CodyncUI/Thread/BotConversation.swift+++ b/apps/ios/Kit/Sources/CodyncUI/Thread/BotConversation.swift@@ -69,6 +69,7 @@ struct BotConversationView: View {let peerId: String@Environment(BotStore.self) private var model@State private var fetched: [Entry]?+ @State private var error: String?private var rows: [BotConversationRow] {BotConversationRow.build(BotExchange.conversation(fetched: fetched ?? [], live: model.chat(botId), peer: peerId))@@ -80,7 +81,10 @@ struct BotConversationView: View {ModalHeader { BotPairTitle(botId: botId, peerId: peerId) }ScrollView {LazyVStack(alignment: .leading, spacing: 4) {- if rows.isEmpty, fetched != nil {+ if let error {+ Text(error).font(.footnote).foregroundStyle(Palette.danger)+ .frame(maxWidth: .infinity).padding(.top, 24)+ } else if rows.isEmpty, fetched != nil {Text("No messages yet.").font(.footnote).foregroundStyle(Palette.tertiary).frame(maxWidth: .infinity).padding(.top, 24)}@@ -92,7 +96,14 @@ struct BotConversationView: View {.defaultScrollAnchor(.bottom)}.background(Palette.background)- .task(id: peerId) { fetched = await model.botConversation(botId, peer: peerId) }+ .task(id: peerId) {+ do {+ fetched = try await model.botConversation(botId, peer: peerId)+ } catch {+ fetched = []+ self.error = error.localizedDescription+ }+ }}@ViewBuilder private func rowView(_ row: BotConversationRow) -> some View {diff --git a/docs/design/ui-conventions.md b/docs/design/ui-conventions.mdindex dfd3fea3..881e192e 100644--- a/docs/design/ui-conventions.md+++ b/docs/design/ui-conventions.md@@ -122,7 +122,7 @@ carries its behavior; the October 2026 parity changes brought the TUI up to it.the editor without cancelling. Secrets are masked and never sent as chat text.- A bot-to-bot exchange is a compact centered row ("Messaged [avatar] Owen" / "Message from[avatar] Egan"; same verbs for asks; the TUI draws one ` · ` line), never a bubble. Only a- failure is marked: danger color, a warning mark (triangle icon; Android and TUI use a+ failure is marked: danger color, a warning mark (triangle icon; the TUI uses aglyph), "failed" in the accessibility label. The rowopens a read-only "A ⇄ B" sheet. In the main chat consecutive exchanges with the same peer(either direction; trace entries don't break the run, any other visible entry does) are one@@ -133,8 +133,7 @@ carries its behavior; the October 2026 parity changes brought the TUI up to it.time separators after gaps over an hour, "Waiting for {name}…" or the failure detail undera pending or failed exchange, no composer. TUI:`v`/`r` picks a message, j/k moves to the row, ↵ (or a click) opens it, j/k ↑↓ and- ^u/^d scroll, esc closes; `r`, `f` and `1…6` on the row say it is read-only. The- watch shows the row only, not tappable. The data contract is+ ^u/^d scroll, esc closes; `r`, `f` and `1…6` on the row say it is read-only. The data contract is[bot collaboration](../features/bot-collaboration.md#notice-data).- TUI bot settings include **Use computer**, matching the iPhone and desktop apps. Theremote-screen viewer and voice-call UI are not in the TUI.diff --git a/host/src/agent/bot/turn.rs b/host/src/agent/bot/turn.rsindex 951f8267..e3924c2f 100644--- a/host/src/agent/bot/turn.rs+++ b/host/src/agent/bot/turn.rs@@ -38,7 +38,7 @@ impl Actor {for id in entry_ids {// Bot-message notices belong to `chat::team`; writing them here would race its final status.if let Some(mut e) = self.hub.store.entry(id).filter(|e| e.kind == EntryKind::User.as_str()) {- e.data["status"] = "sent".into();+ e.data["status"] = json!(crate::chat::team::RequestStatus::Sent);self.hub.set_entry(id, &e.data);}}