Commit Graph
4 Commits
Author SHA1 Message Date
nesquena-hermesandneaucode-bot 05f6e8c7f4 fix(sessions): guard viewed-count clear in message-load + derive stream state from target session (gate findings)
Co-authored-by: neaucode-bot <neaucode-bot@users.noreply.github.com>
2026-07-11 05:39:19 +00:00
nesquena-hermes 63d3efb6c4 fix(sessions): guard post-load unread re-ack on active view (gate finding)
Gate found the unconditional post-load _acknowledgeSessionVisit() cleared a
hidden-tab completion's unread marker: a completion landing while
_ensureMessagesLoaded() is in flight AND the tab then goes hidden is correctly
marked unread, but the final re-ack wiped it. Gate the re-ack on
_isSessionActivelyViewedForList(sid) so only an actively-viewed session clears.
Regression test added. Co-authored-by: neaucode-bot.
2026-07-11 05:15:01 +00:00
Nathan Esquenazi da00a5ae8c fix(review): unblock CI on the stale-unread-dot salvage (#4946)
Two CI-red issues, both fixed:

1. Lint (F401): the new tests/test_session_unread_dot_on_visit.py imported
   `re` but never used it. Dropped the import.

2. Test hang/timeout: loadSession() now routes its viewed-count/unread clear
   through the new _acknowledgeSessionVisit() helper, but the PRE-EXISTING
   tests/test_cross_session_message_load_isolation.py harness (which extracts
   loadSession and stubs its deps) didn't define it — so the extracted
   loadSession broke and the node driver hung to the 60s pytest-timeout.
   Stubbed _acknowledgeSessionVisit + _sessionVisitHasUnreadState to no-ops
   there, mirroring the pre-existing _setSessionViewedCount /
   _clearSessionCompletionUnread stubs they replaced. That harness covers
   cross-session load ordering + stale-reject, not unread-dot state, so a
   no-op stub preserves its intent; the real helper is exercised by the PR's
   own test_session_unread_dot_on_visit.py.

Verified: ruff forward gate clean; the timeout test passes in ~1s; the PR's
unread-dot suite 7/7.
2026-07-10 21:05:47 -07:00
nesquena-hermesandneaucode-bot 58af505cc6 fix(sessions): clear stale sidebar unread indicator on session visit (salvage of #4946)
Salvaged from #4946 by @neaucode-bot. Rebuilt fresh on master (repro-confirmed),
without regressing hidden-tab completion state or lineage-parent unread dots.

Co-authored-by: neaucode-bot <neaucode-bot@users.noreply.github.com>
2026-07-11 03:32:26 +00:00