UAT: TUI session persistence (SQLite tui.db) not implemented — sessions not saved across restarts #4393

Closed
opened 2026-04-08 12:04:17 +00:00 by HAL9000 · 1 comment
Owner

Bug Report

Feature Area: TUI — Session Persistence and Resume

What Was Tested

The spec (§ "Session Persistence and Resume") defines that TUI sessions are persisted to an SQLite database at ~/.local/state/cleveragents/tui.db to enable resumption across TUI restarts.

Expected Behavior (from spec)

Sessions stored in SQLite with columns:

  • id (TEXT PK) — UUID matching domain Session entity ID
  • persona_name (TEXT) — Active persona name
  • actor_identity (TEXT) — Namespaced actor identity
  • title (TEXT) — User-assigned or auto-generated title
  • prompt_count (INTEGER) — Number of user prompts
  • total_cost (REAL) — Cumulative cost in USD
  • created_at (TEXT ISO 8601)
  • last_used (TEXT ISO 8601)
  • project_path (TEXT) — Working directory at session creation
  • meta_json (TEXT) — JSON blob for preset, sidebar state, scroll position

Resume workflow:

  1. User presses ctrl+r from SessionsScreen
  2. TUI reads session record from SQLite
  3. New A2A Task initiated with stored session ID
  4. Actor receives conversation history via A2A multi-turn
  5. Conversation stream populated with historical messages
  6. Persona restored to stored value

Actual Behavior

No SQLite persistence layer exists for TUI sessions. The SessionView dataclass in src/cleveragents/tui/app.py only holds:

@dataclass(slots=True)
class SessionView:
    session_id: str
    transcript: list[str]

Sessions are lost when the TUI is closed. No tui.db file is created. No resume functionality exists.

Code Location

  • src/cleveragents/tui/app.pySessionView has no persistence
  • No SQLite session storage module exists in src/cleveragents/tui/
  • Spec reference: §"Session Persistence and Resume" (line ~30139 in docs/specification.md)

Impact

Users lose all session history when the TUI is closed. The Sessions Screen's "Saved Sessions" section (which depends on this database) cannot function.


Automated by CleverAgents Bot
Supervisor: UAT Testing | Agent: uat-tester

## Bug Report **Feature Area:** TUI — Session Persistence and Resume ### What Was Tested The spec (§ "Session Persistence and Resume") defines that TUI sessions are persisted to an SQLite database at `~/.local/state/cleveragents/tui.db` to enable resumption across TUI restarts. ### Expected Behavior (from spec) Sessions stored in SQLite with columns: - `id` (TEXT PK) — UUID matching domain Session entity ID - `persona_name` (TEXT) — Active persona name - `actor_identity` (TEXT) — Namespaced actor identity - `title` (TEXT) — User-assigned or auto-generated title - `prompt_count` (INTEGER) — Number of user prompts - `total_cost` (REAL) — Cumulative cost in USD - `created_at` (TEXT ISO 8601) - `last_used` (TEXT ISO 8601) - `project_path` (TEXT) — Working directory at session creation - `meta_json` (TEXT) — JSON blob for preset, sidebar state, scroll position **Resume workflow:** 1. User presses `ctrl+r` from SessionsScreen 2. TUI reads session record from SQLite 3. New A2A Task initiated with stored session ID 4. Actor receives conversation history via A2A multi-turn 5. Conversation stream populated with historical messages 6. Persona restored to stored value ### Actual Behavior No SQLite persistence layer exists for TUI sessions. The `SessionView` dataclass in `src/cleveragents/tui/app.py` only holds: ```python @dataclass(slots=True) class SessionView: session_id: str transcript: list[str] ``` Sessions are lost when the TUI is closed. No `tui.db` file is created. No resume functionality exists. ### Code Location - `src/cleveragents/tui/app.py` — `SessionView` has no persistence - No SQLite session storage module exists in `src/cleveragents/tui/` - Spec reference: §"Session Persistence and Resume" (line ~30139 in docs/specification.md) ### Impact Users lose all session history when the TUI is closed. The Sessions Screen's "Saved Sessions" section (which depends on this database) cannot function. --- **Automated by CleverAgents Bot** Supervisor: UAT Testing | Agent: uat-tester
HAL9000 added this to the v3.7.0 milestone 2026-04-08 17:42:38 +00:00
Author
Owner

Closing as duplicate of #4739 — TUI SQLite session persistence not implemented.


Automated by CleverAgents Bot
Supervisor: Backlog Grooming | Agent: backlog-groomer

Closing as duplicate of #4739 — TUI SQLite session persistence not implemented. --- **Automated by CleverAgents Bot** Supervisor: Backlog Grooming | Agent: backlog-groomer
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
cleveragents/cleveragents-core#4393
No description provided.