Skip to content

v0.2.5 — Fix hydration errors and stats-cache missing crash

Choose a tag to compare

@Arindam200 Arindam200 released this 03 Apr 11:00
· 65 commits to main since this release

Bug Fixes

Hydration mismatch (affects all team members)

The TopBar clock and ThemeProvider both caused React hydration mismatches because they read Date.now() / localStorage during the initial server render, producing different values than the client.

Fixes:

  • TopBar: clock now initializes to '' on the server and is set client-side in useEffect. Added suppressHydrationWarning on the element.
  • ThemeProvider: always starts as 'dark' to match server, then reads localStorage in useEffect.
  • layout.tsx: replaced bare <script dangerouslySetInnerHTML> with <Script strategy="beforeInteractive"> to silence the React 19 script-in-component warning.

Stats 404 on machines without stats-cache.json

Team members who haven't run Claude Code long enough for ~/.claude/stats-cache.json to exist were getting a 404 from /api/stats, crashing the overview page.

Fix: /api/stats now builds a minimal valid response from session JSONL data when stats-cache.json is absent — the dashboard shows real session counts, daily activity, and tool usage even without the cache file.