Repository navigation
Description
Summary
Archiving a codex-backed thread in bb reaches Codex on disk but not in its UI. The session stays in the Codex Desktop sidebar permanently — a restart does not clear it.
Environment
- bb 0.38.0 / 0.39.0 (macOS), provider
codex - Codex.app 26.814.41407 with embedded codex-cli 0.148.0-alpha.15
Steps to reproduce
- Open Codex Desktop and note a session in the sidebar.
- In bb, archive the thread backed by that session (
bb thread archive <id>, or the sidebar action). - Watch the Codex Desktop sidebar.
Expected: the session disappears from the list, as it does when archived from inside Codex.
Actual: the row stays. It survives app restarts and never goes away.
What is actually happening
The archive itself works — bb does its part correctly:
- the rollout moves to
~/.codex/archived_sessions/ threads.archivedflips to1in~/.codex/state_5.sqlitecodex resumeno longer offers the session
But Codex Desktop does not read either of those for its list. It keeps its own catalogue in ~/.codex/sqlite/codex-dev.db → local_thread_catalog, which has no archived column. A row leaves that catalogue only via:
handleNotificationon athread/archived/thread/deletedbroadcast from its own app-server →applyAuthoritativeRemoval(threadId), or- a full reconciliation scan — but
isFullReconciliationDue()returns true only when!isComplete || lastFullReconciliationAt == null. Oncelast_full_reconciled_atis set, the full scan never runs again, and the incremental scan callslistThreads({archived: false}), so it cannot learn about a thread that disappeared.
bb spawns its own codex app-server child process and calls thread/archive there. Codex Desktop's app-server (a separate child of the Electron process) never hears about it, so the notification that would remove the row is never emitted.
Evidence on our machine: of the codex threads archived from inside the app, 63 are correctly absent from the catalogue. Of those archived from outside (via bb), 8 out of 8 are still listed.
Confirmed fix path
Codex has a cross-client bus at ~/.codex/ipc/ipc.sock, owned by the Electron process. Its own clients broadcast thread-archived there on archive. Sending that same broadcast after bb's archive removes the row from the sidebar within ~1s, verified visually; thread-unarchived restores it. local_thread_catalog is left untouched — the app stops showing the row by itself, so nothing needs deleting from its database.
So the missing piece looks like: whoever archives a session from outside the app should announce it on that bus. Today bb archives and stays silent.
Important caveat: we found the message shape by reading Codex.app/Contents/Resources/app.asar, not from documentation. Please treat the exact payload as an observation to verify against Codex's own source rather than as a specification.
Secondary, upstream-Codex
Because isFullReconciliationDue() never fires again after the first successful build, a missed broadcast is unrecoverable — no restart, no rescan, ever. That is arguably worth fixing on the Codex side independently, but it is not blocking if bb emits the broadcast.
Workaround we are using
Our sidebar plugin sends the broadcast itself after archiving, strictly best-effort: if the socket is missing or the protocol changes, it silently falls back to today's behaviour and never fails or reverts the archive. We would happily drop that code once bb emits it.
Activity
SawyerHood commentedon Aug 20, 2026
Reproduction & root-cause report: https://get-bb.github.io/reports/issues/1984.html
The report has copy-paste repro steps, screenshots where the bug is visual, code permalinks at the base commit, and repro artifacts. It was independently re-run by a second agent (see its Verification section).