inspector/core/react
Repository files (latest commit first)
Filename Latest commit message Latest commit date
cliffhall 07a7b0beb5 fix(web): accept CRLF-delimited SSE frames on the servers events stream
The `/api/servers/events` reader in `useServers` searched for `\n\n` and
consumed exactly two characters as the separator. SSE permits CRLF line
endings, so a `event: change\r\n\r\n` frame stayed buffered forever:
`isSseDataFrame()` was never reached and no background refresh fired,
leaving the server list stale until a manual refresh or an LF-delimited
event arrived.

Frame boundaries are now located with a CRLF-aware matcher that reports
the separator's real length, and frame lines split on either terminator.

A bare CR is deliberately not accepted as a terminator: it cannot be
distinguished from the first half of a CRLF straddling a chunk boundary,
so a buffer ending in `…\r\n\r` would read as a completed frame and the
`\n` arriving next would open a bogus one.

Two regressions cover it, both verified failing against the old parser.
Each uses a referentially stable `fetchFn` and holds the frame behind a
promise released after the disk write — with an inline `fetchFn` the hook
re-subscribes every render and that re-subscription's own mount refresh
picks the edit up regardless, so the test would pass unfixed.

Closes #2006

Signed-off-by: cliffhall <cliff@futurescale.com>
2026-08-16 20:07:16 -04:00
..
useClientSettingsDraft.ts chore: close quality-gate coverage gaps (#1689) (#1766) 2026-07-24 17:20:12 -04:00
useEmaIdpLoginState.ts fix(auth): guard OAuth-storage async paths against unhandled rejections 2026-07-08 10:59:40 -04:00
useFetchRequestLog.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
useInitialConfig.ts refactor(web): consolidate the three GET /api/config hooks into one (#1770) 2026-07-24 22:12:19 -04:00
useInspectorClient.ts fix: salvage a list result's valid entries when one is malformed (#1909) 2026-08-15 16:52:11 -04:00
useManagedListError.ts fix: read the list error via useSyncExternalStore; clear correlation maps 2026-08-08 17:41:27 -04:00
useManagedPrompts.ts fix: surface list-fetch failures instead of swallowing them 2026-08-08 16:48:48 -04:00
useManagedRequestorTasks.ts SDK v2 migration (behavior-neutral, versionNegotiation: 'legacy') (#1624) 2026-07-15 10:44:24 -04:00
useManagedResources.ts fix: surface list-fetch failures instead of swallowing them 2026-08-08 16:48:48 -04:00
useManagedResourceTemplates.ts fix: surface list-fetch failures instead of swallowing them 2026-08-08 16:48:48 -04:00
useManagedTools.ts fix: surface list-fetch failures instead of swallowing them 2026-08-08 16:48:48 -04:00
useMessageLog.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
usePagedPrompts.ts Thread cacheMode through managed list refresh via SDK cache-aware verbs (#1721) (#1723) 2026-07-19 01:06:31 -04:00
usePagedRequestorTasks.ts Address @claude review: format core/, typed output-validation error, document progress heuristic 2026-07-15 11:08:54 -04:00
usePagedResources.ts Thread cacheMode through managed list refresh via SDK cache-aware verbs (#1721) (#1723) 2026-07-19 01:06:31 -04:00
usePagedResourceTemplates.ts SDK v2 migration (behavior-neutral, versionNegotiation: 'legacy') (#1624) 2026-07-15 10:44:24 -04:00
usePagedTools.ts Thread cacheMode through managed list refresh via SDK cache-aware verbs (#1721) (#1723) 2026-07-19 01:06:31 -04:00
usePendingClientRequests.ts feat(web): render pending sampling/elicitation requests (#1407) (#1411) 2026-06-02 17:52:20 -04:00
useResourceSubscriptions.ts Resources: subscriptions/listen model on modern servers (era fork) (#1630) (#1730) 2026-07-20 19:33:40 -04:00
useServers.ts fix(web): accept CRLF-delimited SSE frames on the servers events stream 2026-08-16 20:07:16 -04:00
useSettingsDraft.ts fix(servers): make settings form re-render on every keystroke (#1361) (#1362) 2026-05-26 13:42:14 -04:00
useStderrLog.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00