Skip to content

test(desktop): wait for channel head refresh before paging thread summary test - #7955

Merged
wesbillman merged 1 commit into
mainfrom
larry/fix-thread-summary-prepend
Sep 28, 2026
Merged

wesbillman merged 1 commit into
mainfrom
larry/fix-thread-summary-prepend

Conversation

@loganj

@loganj loganj commented Sep 28, 2026

Copy link
Copy Markdown
Collaborator

🤖

Summary

Main's Desktop Smoke E2E (4) job fails on scroll-history.spec.ts ("thread summary badge survives a retained older-history prepend"). This change fixes the test's timing. It does not change app code.

When a channel opens, the app starts a live subscription. When that subscription is ready, the app fetches the newest page again, and that fetch replaces the whole loaded history. This test scrolled up before that refresh happened. On slower CI runners, the refresh came after the older page loaded but before it showed on screen. The older rows went away, the reader stayed at the top, and no more pages loaded. All three attempts failed that way.

The test now calls waitForMockChannelHeadReady before it scrolls, like the other pagination tests in this file already do. That helper waits for the live subscription and its refresh to finish.

Related issue

Main CI failure at 15d44dcc (https://github.com/block/buzz/actions/runs/36470599751/job/109092076235). The same failure was reported on #7827.

Testing

  • Added temporary logs to see the order of events. Locally, the refresh ran after the older page had loaded: the loaded history went from 2 pages back to 1. The test passed only because it checked before the next render. With the wait, the refresh runs first and nothing replaces the loaded pages later.
  • playwright test --project=smoke tests/e2e/scroll-history.spec.ts: 18 passed. This test with --repeat-each=8: 8 passed.

Follow-up (not in this PR)

The app has the same race for real users. If someone scrolls up before the live subscription is ready, or during a reconnect, the refresh can drop the older history they loaded. If they are at the top of the list, paging stops until they scroll down and back up.

…mary test

The thread summary prepend test scrolled back before the live
subscription's head refresh. That refresh replaces the channel window,
so on slower CI runners it could drop the older page just fetched and
leave the reader stuck at the top. Use waitForMockChannelHeadReady like
the sibling pagination tests.

Signed-off-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

🔐 Codex Security Review

Status: review required for the current range.

The current range is 9b1c4f98e2981d6d89fbfa3154b8ef0b3b6ad334...d063223ad3a342ad436b07a847033a451c5b74b5.
A new review must complete for this exact range. When manual authorization
is required, a Block organization member must comment exactly
@buzz-security-review d063223ad3a342ad436b07a847033a451c5b74b5 to authorize a new review.
Any previous review applies only to its recorded range.

@loganj
loganj marked this pull request as ready for review September 28, 2026 20:40
@loganj
loganj requested a review from a team as a code owner September 28, 2026 20:40
@wesbillman
wesbillman merged commit f1e50be into main Sep 28, 2026
64 checks passed
@wesbillman
wesbillman deleted the larry/fix-thread-summary-prepend branch September 28, 2026 20:44
johnmatthewtennant pushed a commit that referenced this pull request Sep 28, 2026
…in-ui

* origin/main:
  test(desktop): wait for channel head refresh before paging thread summary test (#7955)
  🤖 perf: bound long-thread aux reads and make query deadlines terminal (#7854)
  Add native HPKE encryption for nsec backups (#7849)
  test(desktop): scope video menu e2e probes to emitted messages (#7953)
  Add owner deletion admission control plane (#7818)
  fix(sidebar): converge stale-at-open state across devices (sections/sort/stars/mutes) (#7805)
  feat(nip-fi): harden Blossom kind-24242 verifier to NIP-FI spec (#7288)
  Make relay readiness process-local (#7341)
  🤖 docs(nip-fi): remove implementation references from the spec (#7912)

Signed-off-by: Sol <49aa1f65411fd096d2e2ec144f1e7aa36fdc76d1b907cfdf7be000c66f9d3b8e@buzz.block.builderlab.xyz>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants