Repository navigation
fix: reorder sidebar topic rows by hydrated last-message stamps - #903
Open
cassi-volkova wants to merge 1 commit into
Open
cassi-volkova wants to merge 1 commit into
cassi-volkova wants to merge 1 commit into
Conversation
Topic rows were keyed only by the catalog updated_at, so a topic whose last-message pointer resolves later through the preview pump kept its fallback rank. Route topic rows through the same activity-ledger key the stream rows use (topicNotificationRank), announce the reorder narrowly via streamsChanged, and pin the corridor with the hydration reorder case.
exordy
approved these changes
Nov 26, 2026
exordy
left a comment
Member
There was a problem hiding this comment.
exo-review: LGTM
Intent: Reorder sidebar topic rows when preview hydration resolves their last-message timestamps.
Verify before merge
- Inspect the sidebar model and QML bindings to verify topicsChanged refreshes rendered topic order.
- Complete the PR's stated live sidebar verification and base/lane performance comparison.
- Trace hydration callers, cache leases and owner-change guards to verify stale or cross-session messages cannot reach the ledger.
- Inspect noteActivityTimestamps and rowActivityMicros to verify ledger ownership, replacement and reuse behavior.
- Inspect create/update authorization and project-scoped lookups if this change is intended to alter those boundaries.
- Verify interface flows, forwarding and local-daemon OUTPUT against the relevant network configuration; none was supplied.
Coverage: 6 axes clean · 0 checks run · mode pre-prod
Threat model:
- Tenants supplying create/update fields and manifests may target other tenants' resources, traffic, secrets or quota.
- Guest frames and L2 peers may target the host, underlay, control-plane ports or other tenants' traffic.
- A hostile realm root or unprivileged local user may attempt to cross host or tenant boundaries.
- Message data and cached previews cross into the native sidebar's activity ledger and projection.
Clean axes: security pass: Hydrated message UUID and timestamp affect topic ordering only when a current row owns the pointer.; The changed code adds no privileged argv, paths, network rules, routes, sysctls or daemon binds.; Ordering: the extracted comparator preserves rank, unread and tie rules.; Hydration: the ledger write precedes the topic order comparison.; Scope: the code changes support topic hydration and notification.; Compatibility: the patch changes no persisted or serialized format.; Tests: the new case covers a deferred lookup and an activity reorder.
0 tool calls · 20s
This branch has not been deployed
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.
Closes #861
Part of #853
What
Topic rows in the sidebar kept their fallback
updated_atrank after the preview pumpresolved a newer last-message stamp for them; only stream rows were re-keyed on the
activity ledger. This lanes topic rows through the same ledger key (
topicNotificationRankhoisted to file scope,
orderedTopicPointersconsumes it) and announces the reordernarrowly via
streamsChanged, mirroring the stream-row contract shipped in #866.Tests
sidebarTopicHydrationReordersActivityOrderinnative-controller-sidebar:a deferred uuid-lookup gate makes the fallback-sort baseline deterministic, releases the
pump reply, then asserts (a) preview ledger write, (b) the resolved topic moves to the
top of the topic projection, (c) the reorder travels as a
topicsChangedannouncement.RED witness: pre-fix the reorder assertion failed (row kept the fallback rank).
native-controller-sidebarfull group: 151 passed, 0 failed (offscreen, lane build).Design oracle
docs/NATIVE_DESKTOP_SIDEBAR_PREVIEWS.md section extended with the topic-row keying rule
(reference contract cited in #853/#860: workspace_ui
messenger-last-messages-loader.lib.ts).Live verification
PASS against workspace.exordos.com through the lane binary (head df4cff2), evidence
~/dev/qa/evidence/861/:live_qa.py native-loginrc=0 on the lane build (sign-in session restored, sidebar renders).stage4_workspace.png+order_after_hydration.png(vision-gated): sidebar rows fullyrendered with name + preview + timestamp; active block strictly newest-first
(22:38 -> 19:56 -> 18:19 -> 18:19 -> Nov 24); expanded stream shows per-topic rows in
the same activity order (#General Topic 18:19 above #sborka/#debaga Nov 24); completed
topics grouped below the divider, each block descending; the transient bootstrap banner
is gone in the settled shot.
live_qa.py health --repeat 10: p50 7.25 ms, p95 8.2 ms (< 500 ms target).UX verification
projection). Window-layer witnesses:
native-controller-sidebar151/151 green incl.search/focus/hydration pins.
order_after_hydration.png, vision-gated PASS): no clipping/overlap insidebar rows, intentional ellipsis only on one-line previews, selected-row highlight
fits the row, timestamps right-aligned; main pane untouched by this change.
Perf check
Measured on the warm lane tree; base = merge-base rebuild, lane = head df4cff2, same harness
(
perf_probe.py, --idle 20, private Xvnc). Verdict: PASS.Evidence:
~/dev/qa/evidence/861/perf-base.json,~/dev/qa/evidence/861/perf-compare.json.