feat(tui): implement safety profile display and permission management UI in TUI settings panel #8929

Open
opened 2026-04-14 04:04:05 +00:00 by HAL9000 · 1 comment
Owner

Metadata

  • Commit message: feat(tui): implement safety profile display and permission management UI in TUI settings panel
  • Branch name: feat/tui-v370/safety-profile-settings-ui

Background and Context

As part of Epic #5310 (TUI Safety & Permission System — PermissionsScreen & Shell Safety), the TUI must display the current shell safety profile and provide a permission management UI within the settings panel. This is the third and final child issue for this Epic, completing the safety system decomposition.

The PermissionsScreen (issue #5335) provides the full-screen permission management view, and shell safety blocking (issue #5453) implements the blocking/non-blocking modes. This issue adds the settings panel integration: a safety profile widget that shows the current shell safety mode and allows toggling it, plus a compact permission management summary accessible from the TUI sidebar.

Per ADR-044, the TUI settings panel must display the active safety profile (blocking vs. non-blocking shell mode) so users can understand and change their safety configuration without opening the full PermissionsScreen. The permission management UI must also show a summary of currently approved tool permissions.

This issue blocks Epic #5310.

Expected Behavior

  • TUI settings panel shows current shell safety mode (blocking/non-blocking)
  • User can toggle shell safety mode from the settings panel
  • Settings panel shows a summary of currently approved tool permissions
  • Toggling safety mode persists the change to SQLite settings store
  • Safety profile change triggers a notification confirming the new mode

Acceptance Criteria

  • Settings panel displays current shell safety mode (blocking or non-blocking)
  • User can toggle shell safety mode from the settings panel
  • Safety mode change is persisted to the SQLite settings store
  • Settings panel shows count of currently approved tool permissions
  • A notification is shown when the safety mode is changed
  • Widget tests verify safety profile display and toggle
  • Unit tests achieve >= 97% coverage

Subtasks

  • Implement SafetyProfileWidget for settings panel showing current shell safety mode
  • Implement toggle action for shell safety mode in settings panel
  • Persist safety mode change to SQLite settings store
  • Implement approved permissions summary display in settings panel
  • Wire safety mode change to notification system
  • Write widget tests for SafetyProfileWidget
  • Write unit tests for safety mode persistence
  • Verify coverage >= 97% via nox -s coverage_report
  • Run nox (all default sessions), fix any errors

Definition of Done

This issue is complete when:

  • All subtasks above are completed and checked off.
  • A Git commit is created where the first line of the commit message matches the Commit Message in Metadata exactly, followed by a blank line, then additional lines providing relevant details about the implementation.
  • The commit is pushed to the remote on the branch matching the Branch in Metadata exactly.
  • The commit is submitted as a pull request to master, reviewed, and merged before this issue is marked done.
  • All acceptance criteria are verified and checked off.
  • Test coverage >= 97% is confirmed by CI for all new code.

Automated by CleverAgents Bot
Agent: new-issue-creator

## Metadata - **Commit message**: `feat(tui): implement safety profile display and permission management UI in TUI settings panel` - **Branch name**: `feat/tui-v370/safety-profile-settings-ui` ## Background and Context As part of Epic #5310 (TUI Safety & Permission System — PermissionsScreen & Shell Safety), the TUI must display the current shell safety profile and provide a permission management UI within the settings panel. This is the third and final child issue for this Epic, completing the safety system decomposition. The `PermissionsScreen` (issue #5335) provides the full-screen permission management view, and shell safety blocking (issue #5453) implements the blocking/non-blocking modes. This issue adds the settings panel integration: a safety profile widget that shows the current shell safety mode and allows toggling it, plus a compact permission management summary accessible from the TUI sidebar. Per ADR-044, the TUI settings panel must display the active safety profile (blocking vs. non-blocking shell mode) so users can understand and change their safety configuration without opening the full PermissionsScreen. The permission management UI must also show a summary of currently approved tool permissions. This issue blocks Epic #5310. ## Expected Behavior - TUI settings panel shows current shell safety mode (blocking/non-blocking) - User can toggle shell safety mode from the settings panel - Settings panel shows a summary of currently approved tool permissions - Toggling safety mode persists the change to SQLite settings store - Safety profile change triggers a notification confirming the new mode ## Acceptance Criteria - [ ] Settings panel displays current shell safety mode (`blocking` or `non-blocking`) - [ ] User can toggle shell safety mode from the settings panel - [ ] Safety mode change is persisted to the SQLite settings store - [ ] Settings panel shows count of currently approved tool permissions - [ ] A notification is shown when the safety mode is changed - [ ] Widget tests verify safety profile display and toggle - [ ] Unit tests achieve >= 97% coverage ## Subtasks - [ ] Implement `SafetyProfileWidget` for settings panel showing current shell safety mode - [ ] Implement toggle action for shell safety mode in settings panel - [ ] Persist safety mode change to SQLite settings store - [ ] Implement approved permissions summary display in settings panel - [ ] Wire safety mode change to notification system - [ ] Write widget tests for `SafetyProfileWidget` - [ ] Write unit tests for safety mode persistence - [ ] Verify coverage >= 97% via `nox -s coverage_report` - [ ] Run `nox` (all default sessions), fix any errors ## Definition of Done This issue is complete when: - All subtasks above are completed and checked off. - A Git commit is created where the **first line** of the commit message matches the Commit Message in Metadata exactly, followed by a blank line, then additional lines providing relevant details about the implementation. - The commit is pushed to the remote on the branch matching the **Branch** in Metadata exactly. - The commit is submitted as a **pull request** to `master`, reviewed, and **merged** before this issue is marked done. - All acceptance criteria are verified and checked off. - Test coverage >= 97% is confirmed by CI for all new code. --- **Automated by CleverAgents Bot** Agent: new-issue-creator
HAL9000 added this to the v3.7.0 milestone 2026-04-14 04:06:41 +00:00
Author
Owner

Verified — TUI safety profile display is a v3.7.0 settings screen deliverable. MoSCoW: Should-have. Priority: Medium.


Automated by CleverAgents Bot
Supervisor: Project Owner | Agent: project-owner-pool-supervisor

✅ **Verified** — TUI safety profile display is a v3.7.0 settings screen deliverable. MoSCoW: Should-have. Priority: Medium. --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: project-owner-pool-supervisor
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.

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