fix: preserve pending user turn on stream errors#1760
Merged
1 commit merged intonesquena:masterfrom May 6, 2026
Merged
Conversation
2106083
iosub
pushed a commit
to iosub/HERMES-hermes-webui2
that referenced
this pull request
May 6, 2026
iosub
pushed a commit
to iosub/HERMES-hermes-webui2
that referenced
this pull request
May 6, 2026
nesquena#1757, nesquena#1760, nesquena#1761) Constituent PRs: - nesquena#1760 (@ai-ag2026) preserve pending user turn on stream errors. Closes nesquena#1361. - nesquena#1761 (@dso2ng) scope terminal stream cleanup to owner session. Refs nesquena#1694. AUTO-FIX applied: restored !INFLIGHT[S.session.session_id] disjunct in _setActivePaneIdleIfOwner (regression introduced by helper centralization). - nesquena#1756 (@ng-technology-llc) isolate profile cookie per webui instance. Closes nesquena#803. - nesquena#1757 (@skspade) tri-state gateway status (alive: True/False/None). Tests: 4642 → 4662 collected (+20). 4649 passed, 9 skipped (test-isolation prong-2 noise), 3 xpassed, 0 failed in 152s. Pre-release verification: - All 4 PRs CI-green or rebased clean (nesquena#1757 had stale base; CHANGELOG conflict auto-resolved by dropping the PR's redundant entry). - node -c clean on static/messages.js + static/panels.js. - 11/11 browser API endpoints PASS. - Pre-stamp re-fetch: all PR heads match local rebases. - Opus advisor: SHIP, all 5 verification questions clean, 0 MUST-FIX, 0 SHOULD-FIX. - Two NICE-TO-HAVE coverage gaps absorbed in-release: (1) test_sprint36.py asserts !INFLIGHT[...] disjunct in helper body (2) test_issue1361_cancel_data_loss.py adds structural-grep test to pin _materialize_pending_user_turn_before_error call sites at error branches. Closes nesquena#803, nesquena#1361, nesquena#1694.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test Plan
python3 -m py_compile api/streaming.py tests/test_issue1361_cancel_data_loss.pypython3 -m pytest tests/test_issue1361_cancel_data_loss.py tests/test_regressions.py -q-> 58 passed, 1 skippedgit diff --checkNotes
This covers stream error exits that occur before the normal agent-result merge. In deferred session-save mode,
pending_user_messagecan be the only durable copy of the current user turn; clearing it before adding the error marker loses the prompt on reload/reconcile.