You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Sidebar blanks Context, Limits and the footer for up to a second after /clear #243
After /clear, the Sidebar's Context and Limits bodies and the claude cli: … / ctui: … footer go blank for up to about a second, then come back together, Context at 0%. Live on 2.1.292 (tmux, sampling the pane every 50 ms from the /clear Enter): they vanish at about 115 ms and return at 171–1052 ms across 11 runs, with Limits cost auto and on, at release/0.5.0 and at v0.4.0. The "Run /clear" row of docs/testing/live-checks.md expects Context at 0% within a second and the footer to stay.
Why
/clear empties $.state with no session.start and no session.measure after it (a tagged probe in setUsage logged none). Only the 1 s $.clock.every tick refills usage and versions (refillUsage/refillVersions in ctui/hooks/register.tsx), so the gap is wherever the tick's phase falls. The engine does redraw the Sidebar as soon as $.state empties.
Ask
When the Sidebar's Pane render reads usage or versions as unset, schedule the matching refill from $.clock.after(0, …): render hooks never write $.state themselves. Keep the tick's refill. A probe of exactly this brought both back at 115–172 ms in 4 of 4 live runs. Update the existing test "after /clear empties $.state, the tick reloads the usage and the versions" (ctui/tests/usage.test.tsx) so the rows are back after a redraw and clock.settle(), with no clock.advance(1000). Ship it from bugfix/clear-refill, cut from release/0.5.0, with its pull request into release/0.5.0.
Activity
a1exk-dev commentedon Oct 10, 2026
Fixed by #257, merged into release/0.5.0.