HERMES-GIELIE/static
nankingjing 95a1647557 fix(#6419): route every recovery path through one pending_user_message merge helper
The mid-stream reconnect path could render the just-sent user message below
the live streaming assistant response it triggered, because
`refreshSession()` appended `pending_user_message` at the end of
`S.messages` unconditionally while `loadSession()` correctly inserted
it before the first live assistant message. When the client went through
its reconnect/recovery path mid-turn (typical on iOS PWA screen
lock/resume) the live assistant tail rendered above the prompt.

Centralize every recovery/reconnect reinsertion through one
identity-aware helper (`_mergePendingSessionMessage`) that:

- inserts the owning user turn before its live assistant/Worklog tail,
- appends only when no live tail exists,
- deduplicates against the current tail user row,
- remains idempotent across repeated resume probes.

`refreshSession()` now calls the same helper instead of pushing at
the end. `loadSession()` continues to use the helper unchanged.

Adds `tests/test_issue6419_pending_user_reconnect_order.py` pinning:
- the helper is defined exactly once at module top level,
- it inserts before live assistant and falls back to append,
- `refreshSession()` uses the helper and does not push unconditionally,
- `loadSession()` still merges before renderMessages in the INFLIGHT
  reattach branch.

Renames the inner end-marker in
`tests/test_gateway_sse_reconnect_dedupe.py` to a stable inside-loadSession
boundary (`// Phase 2a:`) since the helper is no longer nested.
2026-07-29 22:37:58 +00:00
..
vendor fix: protect pipes inside backtick code spans in renderMd tables 2026-06-25 08:25:58 +00:00
__init__.py Release: pip-installable packaging metadata (#6337, @rodboev) (#6344) 2026-07-20 02:17:52 +00:00
apple-touch-icon.png Swap brand to new cyan caduceus: favicon family, titlebar + empty-state logo (theme-safe navy badge), remove per-skin titlebar fill overrides 2026-06-28 07:44:16 +00:00
assistant_turn_anchors.js Harden historical anchor hydration edges 2026-07-20 17:22:02 +08:00
boot.js fix(sessions): preserve active chat across hard refresh 2026-07-29 21:50:54 +00:00
commands.js fix(#6008): keep stop failure toasts actionable across locales 2026-07-22 12:33:57 -04:00
extension_settings.js fix(extensions): prune malformed browser overrides (#5094) 2026-06-28 18:31:43 -04:00
favicon-32.png Swap brand to new cyan caduceus: favicon family, titlebar + empty-state logo (theme-safe navy badge), remove per-skin titlebar fill overrides 2026-06-28 07:44:16 +00:00
favicon-192.png Swap brand to new cyan caduceus: favicon family, titlebar + empty-state logo (theme-safe navy badge), remove per-skin titlebar fill overrides 2026-06-28 07:44:16 +00:00
favicon-512.png Swap brand to new cyan caduceus: favicon family, titlebar + empty-state logo (theme-safe navy badge), remove per-skin titlebar fill overrides 2026-06-28 07:44:16 +00:00
favicon-512.svg Swap brand to new cyan caduceus: favicon family, titlebar + empty-state logo (theme-safe navy badge), remove per-skin titlebar fill overrides 2026-06-28 07:44:16 +00:00
favicon.ico Swap brand to new cyan caduceus: favicon family, titlebar + empty-state logo (theme-safe navy badge), remove per-skin titlebar fill overrides 2026-06-28 07:44:16 +00:00
favicon.svg Swap brand to new cyan caduceus: favicon family, titlebar + empty-state logo (theme-safe navy badge), remove per-skin titlebar fill overrides 2026-06-28 07:44:16 +00:00
i18n.js fix(workspace): persist recovered session bindings 2026-07-29 18:22:22 +00:00
icons.js stage #4581 onto master (v0.51.556) — surface escape-target symlinks as display-only workspace rows 2026-06-21 09:15:22 +00:00
index.html polish(#6040): approval-counter CSS cleanup + i18n the pending-count string 2026-07-23 03:12:49 +00:00
login.js Fix login connectivity retry cleanup: clearInterval not clearTimeout 2026-07-09 03:41:42 +00:00
manifest.json
messages.js harden(#6349): strict finite-px min-height parse for the composer fast path 2026-07-23 04:05:03 +00:00
onboarding.js fix(webui): give the onboarding password inputs a form owner too 2026-07-15 10:41:16 +02:00
outline.js Release: msg_limit ceiling + row-loss-safe pagination (#6152 + #6154, @rh-id) (#6213) 2026-07-17 20:15:40 -07:00
panels.js fix(workspace): persist recovered session bindings 2026-07-29 18:22:22 +00:00
pwa-startup.js
sessions.js fix(#6419): route every recovery path through one pending_user_message merge helper 2026-07-29 22:37:58 +00:00
share.html Rebase #5337 (public read-only conversation sharing) onto master 2026-07-11 01:39:42 +00:00
share.js Rebase #5337 (public read-only conversation sharing) onto master 2026-07-11 01:39:42 +00:00
style.css feat: render process wakeups as collapsed summary cards (#6350) 2026-07-23 20:52:51 +00:00
sw.js fix: focus the existing chat tab when a notification is clicked instead of opening a new tab 2026-06-13 14:42:41 -07:00
terminal.js Handle terminal output EventSource transport errors 2026-07-09 02:26:20 +00:00
ui.js fix(#6419): route every recovery path through one pending_user_message merge helper 2026-07-29 22:37:58 +00:00
workspace.js fix(workspace): persist recovered session bindings 2026-07-29 18:22:22 +00:00