_make_backup() already writes rotating timestamped backups (.bcc_backups/<name>.<timestamp>.json, capped at MAX_BACKUPS=15) on every save. But there is no way to browse or restore one from the GUI — you have to find the file manually. Research repeatedly surfaces "config got corrupted / Claude won't launch after I edited it" as a common failure mode, which is exactly what these backups exist to fix, but the fix is currently inaccessible.
Proposed solution
A Restore from backup… action per profile that:
Lists the backups in .bcc_backups/, sorted newest-first, with human-readable timestamps.
Shows a unified diff of the selected backup vs the current file (inline preview).
Writes the selected backup back through the normal write_config() atomic-write path — so restoring itself creates a new backup of the pre-restore state.
Core logic (listing, diffing, preview generation) lives in bcc_core.py; the dialog lives in bcc.py.
Acceptance criteria
Restore is reachable from the profile menu (or a toolbar button).
Dialog lists backups with timestamps; selecting one shows a diff.
Restoring creates a new backup of the pre-restore state.
## Problem
`_make_backup()` already writes rotating timestamped backups (`.bcc_backups/<name>.<timestamp>.json`, capped at `MAX_BACKUPS=15`) on every save. But there is no way to browse or restore one from the GUI — you have to find the file manually. Research repeatedly surfaces "config got corrupted / Claude won't launch after I edited it" as a common failure mode, which is exactly what these backups exist to fix, but the fix is currently inaccessible.
## Proposed solution
A **Restore from backup…** action per profile that:
1. Lists the backups in `.bcc_backups/`, sorted newest-first, with human-readable timestamps.
2. Shows a unified diff of the selected backup vs the current file (inline preview).
3. Writes the selected backup back through the normal `write_config()` atomic-write path — so restoring itself creates a new backup of the pre-restore state.
Core logic (listing, diffing, preview generation) lives in `bcc_core.py`; the dialog lives in `bcc.py`.
## Acceptance criteria
- Restore is reachable from the profile menu (or a toolbar button).
- Dialog lists backups with timestamps; selecting one shows a diff.
- Restoring creates a new backup of the pre-restore state.
- "No backups yet" is handled gracefully.
- Core list/diff logic has unit tests.
## Relevant code
- `bcc_core.py::_make_backup` (line 207)
- `bcc_core.py::write_config` (line 226)
- `bcc_core.py::BACKUP_DIRNAME`, `MAX_BACKUPS` constants
the_og
added the P0 label 2026-07-02 00:49:30 -04:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Problem
_make_backup()already writes rotating timestamped backups (.bcc_backups/<name>.<timestamp>.json, capped atMAX_BACKUPS=15) on every save. But there is no way to browse or restore one from the GUI — you have to find the file manually. Research repeatedly surfaces "config got corrupted / Claude won't launch after I edited it" as a common failure mode, which is exactly what these backups exist to fix, but the fix is currently inaccessible.Proposed solution
A Restore from backup… action per profile that:
.bcc_backups/, sorted newest-first, with human-readable timestamps.write_config()atomic-write path — so restoring itself creates a new backup of the pre-restore state.Core logic (listing, diffing, preview generation) lives in
bcc_core.py; the dialog lives inbcc.py.Acceptance criteria
Relevant code
bcc_core.py::_make_backup(line 207)bcc_core.py::write_config(line 226)bcc_core.py::BACKUP_DIRNAME,MAX_BACKUPSconstants