mirror of
https://github.com/block/buzz.git
synced 2026-11-01 23:11:58 +00:00
bool::then_some evaluates its argument eagerly, so every caller that lost the compare_exchange still constructed a PruneGuard and dropped it with the returned None. That Drop cleared prune_running under the winning pass, so a burst of triggers admitted multiple concurrent prunes (Gurney's live lane: 8 triggers -> 4 admitted, 3 escaped with SQLITE_BUSY). Construct the guard lazily with then(|| ..) so only the winning caller ever builds one. Add two regressions in archive_db_tests.rs: a synchronous exactly-once test where a second losing call proves the flag stays set under a held guard, and an async burst test mirroring the maybe_prune control flow proving exactly one pass enters. Reverting to then_some fails both. Co-authored-by: Will Pfleger <pfleger.will@gmail.com> Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
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 frontendpnpm tauri dev- run the desktop apppnpm build- typecheck and build frontendpnpm typecheck- TypeScript checkspnpm lint- Biome lintpnpm 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