Skip to content

feat: archived bots and crews in Settings, each with Delete - #58

Merged
httpsphl merged 9 commits into
mainfrom
feat/archived-list
Sep 30, 2026
Merged

httpsphl merged 9 commits into
mainfrom
feat/archived-list

Conversation

@httpsphl

Copy link
Copy Markdown
Owner

Stacked on #56 (which is on #54 and #55). Merge those first, with merge commits; this PR's own commits are the last two, feat(daemon): archive.list, what the owner archived and feat(app): archived bots and crews in Settings, each with Delete.

What

Archived bots and crews were shown nowhere in the app, so what was archived before Delete existed could not be deleted. Settings gets an Archived part that lists them, each with Delete.

  • Daemon: archive.list answers {crews, bots}: what is archived, which crews.list and bots.list leave out, the latest archived first. bots has every archived bot, those of archived crews too, so the app can count them.
  • App: Settings > Archived, between Appearance and About. A line says that what is archived is stopped and out of sight, and that Botloft still keeps the conversations. Then the list: crews first ("Crew · 2 bots · archived 3 days ago"), then the archived bots of active crews ("Bot in Ops · archived 3 days ago"). A bot of an archived crew goes with its crew and is not listed on its own. With nothing archived, it says so.
  • Delete on a row opens the same confirmation as the menus, with the folder that stays. For something archived it says "leaves Botloft for good" instead of "stops now and leaves", since it stopped when it was archived.
  • The confirmation moved out of the menus into DeleteBot and DeleteCrew, used by the menus and by this list.
  • Texts in the three languages. Spec 7.6, 11.2 and 15.1.

Not here: restoring something archived. There is no such method in the daemon, and it was not asked for; the spec says so.

Tests

  • crates/botloftd/tests/archive.rs: the archive is empty, then has an archived bot and an archived crew with its bot, with their folders, and is empty again after both are deleted; active bots are untouched.
  • features/account/archived.test.tsx, with FakeBotloft: the list and its lines; deleting an archived bot (wording, folder, row gone); deleting an archived crew with its bot, then "Nothing is archived."; the empty list; a list that cannot be read.
  • cargo fmt, clippy -D warnings, the daemon's tests and pnpm check (210 tests) pass.

Checked in the preview (pnpm dev, FakeBotloft, Portuguese): a bot archived from the right-click menu shows up in Configurações > Arquivados.

Nothing here depends on the real Claude Code.

Archiving keeps the rows. Deleting removes the bot with its chat, approvals, the messages it received, its routines, browser sites and tasks, in one transaction; what it sent to other bots stays without a sender.
The methods, the bot.deleted and crew.deleted notifications, the fake daemon and the app store, which drops a deleted bot with its routines, tasks and deliveries.
bots.delete and crews.delete work on active and archived items (spec 7.6). The process is killed at once and the supervisor forgets the bot; the database loses the bot and what was its own; folders stay on disk (spec 5). Other bots are told about the unfinished tasks a deleted bot leaves, and a message of its that still waited arrives as from a deleted bot.

The spec row that said archiving deletes the workspace was never true and now says what happens.
useBotActions holds the items of the bot's menu and the dialogs they open, so another menu can offer exactly the same.
The menu opens at the pointer (or from the keyboard's menu key), without opening the bot, with the same actions as the header's menu. ContextMenu reuses the rows of Menu, stays inside the window and walks with the arrow keys; Menu gets the arrow keys too.
Delete is the last action of the bot's menu (header and right-click) and of the crew's menu. The confirmation names the bot or crew and says what goes (the conversation, routines and tasks, for good) and what stays (the folder, with its path). A message from a bot that left, archived or deleted, reads as from a bot no longer in the crew.
The other lists leave archived crews and bots out, so nothing showed them. archive.list returns both, the latest archived first, for the app to list and delete.
Settings gets an Archived part: the crews and the bots the owner archived, which the rest of the app does not show, with the same delete confirmation as the menus. The confirmation is now a component of its own (DeleteBot, DeleteCrew) and says "leaves" instead of "stops now" for what was already stopped.
@httpsphl
httpsphl merged commit 597a72f into main Sep 30, 2026
3 checks passed
@httpsphl httpsphl mentioned this pull request Sep 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant