Files
buzz/desktop
Leo d051350f69 Make the thread-head E2E proof deterministic (P1 on #6887)
Address Wes/Carl's P1: the spec delayed get_thread_replies by 4s but both
assertions used Playwright's 5s auto-retry window. On the buggy code the
panel first shows the stale body, then the delayed relay response (which
carries the root edit) lands inside the retry window and heals it, so the
positive assertion can false-green. Navigation time eats into the 4s,
making the false-green path more likely under load. The delay is a timer
that self-heals; it does not prove the head opens with the channel-window
overlay rather than healing later.

Replace the timer with a manual gate. New `deferThreadReplies` mock option
holds every get_thread_replies response open until the test calls
`__BUZZ_E2E_RELEASE_THREAD_REPLIES__()` — mirroring the existing
deferLinkPreviewMetadata / RELEASE_GET_EVENT queue pattern. The thread-aux
backfill provably cannot land before the assertion, so:
- head-edited assertion runs while the fetch is verifiably held
  (`__BUZZ_E2E_THREAD_REPLIES_PENDING__` poll guards against the fetch
  never having been dispatched);
- release the gate and re-assert the head stays edited (dedup path).

Verified red/green: reverting the production headAux carry in
independentThreadPanel.ts makes the spec fail deterministically at the
head assertion (received the stale "these two PRs?"); with the fix it
passes. tsc clean; 8/8 independentThreadPanel unit cases pass.

Signed-off-by: Leo <5faf251baee50ee6bcde338aef6acdd70bb3e60115664c2cd490d94a55dfc488@buzz.block.builderlab.xyz>
2026-08-26 14:23:51 -04:00
..
…

Buzz

Desktop chat shell with:

  • Tauri + React + TypeScript + Vite
  • Tailwind CSS
  • shadcn/ui-ready shared components
  • Biome (lint/format/check)
  • Feature-driven frontend structure

Scripts

  • pnpm dev - run the web frontend
  • pnpm tauri dev - run the desktop app
  • pnpm build - typecheck and build frontend
  • pnpm typecheck - TypeScript checks
  • pnpm lint - Biome lint
  • pnpm format - Biome format (write)
  • pnpm check - Biome check

Structure

  • src/shared - reusable app-wide code (ui, lib, styles)
  • src/features - feature modules (vertical slices)
  • src/app - top-level app composition