Skip to content

Bug: TUI status line preview shows static dummy content instead of live data #19

Description

@vishnujayvel

Description

The Status tab in the hookwise TUI always displays hardcoded placeholder text from SEGMENT_PLACEHOLDERS instead of rendering real data from the cache (~/.hookwise/state/status-line-cache.json).

Root Cause

tui/hookwise_tui/tabs/status.py:_render_segment() (lines 298-312) looks up segment names like insights_friction directly in the cache dict. But the cache stores raw insights data — there's no code to transform it into the three insights sub-segments. The method falls through to SEGMENT_PLACEHOLDERS.get(seg) every time.

Affected segments (at minimum):

  • insights_friction — no rendering logic, always shows "✅ No friction detected"
  • insights_pace — always shows "📊 12 msgs/day | 2.1k+ lines"
  • insights_trend — always shows "🔧 Top: Bash, Read | Peak: afternoon"
  • Other segments (pulse, news, memories, streak) may also lack proper rendering

The TypeScript CLI (src/core/status-line/segments.ts) has full rendering functions for all these segments. The Python TUI needs equivalent logic.

Expected Behavior

The preview should render live data from the cache, matching the TypeScript CLI output. Placeholders should only appear when cache data is genuinely missing or stale.

Steps to Reproduce

  1. Run hookwise status-line — see live output with real data
  2. Open TUI → Status tab
  3. Toggle any insights segment ON
  4. Preview shows hardcoded dummy text, not the real cached data

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions