-
Notifications
You must be signed in to change notification settings - Fork 2
Session names truncated in 'daf list' making sessions impossible to reopen on small terminals #358
Description
Problem Description
When running daf list on a terminal with small width, session names are truncated with ellipsis (e.g., "my-long-session-name" → "my-lo…"). This is problematic because the session name is the key identifier for reopening sessions with daf open <session-name>.
Users cannot copy the full session name from truncated output, making it impossible to reopen sessions without manually finding the full name in session files.
Steps to Reproduce
- Create a session with a long name (e.g., "feature-implement-caching-layer-redis")
- Resize terminal to a small width (< 100 columns)
- Run
daf list - Observe the session name is truncated: "feature-im…"
- Try to reopen:
daf open feature-im→ fails because the full name is needed
Actual Behavior
The "Name" column in the table is truncated when terminal width is small:
- Session name displayed as: "feature-im…"
- Full name is hidden
- User cannot copy the full session name
daf openrequires the exact full name
Expected Behavior
Session names should never be truncated in daf list output because:
- They are the primary key for reopening sessions
- Users need to be able to copy the full name
- Other identifier columns (like "Issue") can be truncated, but not the session name
Root Cause Analysis
File: devflow/cli/commands/list_command.py
Line: 56
table.add_column("Name", style="bold")The Name column is created without no_wrap=True, causing Rich Table to automatically truncate the column to fit terminal width.
Evidence:
-
Test file acknowledges truncation (
tests/test_list_command.py:113):# Session name and summary may be truncated (e.g., "compl…", "Comple…") -
Integration test has workaround (
integration-tests/test_investigation.sh:265):# Search for the first 10 characters of the session name to handle truncation -
Other commands already use
no_wrap=Truefor session names:sync_command.py:38:table.add_column("Session Name", style="cyan", no_wrap=True)template_commands.py:108:table.add_column("Name", style="cyan", no_wrap=True)
Proposed Solution
Add no_wrap=True to the Name column definition:
table.add_column("Name", style="bold", no_wrap=True)This matches the pattern already used in sync_command.py for session names and ensures the Name column never truncates.
Files to modify:
devflow/cli/commands/list_command.py(line 56)
Files to update (remove truncation workarounds):
tests/test_list_command.py(line 113 comment)integration-tests/test_investigation.sh(line 265 comment and logic)
Additional Context
Session names are the only way to reopen sessions:
daf open <session-name>Unlike JIRA keys or issue numbers, session names:
- Are user-defined strings (can be very long)
- Cannot be looked up elsewhere
- Are the primary identifier in the UI
- Must be fully visible for usability
Impact
Severity: Medium
- Affects users with small terminals or many table columns
- Workaround exists:
daf list --json | jqto get full names - Core UX issue: primary identifier should always be visible
User Experience:
- Frustrating when you can't reopen a session
- Forces users to manually inspect session files
- Inconsistent with
daf syncwhich doesn't truncate session names