Repository navigation
fix(platform): show older unread notifications instead of caught up - #4394
Conversation
|
Independent exact-head review of #4394 at
B1 (MEDIUM, blocking): when the count re-reads before the list after a single read, the hold is dropped and the #3610 state flashes.
Everything else on the brief holds
Runs
Claim corrections (LOW, not blocking): the PR adds 18 new tests (9 cases × 2 streams), not 14, and main fails 12 of them, not 10. CI at this head: 14 checks completed (Lint commits and PR scope green, the rest skipped by design) and 21 are queued. I did not rerun anything. No push, merge, rerun or status change. Next: agent #5 repairs B1 at a new head, and the manager routes the re-review. |
|
Independent exact-head re-review of #4394 at
B1: closed in both streams
Mutants (head source, head suite, one worker)
No regression elsewhere (head suite plus probes; P9-P13 are new)
N1 (LOW, not blocking; an optional follow-up or one more known-limits line): the documented two-read limit has a mirror case.
Runs (
CI at this head: pending.
Next:
|
7b1ab32 to
f4b81dc
Compare
f22735c to
44d59e2
Compare
The Unread tab filters only the loaded rows, while pagination walks each stream's read and unread rows together. With the 25 newest notifications read and an older one unread, the panel showed "Unread (1)" over "You're all caught up", although the next page held the unread row. Each stream now compares its unread count with the unread rows it has loaded. When the count is higher and the stream has a page left, the empty Unread tab points at older unread notifications, and Load more walks to them. An exhausted stream or a zero count still reads caught up, and Load more stays hidden over read history only. A read reaches the list and the count in separate re-reads, in either order. After the panel's own read, the stream keeps its figure until its count moves: Mark all as read holds none, since it also reads the pages not loaded yet, and a failed write lets the figure go. The new copy ships in EN, DE and FR, and the coverage register names the suite. Closes #3610
After a single read, the hold kept a stream's unread-beyond figure only while the count still read its old value. When the count re-read landed first (2 to 1, the read row still unread in the list), the hold dropped, 1 - 1 = 0 read as "You're all caught up", and Load more hid in both streams until the list re-read arrived. The hold now records the row it read. It stands while the count has not moved or the list still reads that row as unread, so the figure holds until both re-reads have landed, in either order. The release effect re-checks on list changes too. Mark all as read keeps its zero figure until the count moves, as before. The list-first test now says so in its title, and a count-first test covers both streams: the count goes 2 to 1 with the row still unread, and the panel keeps pointing at the older unread row with Load more enabled.
44d59e2 to
c959386
Compare
What changed
The Unread tab filters only the loaded rows, while pagination walks each stream's read and unread rows together. With the 25 newest notifications read and an older one unread, the panel showed Unread (1) over You're all caught up, although the next page held the unread row (#3610).
notification-list-panel.tsxnow compares each stream's unread count (organization and personal) with the unread rows that stream has loaded:CanLoadMore, orLoadingMore), the empty Unread tab says You have older unread notifications · Load more to see them. (BellDot), and Load more walks to them. It never says "all caught up" in that case.unreadCount > 0. That keeps the button from appearing under "caught up" while a count catches up after a read.emptyOlderUnreadTitleandemptyOlderUnreadDescription, ship in EN, DE (du) and FR (tu). They contain no ß and no quotes, so no de-CH override is needed.tests/manual/reference/automation.md, right after the existing[notifications]behaviour row (anchor: the "Partial preference updates…" row).Neither the backend nor the query hooks change. Two alternatives were rejected:
hooks/queries.tsdeliberately keeps the filter out of the query key.fetchNextPagewould cancel an in-flight hint refetch.How I verified it
All runs were local, Node 24 + Vitest 4.1.11, with one worker.
notification-list-panel.test.tsx: 43/43. Ten new cases × both streams, 20 in all:Unread (1), never "all caught up". Load more is called, theLoadingMorestate follows, and the next page reveals the row;37abcb5a, plus both count-first tests. The 6 that pass are the loaded-rows control, the failed read's dropped figure and the exhausted stream, each in both streams.37abcb5a's component, only the 2 count-first tests fail: the panel reads "You're all caught up" (review B1).LoadingMoredropping the claim;unreadCount;readIdon the organization read, noreadIdon the personal read, and the list's unread check inverted. DroppingresultsandmyNotificationsfrom the release effect's dependencies failsreact-hooks/exhaustive-deps.vitest.ui.config.ts), andnotification-bell.browser.test.tsx1/1 in Chromium.lib/i18n/messages.test.ts+notification-keys.test.ts60/60, with no report-mode finding on the new strings.oxlint --type-aware --type-checkclean on both TS files (the invocation was checked with a planted error), and a scopedtsc -pover both files passes. oxfmt and lint-staged ran, andbun run lint:manualpassed.git merge-treeagainst all 64 open PRs adds no conflict that main itself doesn't already have. fix(platform): refresh API key views across organizations #4382 inserts at the register's prose spot, which is why the row sits in the table instead. The branch merged cleanly with main at07d6d7914. At7b1ab322it still merges cleanly with main atdd1cb498d.Known limits
37abcb5abehaved the same.Closes #3610