Commit Graph
8 Commits
Author SHA1 Message Date
Jamie BruntonandClaude Opus 5 a9cea7ed18 Retire removed accounts instead of deleting them
Removing an account had no path at all, so a dead session could only be
left running or hand-edited out of the database. The first cut deleted the
account and everything it owned, which threw away conversations and media
that are worth keeping.

Retire instead: keep the row and every row it produced, destroy the stored
cookies and Matrix token. Wiping the credentials is what makes sending and
syncing impossible rather than merely disabled — isEnabledAccount requires
a verified status, so no runtime ever starts, and no session survives for
anything to use. setActive, markLoginRequired and the background credential
refresh now skip retired accounts so none of them quietly revives one;
re-importing a session deliberately does.

Keeping the content visible needed more than keeping the rows. Conversations
and media are only served from running runtimes, so a retired account's
history would have disappeared from the dashboard regardless. Media already
reads the account content table for every listed account. Conversations now
have an archive path that reads the stored ActiveChat payloads directly.

Every write path refuses a retired conversation with a 409: send-reply,
both suggest endpoints, share-media, shareable-media and all read-state
writes. Lazy-loading detail is skipped too — the fallback chat service
belongs to a different account, so it would sync the wrong session and
write the wrong cache. Archived detail derives conversation state from the
transcript alone for the same reason.

Migration 32 rebuilds reddit_accounts to admit the new status, with foreign
keys off and a foreign_key_check before they are restored, as migration 11
does. Two migration tests rewound user_version by counting back from the
head, which silently breaks whenever a migration is appended; they now
target absolute versions.

Conversations never opened before removal keep only their summary. Message
history is lazy-loaded on first open and there is no session left to fetch
the rest with.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-12 08:58:22 +01:00
jjbrunton 687abab82b Add human-led conversation learning loop 2026-08-11 23:04:25 +01:00
jjbrunton bc42c55555 Remove browsing selection ceilings 2026-08-11 22:54:48 +01:00
jjbrunton e890f74478 Configure browsing session pacing and size 2026-08-11 22:17:18 +01:00
jjbrunton 1fd154e1eb Track pending browsing upvotes 2026-08-11 22:05:54 +01:00
jjbrunton 540590f43e Run immediate browsing sessions with enabled votes 2026-08-11 21:59:13 +01:00
jjbrunton 7bf1aa9d24 Enable automatic browsing upvotes 2026-08-11 21:52:54 +01:00
jjbrunton 27012399ec Add account browsing simulation 2026-08-11 21:40:31 +01:00