)]}'
{
  "commit": "568bebf2f2a23917ac6ce7d2f2f30aba54a57eca",
  "tree": "0fa126370bdc31193834bd00b2d0ed36b952b82b",
  "parents": [
    "7fe76973f6cba7c7a51f4b896444c2ce3c1ce0d5"
  ],
  "author": {
    "name": "banksean",
    "email": "banksean@gmail.com",
    "time": "Thu Jul 24 02:44:54 2025 +0000"
  },
  "committer": {
    "name": "banksean",
    "email": "banksean@gmail.com",
    "time": "Thu Jul 24 02:51:34 2025 +0000"
  },
  "message": "webui: fix IDLE/DISCONNECTED oscillation by replacing initialLoadComplete misuse\n\nFix DataManager session_ended handler that caused rapid status switching\nbetween IDLE and DISCONNECTED when sessions ended.\n\nIssue Description:\nWhen a session ended, the UI\u0027s sketch-call-status component would rapidly\noscillate between IDLE and DISCONNECTED states, suggesting continued\nconnection attempts despite the session being over.\n\nRoot Cause Analysis:\nThe primary issue was session_ended handler improperly firing initialLoadComplete\nevent, confusing timeline component state management. The initialLoadComplete event\nwas added for newsessions functionality but broke assumptions in regular sketch\nsessions. The timeline component expects initialLoadComplete to signal new page\nloads, not ended sessions.\n\nWhen fired for ended sessions, this caused UI re-render cycles and state confusion\nthat interfered with connection status display, creating the oscillation effect.\n\nImplementation Changes:\n- Added sessionDataReady event type for ended session data readiness\n- Modified session_ended handler to emit sessionDataReady instead of\n  initialLoadComplete for ended sessions\n- Preserved initialLoadComplete semantics for active session data loading\n- Added clarifying comment to existing isSessionEnded guard in connect()\n\nSecurity \u0026 Compatibility:\n- No security implications, purely UI state management fix\n- Newsessions component unaffected (doesn\u0027t use initialLoadComplete)\n- Timeline component behavior restored to expected state\n- All existing event handling preserved\n\nThis fix eliminates the connection status oscillation while maintaining\nproper separation of concerns between live session loading and ended\nsession display states.\n\nCo-Authored-By: sketch \u003chello@sketch.dev\u003e\nChange-ID: scd1b437c8ae7c381k\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "247a9cb4ceefbe23181c3cdf040c7fac6e1871d4",
      "old_mode": 33188,
      "old_path": "webui/src/data.ts",
      "new_id": "9d2444402d8d13c0c523d46e0a4f4e2c14b96d17",
      "new_mode": 33188,
      "new_path": "webui/src/data.ts"
    }
  ]
}
